Jump to content

Macrura

PW-Moderators
  • Posts

    2,776
  • Joined

  • Last visited

  • Days Won

    40

Everything posted by Macrura

  1. would need to be $home_slider->sliderimg->url or $home_slider->sliderimg->first()->url depending on if the image field is single or multi
  2. depending on how your templates are configured, you could for example not have a $useDone or $useMain and then at your own discretion use the return $this->halt which should do the same thing, meaning it would prevent anything from happening after the point that you put that.
  3. the profile itself has a $useDone variable, so you can also just set that to false and load your alternate file. /* * Whether to include the _done.php markup file? For example, your template * file would set it to false when generating a page for sitemap.xml * or ajax output, in order to prevent display of the main <html> document. * */ $useDone = true; in other scenarios you can stop what happens after the template by using: return $this->halt(); so therefore you could use wireRenderFile, or include/wireIncludeFile your alternate file, and then prevent loading _done by halting.
  4. Where is _done.php coming from? If you look at Ryan's CMS Critic case study, he shows how you can make an "$includeMain" variable; are you using $page->render() or wireRenderFile() for the content of your url segment pages?
  5. thanks for that brain jiggle @Robin S Doh - just figured it out - the other dev on this project added a 2nd body field which somehow by default loads 'mystyles'
  6. no, I just followed the instructions exactly and it didn't work, that error is on the JS console. i changed all of the references to a different word and it works, but certainly something seems up, this is a vanilla 3.0.25 body field...
  7. this doesn't really work anymore: Error: [CKEDITOR.resourceManager.add] The resource name "mystyles" is already registered. something somewhere needs to change in terms of the instructions; i followed those exact instructions (Instructions can be found on here.)
  8. you can just place like a fixperms.php (with the below code) file in the root and load it (then delete it): <?php exec ("find /home/user/public_html/ -type d -exec chmod 0755 {} +"); exec ("find /home/user/public_html/ -type f -exec chmod 0644 {} +"); replace the path with the root of which folders you need to fix. our main host switched like 30 sites to a different machine and the perms were completely messed up after the migration.
  9. I have the same issue as @Zeka - i can't use T on backend, because of the white screens... haven't had time to figure out the issue...
  10. right, you'd probably want to cache that markup for a certain time, like using wireCache otherwise, i'm not sure how else you'd get the contents of those files into PW pages, maybe ajax load, or iFrame are other options
  11. I would probably go with file_get_contents of the index.html files but you may also have to somehow account for asset locations, maybe with string replacements.
  12. you'd need to make some function to output the individual assets, for example when an admin is logged in.. (very basic example) if($user->isLoggedin) { listAssets($stylesheets); } else { echo AllInOneMinify::CSS($stylesheets)); } that's how i do it..
  13. don't you need to use $item->getForPage() (should return the page the $item is assigned to) <?> at least that's how i always deal with repeaters if they are not in $page context
  14. There does seem to be an issue. see i am going to be testing more later and try and submit a github issue
  15. Pursuant to the post above by @MarcU, i am seeing the same behavior, that is the "Add New" functionality for page selects appears to be broken (ProcessWire 3.0.25 devns)
  16. I guess i might have done the sticky thing, but i assumed that meant it would show up in the selected panels in the module settings; If that's not the case, then it would be hard to 'undo' a scenario where an enabled panel under sticky mode was causing epic page loads, how would you get to the frontend panel to turn it off? i probably will use it only in the regular template files, it will definitely come in handy - many thanks!
  17. 1) Right, I don't have ToDo enabled, but it still loads all 1000 warnings 2.) OK - yes there is a massive horde of js files inside my templates folder, because I have a /themes/ folder and inside there are like 5 themes, each with a ton of css and js files, and probably a lot of those are not UTF-8 I will go ahead and exclude everything now and see what happens (can't test much because it takes about 10 minutes to render the page with warnings!) EDIT: SUCCESS I disallowed a bunch of directories and i didn't have ToDo enabled in the module settings, but it was loading on the bar, until i actually went and turned of off from the bar; so now it all works, and the ToDo was actually loading, though i have it disabled now, will check it out later...
  18. I don't know about the upgrade from/to because i deleted the previous one - sorry! I also don't know anything about ToDo, i don't use it, and don't know how it works, but I'm sure i have a ton of whack stuff in my template files, so if it is trying to read those for anything particular, then i can easily see why it might crash; all of the templates are in UTF-8 i think but i put stuff like this at the top of some of them: /** __ __ / / / /___ ____ ___ ___ / /_/ / __ \/ __ `__ \/ _ \ / __ / /_/ / / / / / / __/ /_/ /_/\____/_/ /_/ /_/\___/ */ because I have a lot of template files open at once and this makes it easier to see where i am
  19. Just upgraded, and I'm getting hundreds of errors like this, which are hanging the browser, and making Tracy unusable: Warning: Unexpected character in input: '�' (ASCII=4) state=0 in .../site/assets/cache/FileCompiler/site/modules/TracyDebugger/TodoPanel.inc on line 190 Warning: Unexpected character in input: ' in .../site/assets/cache/FileCompiler/site/modules/TracyDebugger/TodoPanel.inc on line I tried un-installing and re-installing but still can't use it...
  20. I think what you are getting at is a way to "field cache" the results of the selector field so that you don't have to evaluate it at runtime, and thereby allow that field to be used in selectors etc; You can just add a hook to the saveReady and then evaluate the selector result, and save the pipe delimited ids into that field; very simple and effective way of field caching and i use it a lot. The only snafu is that the beauty of the selector field is it's inherent dynamism, meaning you don't need to interact with the page anymore once the selector field is configured (new pages would 'auto-add' to the results). But if you field cache those results, they will be frozen at the time you save that page. You'd need another element which would be like a cron job that updates the field once in a while or when other pages are saved. Another option would be to wirecache those selector field results.
  21. @kongondo great! Thanks for the update, and for this module! Will post the the final site/use once it's done (about a month away...)
  22. You can sell them here: https://processwireshop.pw/
  23. @kixe can you upgrade to 3.0.23. A lot of modules and other stuff was broken on .22
  24. right - the use case is that we have a media library and that holds images that are used in various places on the site. On any of those images in the library, the users should be allowed to use the image marker functionality, or not use it...
  25. working well, like the Lato font; noticing that the top breadcrumb is breaking to 2 lines
×
×
  • Create New...