Jump to content

adrian

PW-Moderators
  • Posts

    11,213
  • Joined

  • Last visited

  • Days Won

    373

Everything posted by adrian

  1. Again - using @fbg13's code is not pulling the value from the cite field, but rather from the details of the currently logged in user. If you require that a user is logged in before commenting, that will be fine, but if not, it will always return the guest user, so you would need to figure out the issue with cite. Let us know what you find regarding the cite DB column/field. As for why it might not be being populated, are you using $page->comments->renderForm() to generate the comment form, or are you creating it manually? Is it asking for "Your Name" along with email address and the actual comment The "Your Name" field is what populated the "cite" field in the db.
  2. Remember that the "cite" field is not storing the same info as the "created_users_id". In most cases, "created_users_id" will be "40" - the ID of the guest user. "cite" can be entered manually. Have you checked the "cite" field in the DB table for the comment field? Is it actually being populated? May or may not be useful, but if your users are always logged in, check out this very old PR: https://github.com/ryancramerdesign/ProcessWire/pull/954
  3. Just an FYI - I have that setting on (as is default), and if I link to a page without the trailing slash, it always redirects to the slash version. Any chance you have something that might be hijacking the redirect?
  4. @Sipho - You can choose different templates for Repeater Matrix fields - that link I provided shows examples and states: But, as with repeaters, they are not pages with URLs that can be directly visited - you could probably "fake" this by using URL segments on the parent page and use the passed values to determine which repeater item to show. OT - I completely agree that the PageTable interface is not ideal - seems to me we need the repeater matrix editing interface for PageTable fields as well. When the PageTable field was added, repeaters didn't support ajax loading, hence the modal editing interface to ensure it was scalable with lots of items.
  5. Not free, but check out Repeater Matrix: https://processwire.com/api/modules/profields/repeater-matrix/
  6. Take a look at this: https://github.com/adrianbj/ProcessAdminActions/blob/master/actions/PageTableToRepeaterMatrix.action.php It's purpose is to convert a PageTable to RepeaterMatrix, but you should find the code snippet in there that you need.
  7. Another option is the functions API: https://processwire.com/blog/posts/processwire-3.0.39-core-updates/#new-functions-api which lets you do things like: pages("template=basic-page")
  8. This will happen automatically if the fields for the page don't have a translated version - they will fallback to the default language. Also, just an FYI - you can also use Admin Actions to batch activate languages.
  9. Also, just an FYI - you can also use Admin Actions to batch activate languages.
  10. adrian

    Chrysemys nl

    CSS issues again right now: https://chrysemys.nl/verspreidingen/mississippi/ The CSS file is not found: https://chrysemys.nl/site/assets/aiom/css_chrysemys1f1a1b4c7f9475a33fbccc73a9188593.css If AIOM is causing these issues, then there must be something wrong somewhere
  11. No ideas are silly - just looking for a consensus before making any changes.
  12. Maybe, but on my Mac keyboard, the ALT key is closer to Enter than the CMD or CTRL keys, so for me that is the easier thing to use to clear and run. How many people out there are using the actual "Run" button instead of the shortcut? I know I do occasionally on page reload when the console isn't in focus, but it's not often. I guess my reasoning for a "Clear Results" button, rather than clearing by default is to keep it a little similar to the behavior you see with a regular terminal/command line where you have to explicitly clear what has been returned. Any strong feelings on this? PS - if we had two radios then we need to decide whether that status should be remembered or reset - sounding unnecessarily complicated to me
  13. I'm happy to adapt if needed, but to be honest I almost always use the ALT+Enter option to run the code which automatically clears before running: "Enter PHP code, then use CTRL/CMD+Enter to Run, or ALT/OPT+Enter to Clear & Run." Does this work for you, or do you still think we need a change?
  14. adrian

    Chrysemys nl

    Seems to be fine now - before I couldn't get the css files to load, so there was no page styling at all. I did reload a couple of times to check. Maybe it was an issue with AIOM, or some network glitch, but the css on other pages was ok. Maybe nothing to worry about, but I would suggest keeping an eye out.
  15. adrian

    Rockpool Painting

    Just a quick note - the "Page Delete" module is obsolete - that functionality has been in the core for quite some time now.
  16. adrian

    Chrysemys nl

    @webhoes - the site looks fantastic, but just wanted to let you know that some pages are having css issues, eg: https://chrysemys.nl/habitats/ and https://chrysemys.nl/verspreidingen/kansas/ I expect there are many more also.
  17. Hey @bernhard - I just PM'd you with a new version that should work as expect with ready.php and hooks inside it. If you can test for me, hopefully I can get a new version released. Thanks!
  18. There are some links and also some code for creating repeaters and adding fields to it here: Shouldn't be anything special about doing it from a module. HTH.
  19. Nope - you just select the template of the parent page and the template that you want to use for the child pages from the module config settings. It should be pretty obvious once you start with it.
  20. Hey @onjegolders - I just tested @mr-fan's version of this script (which makes it a configurable module) and it works fine for me in PW3. The new page are created as direct children of the page where the bulk images are uploaded. The only thing I noticed that seemed a little weird is that if no description for an image was entered, the child page title used the name of the image directly including the file extension. I have created a PR which improves this: https://github.com/mr-fan/AutoImagePages/pull/1 Until that is accepted, please check out my fork: https://github.com/adrianbj/AutoImagePages
  21. Hi @Klenkes - I decided to go with #2 - now BCE will only apply the "purify" sanitizer if the field that is being populated/updated has the HTMLPurifier enabled. Could you please test at your end to make sure it works as expected? Thanks!
  22. I do use the $sanitizer->purify option with all content added via BCE, so that will be the source of the problem for sure. I can see two possible options here. 1) Add a BCE config setting to enable you to turn off the purifier sitewide and/or per parent page. 2) Check the purifier status for the field that the content is being added to and respect that. Any thoughts? PS if you want a quick fix, just edit this line: https://github.com/adrianbj/BatchChildEditor/blob/ba228d2f011d306345f02ec4aa19d090f2d89481/BatchChildEditor.module#L1448
  23. Hey @bernhard - I spent quite a bit of time looking into this the other day with no success. It turns out it's not just hooks inside ready.php - it seems like ready.php is never called at all from the Tracy console panel. I will investigate further, but so far a bit of a mystery. I thought perhaps it was an issue with ajax calls (which the console panel uses), but a normal ajax call results in ready.php being called, so really not sure at the moment. I'll see what I can figure out. Cheers, Adrian
  24. You could also just do this. By using "first()" you avoid the need for the foreach loop. $cart->renderPriceAndCurrency($release->children("limit=1, sort=pad_price")->first()->pad_price);
  25. You could also use Batch Child Editor's edit mode to change the status of all 500 children at once. Simply click the checkbox for the "Unpublished" label and that will uncheck it for all child pages.
×
×
  • Create New...