Jump to content

Soma

Moderators
  • Posts

    6,808
  • Joined

  • Last visited

  • Days Won

    159

Everything posted by Soma

  1. Ryan thanks for the throughout explanation. That all makes sense. Now testing again with and with your new PageFinder.php it seems to make a difference and should work. Maybe I mixed something up with the new php file yesterday... But one thing that caught me is that when I test with your code. In the output the user id's are switched. I tracked 2 pages and edited with admin and an editor user. page: 1240, created_user_id: 1007, modified_user_id: 41 page: 1257, created_user_id: 41, modified_user_id: 1007 Actually 1240 was created by admin (41) and modified by editor (1007)... ? Same with the page 1257, it's created by 1007 and modified by 41. When I look at the info on page edit screen it shows me the correct values. I double checked everything and tried everything (removed PageFinder.php) etc but can't figure out why.
  2. Ryan, I also tested this and we were utterly confused. (in the irc) "|" means OR, and it was working as it should (or is it different with textfields?) the first to find will be returned. Can you put some light into this? Now after your change, it returns all pages that are found for both fields (created and modified). And this is confusing as I assume it's an OR. But that's not what he wants. He wants ALL pages that are either modified or changed by the user. At the end we ended up again to what I suggested to split the find and merge them. Because it can't be done with one selector like "created=uid, modified=uid" as it will only return the pages both are true.
  3. It works fine, I'm using repeaters and haven't run into this issue. I assume it's something with the permission on templates/pages that does not find the pages for guests. $quoteList = $pages->find("employee_quote!=")->shuffle(); This is not on page but doing a find over ALL pages there is. If the pages with the repeater on it is somwhere the guest doesn't have access it won't find them. To test this you could try adding a ",include=all" to your selector. Does it change anything?
  4. Errm, while extensively testing things, I forgot that I had caching on, and once turned off (and urlsegments ) it seem to be working. Although not tested completely
  5. nikola, I think it's either because the Module isn't installed, or you're logged in while viewing the page. It only renders form when not logged in. I tested it but it doesn't seem to work just like this. Somehow it doesn't process it and instead just show the form again after submit.
  6. Steve, you're revealing too much already...
  7. You're missunderstanding viewable(). It's only for checking if a user has view permission. I think what you're trying to archive would be: if( !$parent->isHidden() ) ... Do a "page->is" search on the cheatsheet to see further methods. Edit: ...oh and I drink coffee not beer. Edit2: Damn you already got that in your code... (not enough coffee I guess) need to read again. lol Edit3: Ok I added a !, so this looks ok. Reading again you already got the answer there in the code. Anyway, as an alternative, you could also leave the apple page visible and create a special template ie. "redirect_xy", and use that to do redirects to the first child or anything you could specify. You then would also have to deal with the searchresult additionally, or maybe not. For example the: $session->redirect($page->children()->first()->url); Or maybe even add a page field (single) to the template to select the page to redirect to. $session->redirect($page->redirect_page->url); But your solution seems ok to me. Just wanted to give alternatives (for others and the record).
  8. Same caught me too once. It's only when logged in as supermom.
  9. There's actually a login link at the end of the installation.
  10. Ryan, this doesn't return the anything for me. ? echo $page->pdf->pathname; // returns nothing However, I got a little class that works pretty well for download files. Without getting headache. https://gist.github.com/2775882
  11. You're almost right. But it's not what he wants actually. He wants to have all pages that where created XOR modified. Using "," will only return pages that are modfied and also created by the user, like you mention (both must be true). So it's "only possible" with splitting it in two separate queries and merge them.
  12. You're right. It's actually because it's also not in the docu. Will add it later, thx.
  13. When cloning a template that has template context setting on fields (ie width), the settings get lost.
  14. Not sure what's wrong. It works as it should for me... I would get "1002,1004,1006", it actually xor I think.
  15. Yeah I've put enough pressure on Ryan to implement it finally. Shame not all noticed it. Welcome aboard alan
  16. Although it's not completely complete I think...
  17. I'm sorry. I would love to help, but I'm too busy with my own projects, fulltime job and family. Hope you find someone.
  18. If you can I would use symlinks to have one set of templates and link folder or single files to the local site.
  19. Ah, sorry for not getting it first time. Simple but not that easy that I could just write the code here. May I refer you to this?
  20. Soma

    the-omnia.com

    Thanks apeisa! Yeah very mysterious I just asked them to list processwire.com under credits, so it's there now.
  21. Admin -> Modules -> Password Forgot module (install). Enjoy
  22. Depends on how you code that part. So I'd guess (without seeing your code) you have some echos in there that isn't conditional.
  23. I was also able to reproduce the image part. It now works with the latest. Thanks Ryan! Haven't tested google maps.
  24. Ah, sorry I didn't get it that's on user list. You're right, user names with only numbers breaks the output. In DataTable, if a row array entry is a key=value, where value would be a url, it will be outputed as link automaticly... $row["username"] = "edit/?=123"; This is the code that does it on user list in ProcessPageType.module : foreach($fieldNames as $name) { if(!$n) $row[(string)$page->get($name)] = "edit/?id={$page->id}"; else $row[] = $this->renderListFieldValue($name, $page->get($name)); $n++; } So you're right. Even though the key should be a (string) it doesn't work with a number.
  25. Glad I could made your day!
×
×
  • Create New...