-
Posts
10,902 -
Joined
-
Last visited
-
Days Won
349
Everything posted by adrian
-
I haven't looked into why, but it's weird to me that the first option doesn't work. Maybe it would be ok with !== but that would make it more strict, so not sure. But glad you have it working
-
Front end ajax select filters based on pages data
adrian replied to Krlos's topic in General Support
Good suggestion - I have actually used this module (slightly modified) on the frontend - works great! -
For reference for other who come across this and don't see the github issue: https://github.com/processwire/processwire-issues/issues/434#issuecomment-345437293 Ryan talks about the uncacheAll issue and how to deal with it.
-
Makes sense - tricky because you are adding a repeater item. I am sure there is a fix, but really have to go now Have a read of this: https://processwire.com/talk/topic/315-run-code-after-page-save/?do=findComment&comment=2206 - might put you on the right track!
-
I haven't followed closely, but please try: $p->save('text'); Or something like that depending on what field(s) you are trying to save. Sorry, I should probably look at this more thoroughly, but not enough time Saving the entire page in a save hook will always cause problems because of recursion.
-
how pages that logged user has created in admin panel
adrian replied to ziu's topic in General Support
Some discussion on this and using listable() https://github.com/ryancramerdesign/ProcessWire/issues/302 -
[SOLVED] 403 Forbidden when loading images from folder
adrian replied to jploch's topic in Getting Started
This takes me back to my newbie days PS - hope that didn't come across as though I was suggesting that is a newbie question @jploch - I would probably have referred to that old thread if I had the need once again. -
how pages that logged user has created in admin panel
adrian replied to ziu's topic in General Support
Have you tried this gist: https://gist.github.com/adrianbj/e391e2e343c5620d0720 With this PW permission: I haven't tested, but I think that combination should work as is, or with a little tweaking. Might avoid you needing to reinvent things. -
You need to install the PDO driver: https://stackoverflow.com/a/6735730/1524576
- 1 reply
-
- 1
-
I don't see a problem here with regular fields. Any chance it's just ImageExtra fields that cause the problem?
-
I haven't seen any issues and it should be fine, because it uses PHP's version_compare() which support comparison of integer and string version numbers https://github.com/processwire/processwire/blob/57b297fd1d828961b20ef29782012f75957d6886/wire/core/Modules.php#L4023 http://php.net/manual/en/function.version-compare.php
-
It's always been an issue to some degree: I have actually moved all my modules to string version numbers so that I can do 1.2.13 etc. I am trying to be more diligent with using numbers that are somewhat semantic at least.
-
Problem with password field after downgrade
adrian replied to verdeandrea's topic in General Support
Try doing Modules > Refresh -
how pages that logged user has created in admin panel
adrian replied to ziu's topic in General Support
Well, it's pretty much just like this. If the createdUser property for the given page matches the current user, it will return true, otherwise false. If that doesn't make sense, maybe post some code so we can debug for you. -
Thanks to a request from @Rudy this module now supports "Allowed Roles". This is basically the same as the option in the Page Protector module, but I thought it might be nice here as well. It allows you to limit access when in Protected Mode to a defined list of roles.
-
@Robin S -if you have original files (InDesign or compatible) you might want to take a look at Adobe's DPS: https://digitalpublishing.acrobat.com/welcome.html I haven't looked into it in a while, but what I wish would happen would be wide spread adoption of EPUB 3 so we could build layout style publications that reflow properly on smaller devices.
-
Hi @cstevensjr - nice looking site and story. I hope it proves successful for you wife. One small thing - I noticed that all the links in the sidebar open in a new tab - I assume that this isn't intentional? Cheers, Adrian
- 4 replies
-
- 1
-
- online e-commerce
- page table
-
(and 2 more)
Tagged with:
-
PS, this is a really good reason to be using 7.1 over 7.0: http://php.net/manual/en/migration71.incompatible.php#migration71.incompatible.fatal-errors-to-error-exceptions
- 11 replies
-
- 3
-
- php 7
- processwire
-
(and 2 more)
Tagged with:
-
how pages that logged user has created in admin panel
adrian replied to ziu's topic in General Support
It sounds like easiest approach would be to change it to look like this: Properties ---User 1 -------Property 1 -------Property 3 ---User 2 -------Property 2 -------Property 4 I understand that might be an issue for the url structure on your site. There are ways around this though. The other option is https://processwire.com/talk/topic/1176-hiding-uneditable-pages-from-users/?do=findComment&comment=84916 - read that post and the post that it links to and the rest of both threads. There are ways to do this that should work fine and in your scenario I don't think the mentioned problems will be an issue. Let us know if you need help with any of the linked scripts. -
Hey @Robin S I haven't used a website to app conversion tool, but I have built a few apps using hybrid technologies - most recently with Ionic. You can easily distribute Android apps with an APK file. iOS are of course more difficult. If you went with Ionic, they have an app called Ionic View which makes it easy to run an app on iOS and Android devices without submission to app/play stores. There are also things like these tester app distribution tools (https://rollout.io/blog/testflight-alternatives-ios-beta-testing/) which might get the job done for your needs. Hope that's a helpful start.
-
how pages that logged user has created in admin panel
adrian replied to ziu's topic in General Support
@ziu I think this is what you are looking for, but not positive of your exact scenario: http://modules.processwire.com/modules/admin-restrict-branch/ -
Sorry, @bernhard - yes I did see it. I haven't investigated fully yet. I am still not totally convinced of the right way to go - the Github Pages site is ready to go and can accept PRs, but @netcarver also has something cool up his sleeve: Amongst its many features, makes the ReadMe file viewable from the Module settings within PW, so maybe that is actually a good place for docs after all? So, not forgotten, just percolating. Thanks again for the suggestion!
-
Attaching a form uploaded image in an email (solved)
adrian replied to ryanC's topic in Getting Started
I don't think you are doing anything wrong other than having the path to the attachment incorrect. This is the code I use successfully for sending an attachment. I am using horst's WireSMTP module. $mailer = $mail->new(); $mailer->sendSingle(true)->to($to_address); $mailer->from($from_address); $mailer->attachment($page->files->last()->filename); foreach($page->files as $file) { $mailer->attachment($file->filename); } $mailer->subject("Email Subject")->body(strip_tags($message))->bodyHTML($message); $mailer->send(); This attaches all the files in the "files" field on the current page. You can remove that foreach loop and just attach the user's uploaded file. You just need to get the full path to the file on the server disk. Based on your code above, it should be at: $config->paths->assets . "files/useruploads/" So you just need to add the filename to the end of that. I think you should specify the full path to an image that is already on your server so you can first see for yourself that attachments are correctly sending. Then you can make it grab the user's uploaded file. -
Page Reference Input fieldtype: Checkboxes - more advanced options
adrian replied to cst989's topic in Wishlist & Roadmap
Not quite the same, but you can currently select the first item and if you hold down shift while clicking the last, all will be selected. -
Attaching a form uploaded image in an email (solved)
adrian replied to ryanC's topic in Getting Started
Hi @ryanC - sorry for the silence on this one. I don't have much time to help with this today, but I wanted to get the ball rolling for you. I think you are misunderstanding PHP objects/variables/strings etc a bit here. You define $upload_path as a string and they try to use it like an object with a $userimage property, which just doesn't work. I would suggest stepping back and using: $mail->attachment('known/path/to/image.jpg'); That will help confirm that the attachment process is working. Then make sure that the path you are linking to the user uploaded image is the correct full path to that image.