Jump to content

Soma

Moderators
  • Posts

    6,808
  • Joined

  • Last visited

  • Days Won

    159

Everything posted by Soma

  1. Ok back on laptop. I corrected my code example with "n" and missing bracket. Thanks for pointing out, but I wrote it in the browser and didn't test. Glad you figured it out finally It can take time to adapt brain to PW but it's worth. Concerning your publish month question. The current example with getting current month doesn't require a publish unpublish scenario. If you would really want to make it it would be as simple as getting the published page from the parent with children(selector). This function will only return pages that are published and not hidden. // return published and visible children from /empfehlungen/ $menues = $pages->get("/empfehlungen/")->children("template=empfehlung_list"); if(count($menues)) { foreach($menues as $child) echo $child->render(); } else { echo "Keine Menues gefunden."; } // return all children, even hidden $menues = $pages->get("/empfehlungen/")->children("template=empfehlung_list, include=hidden"); // return all children, even published and hidden $menues = $pages->get("/empfehlungen/")->children("template=empfehlung_list, include=all");
  2. The parent in the selector is wrong.. Just need the path as in my second post.
  3. Obviously nothing helps but call support of that hosting...
  4. I have php 5.2.9 and works all well. I don't think there legacy version. As I said earlier you might check if $config->userAuthHashType = "sha1" is supported by your server or need different setting. Also check php info to see if mcrypt blowfish is installed and what hash engines are available.
  5. Hmm, The error you mention can't be found in PW, so is it an php error? Maybe something to do with PHP install and $config->userAuthHashType = 'sha1'; ?
  6. Have checked session folder perms or delete them and cookies? Can you try using db session or are you using it?
  7. $config->userAuthSalt = '...';
  8. Also instead of doing $pages->get("parent=/empfehlungen/, name=$curr_month")->children->find("template=empfehlung_list"); You can do just $pages->get("/empfehlungen/$curr_month/")->children("template=empfehlung_list");
  9. Don't make things complicated Since php generated date strings are english you'd have to name you pages in english or use a mapping. Diogo already posted some code with using eq(n) which would take the position in the pages tree to get the current month. Here's another example how I would do it with using month names. $month = date("n"); // month integer $month_names = array("januar","februar","maerz","april","mai","juni","juli","august","september","oktober","november","dezember"); $curr_month = $month_names[$month-1]; $menues = $pages->get("/empfehlungen/$curr_month/")->children("template=empfehlung_list"); if(count($menues)){ foreach($menues as $child){ echo $child->render(); } } else { echo "Keine Menues gefunden."; } In selector you should use "field=$value" instead of 'field=$value', or the variable won't get parsed. Also you need to separete selector pair with comma. "field=value1,field2=value=2".
  10. Ended up posting? They're moderated so they won't get published immediately.
  11. What about the hash key in the /site/config.php? This should be different from server to server install. Or maybe try disable fingerprint setting in there?
  12. I just tested and was able to submit a comment and see the success text. I also noticed there's some script that it seems to wait for loading plusone.google.com but it's still working.
  13. Thanks alan! Well not sure what this admin theme has to do with ModulesManager and Helloworld.module?
  14. Texformatter modules aren't autoload they only get called when needed. You'd have to make it autoload to use the init in the backend, but then it's not when it's called but when autoloaded in the admin. Then you could use init to add a hook InputfieldText::render there for fields that use that this textformatter.
  15. Clear cookies and try again. It works for me but also got problems when trying around..
  16. It doesnt render or no items in cart os different thing. Clear cookies and cache.
  17. You maybe have to enter the umlauts in the InputfieldPageName module config? Though not sure that has to do with it.
  18. jQuery 1.9 wouldn't work I think out of the box for many jQuery code in PW or modules, as it doesn't have .live(), .browser() and possibly some others. At least I know some that use live, and the admin theme main.js uses .browser() to block for IE7 browsers. Other than that I think at some point we can update and encourage module developers to check their modules and make js code 1.9 friendly.
  19. Watch out for the nav2 malware just updated the gist...
  20. Nice catch joss! Yeah that was missing. The problem was that $child->numChildren isn't access aware so I use now count($child->children). numChildren also count unpublished and hidden pages. It's now fixed. I also rewrote some if else in there to keep thing short. Since I'm sick updating it here I created a snippelt. Also for Sublime2 Fetchers and myself in case I need it once https://gist.github.com/somatonic/4743011
  21. Theres clearly something wrong with the hosting as stated above by Ryan a possible next step would be to call the hosting support to ask if theres something regarding htaccess rewrite settings or possible other setting interferering. A 5O0 server error has most of the time to do with htaccess.
  22. Any more info helps, so far your last info is the most important to know...
  23. Thanks for the response. Ithink this would be no problem as youre also able to select hidden pages.
  24. Thanks for sharing. "Just copy the SmartyTemplating folder to your /wire/modules/" ... That's plain wrong. Never use /wire for modules and such. It's the core and if you provide 3rdparty modules they are always in /site/modules.
  25. You now got the nav2 class still in.
×
×
  • Create New...