Jump to content

Jonathan Lahijani

Members
  • Posts

    716
  • Joined

  • Last visited

  • Days Won

    26

Everything posted by Jonathan Lahijani

  1. I just found this developer oriented browser which has me excited: https://sizzy.co/ I'm about to play around with it but wow, it looks like it could increase my productivity quite a bit!
  2. That code seems correct. Are any of the post pages in-fact published, because if not, you'll need to add 'include=all' to your selector: $pages->find('template=lvl04-post, limit=5, include=all');
  3. I was literally suggesting FullCalendar as you replied. It's a great option. You just need to provide it with the JSON it needs and it works quite well.
  4. Excellent update. One minor nitpick about the overrides tab. When a field has been added to a RepeaterMatrix, can you have it show the Matrix Type Name (such as "gallery") instead of (or in addition to) the Matrix Type ID ("matrix4"). It would be much clearer that way.
  5. I want to prevent the creation of a field named 'fake'. What would be the correct hook in ProcessWire to do this?
  6. @NoremPload ProcessWire 3.0.142 (which is a dev version and very recently released) brings in the ability to have custom fields for images. I personally had some issues with this ImageExtra plugin and stopped using it a while ago (it's been a few years). Also the author is no longer working with ProcessWire so there's also that. I'd recommend putting in the extra work to do it the new, native way: https://processwire.com/blog/posts/pw-3.0.142/
  7. <?php namespace ProcessWire; class MyCoolModule extends WireData implements Module, ConfigurableModule { public function __construct() { $this->myvar = $this->wire('pages')->get(2)->name; // problematic for some reason } I have the above code in my module. However it throws this error: Fatal error: Uncaught Error: Call to a member function get() on null. Why is this the case?
  8. One work-around is to use this package, which I've used with success: https://github.com/tijsverkoyen/CssToInlineStyles
  9. Related: https://github.com/processwire/processwire-issues/issues/928
  10. This doesn't seem to be a problem with PW 3.0.140 as far as I can tell.
  11. I experienced this issue and the fix was related to JavaScript loading order.
  12. I see that if I enable auto-join for the field, then it circumvents the issue. So that's one solution.
  13. I have a Page field and in ProcessWire, I can get values from it like this: $page->my_page_field; // returns the ID $page->my_page_field->title; // return the title Given my particular situation, I'm hitting an infinite loop as I documented here a few years ago: https://github.com/ryancramerdesign/ProcessWire/issues/1962 Is there a way to ONLY get the raw ID of the assigned page without ProcessWire getting all the attributes of that page leading to the loop?
  14. If the field being hooked is inside of a repeater, how can I get the repeater's page id?
  15. I don't use a Mac but I've heard great things about Quiver: https://happenapps.com/
  16. I'm using this now on a site that needs that extra level of metadata. It's working great. Thank you.
  17. https://craigmod.com/essays/fast_software/
  18. https://blog.theodo.com/2019/07/vscode-php-development/
  19. I'm looking to improve my editor (VSCode) in a way whereby it will tell me the value of a ProcessWire setting() value that's been defined in another file as I write an override setting. Let's say I have a file called /site/templates/settings-default.php with the following: setting("my-div", "my-default-class"); And I have another file called /site/templates/settings-override.php with the following: setting("my-div", "my-override-class"); As I'm writing that specific line in "settings-override.php", is it possible through some sort of auto-suggest / intellisense for it to tell me the value of the setting in "settings-default.php" so that it provides context in realtime as I write the override setting? This would prevent me from having to switch between the two files in my editor and improve my workflow. Any suggestions would be appreciated.
  20. A sneak preview of a new page builder concept that I'm close to completing. I'll write more about this in coming weeks, but this video demonstrates a lot of unique things going on:
  21. Yes but that doesn't work for some reason. I believe it may have to do with partials being involved.
  22. One little hackish way around this is to redirect to the same page with "?livepreview=1" appended to the URL: <?php namespace ProcessWire; if(!$_GET['livepreview']) { $session->redirect($page->url."?livepreview=1"); } Good enough for my use-case.
  23. I have PageFrontEdit enabled. I have a template that includes a bunch of partials. Those partials contain the PageFrontEdit tags in the following format: <edit field="body" page="<?php echo $page->id; ?>">...</edit> This is all working well, however I have a particular template whereby I don't want Frontend Page Editing to be activated at all, as if you were logged out. https://processwire.com/docs/front-end/front-end-editing/ What's the best way to disable it for a particular template? Is there a proper hook for this perhaps? Or some hackish JS approach?
  24. I follow Linux desktop trends quite a bit. This post has got me thinking if it's time for Linux on the desktop for me despite MS innovations. I gave it a bit of thought and I think I can make it happen, even if I have to run Adobe CS through a VM. I'm much more comfortable with the idea now that I've been using WSL funny enough (also since I install Linux for customers every now and then... Ubuntu, RHEL, CENTOS, Suse). I'm thinking Arch w/ i3, VSCode, ranger and a bunch of text user interface apps, bash scripts, etc. Minimalism as much as possible, kind of like ProcessWire.
×
×
  • Create New...