Jump to content


  • Posts

  • Joined

  • Last visited

  • Days Won


Everything posted by jploch

  1. Thats a great concept! I have to think about this. You can also use a page reference field in a PAGEGRID block template to store a reference to a PAGEGRID item page. This allows you to render a PAGEGRID item on multiple pages (e.g. useful for headers or footers). If you change the content or styling of the referenced page it will update across your whole site.
  2. @MarkE More options/tools are always great. But there might be some overlapping between our modules, I will send you a test version and you can see for yourself. PAGEGRID is no longer limited to CSS grid, it also supports flexbox and most common CSS properties. It's like ProcessWire and webflow had a baby, but that baby is still very young 😛 Maybe this?
  3. The PAGEGRID beta will be released next week! If you want to help testing this module and try it yourself for free, please apply for the beta test.
  4. I am happy to announce that I will release an early beta version of my pagebuilder module PAGEGRID to selected users. The main focus of this testing is to make PAGEGRID production-ready. There is also an official website now. And a small, but growing documentation page. Both are works in progress, so expect some updates coming soon. You can find the initial post here (it's a little outdated). In order to organise this testing, I will need to gather some information via Google Forms. I need your email address in order to inform you how to access PAGEGRID as well as for other necessary communication. I will not use your email address for any other purposes nor pass it on to any third parties. You need to have an account on this forum to apply. Apply here if you want to be part of the free beta test. Please note that there is a limited number of test slots available. This form will close in 10 days.
  5. @thausmann Thanks for your quick reply! This was very helpful! It seems like filePutContents works great, but you have to give it the full path: <?php //create ics file $icsgen = wire()->modules->IcsGenerator; $icsgen->set('date', '2033-12-24 12:00'); $icsgen->set('dateEnd', '2033-12-24 14:00'); $icsFileContent = $icsgen->getString(); $icsFilePath = wire()->config->paths->assets.'files/'.$page->id.'/event.ics'; // use full path to create the file $icsFileUrl = wire()->config->urls->assets.'files/'.$page->id.'/event.ics'; // use relativ url to set the link target wire()->files->filePutContents($icsFilePath, $icsFileContent); ?> <!-- Link to file --> <a href="<?= $icsFileUrl ?>">ICS File</a>
  6. Hi! This is exactly what I need for a project I am working on. But the module is not generating any files for me. Maybe I am doing something wrong? Here is my code (testet locally on laravel valet and on a shared hosting server): function icsLink() { $icsgen = wire()->modules->IcsGenerator; // set single properties (date strings) $icsgen->setArray(array( 'date' => '2033-12-24 12:00', 'dateEnd' => '2033-12-24 14:00', 'summary' => 'Event title', 'description' => 'Event description', )); $icsPath = $icsgen->getFile(); $out = '<a href="' . $icsPath . '">Merken</a>'; return $out; } The function returns the link successfully, but when I click the link I get a 404. While the link points to a file (site/assets/cache/WireTempDir/.icsgenerator/0/ics-1663226011-413791867.ics), it seems like the file is never created. Any ideas?
  7. Another thing with this module is, that it's not triggering a module resfreh automatically after installation. Depending on the module this can crash the installer at the last step. When I put this code in my template file it works (not a good fix): if ( !$modules->isInstalled('InputfieldPageGrid') ) { $modules->refresh(); } I also tried to put this code in the finish.php file inside the exportet site->install folder, but this seems to be called to late. @ryan can you please look into this, as I would like to share my site profile for my new module Iam working on. Would be awesome if this can be fixed, as others also seem to struggle with this.
  8. Thanks! @Jan Romero and @zoeck. Berhards hook worked for me! Nice! It doesn't really matter now, but this was not working somehow: $this->addHookAfter('ProcessPageAdd::processQuickAdd', function (HookEvent $event) { $page = $event->arguments(0); $page->removeStatus('statusTemp'); $page->save(); });
  9. Hey folks. I have set the familiy tab to only allow one template for chldren and also set the childNameFormat. Now the user can create a page in one step. However the new page is unpublished by default and the user needs to press the "publish" button to publish, wich is usually what you want. But for my usecase I want to force the client to allways publish without the need to press the button. Is there a way to auto publish the new page? I tried it with an after save hook, and the page is then published but has a strange flash icon and seems to be corrupted.
  10. @MarkE I just found out, that it's easy to create permissions that are template based. The permission name must start with "page-". After you check the box on a template "Mangage edit access" (screenshot above), it becomes selectable under Access->Roles->Yourrole. You just have to click on the little arrow to open the settings first. Nice!
  11. Is ist possible to make locked pages editable for superusers? If a page ist locked I want to prevent the client to edit it, but would like to make changes myselft without unlocking and then locking the page again.
  12. @MarkE It's a little complicated to explain 🙂 I Am working on a pagebuilder module, that makes it possible to visualy compose a page. The page structure is defined by the items you add to your page. PageGrid creates a hidden page for every item that gets added to it (similar to how PageTable or Repeater Matrix work). Each item (a page) is based on a block template. A template can have multiple fields to hold your data (native ProcessWire templates and fields). Each item has an edit link that opens that page in an overlay, some fields also have inline edit capacity. Now I want to be able to have my own permissions beside page-edit to control if the edit link of that item is visible or not to certain users. The page-edit permission would enable inline editing (or editing in general) und my new permission would display the edit link. Hope that makes sense. I think this could also be achived with multiple roles, so if use has role "edit-items" and the page-edit permission for that item template it will display the edit link. But I was just curoius if I could create those template permissions myself.
  13. @MarkE Thanks for your answer. I was looking for a way to create a new permission that the user can than enable per template in the backend. But I don't think it's possible. See Screenshot:
  14. Hi folks, is it possible to add custom template permissions like page-edit, e.g. page-edit-mymodule? For a module I am buildinmg I want to be able to fine tune some functionalities on template level.
  15. @Jan Romero that made it clearer thanks! It looks like LoginRegisterPro could work well. It also handles the unsubscribe funtionality.
  16. this module is still a great time saver. Today I tried to use the feature to automatically load the script. But it's not working, even if I have the markup with the data-srcset rendered on the page. It's working if I load it manually.
  17. Most likely less than 100 per day. There will propably have to be a verification of some kind to prevent spam? Maybe limit the amount of posted emails per session?
  18. @bernhard thx for your quick reply! Maybe I am thinking about it the wrong way, but how would the script be triggerd if not with a cronjob or something? How/when would you execute the code that checks the date and sends the emails Subscription would be a "nice to have" feature. My performance concern above was about delivering/sending the emails from the shared hosting server. I dont't think I could use external services like MailChimp to send these mails, because they will have dynamic content in them (event name, even date, etc.). So WireMail seems like the way to go here. For the mail layout I will use css tables and inline styles, but the layout will not be that complicated 🙂
  19. Hey folks, I am working on a client website, which lists some events. Events are just pages and each event has a date. Now the client wants a solution, where people could click a button for each event to put it on a "reminder list". After they collected all the events they have interrest in, they can enter an email and get a message a day before each event happens. Since I never had the need to develop something like this before. Is there someone who can share a good approach to this? I worked with FormBuilder before and there is also ProMailer (which I never used before), but not sure if that would help here. I also I took a look at WireMail Class which seems quite easy to use. I think the website runs on a shared hosting server, so not sure if the server could even handle it. But I could talk to the client to upgrade I guess. My approach would be like this: The email will be saved to each event page the person was interested in (maybe each event page has a field for this, where multiple emails could be stored). These Emails will not be seen by regular guest users. There will propably have to be a verification of some kind to prevent spam? There need to be some script/cronjob that checks if an event will happen soon (this seems complicated). Then an email will be send to every email that is accociated with that event. To comply to GDPR laws, the emails have to be deleted after the notification was send. (The client would like to keep them for future newsletter stuff, but than a unsubscribe button in the email isneeded). Any ideas or feedback is welcome. Thx in advance!
  20. @wbmnfktr Thx! To be clear, the css my module generates is rendered in a style tag in the docuemnt head, so no file is requested here (that is the major part of the css needed to render the page). But the css files from the templates, which are optionally (only loaded if the developer puts them in the template folder and names them like the template file) are added as links. I think of them as a quick way to set some default styling. Do you think it would be better for performance to inline the content of these css files as well? My concern is that this would create more work for the server to read these files every time the page gets rendered. It might not be a big problem with HTTP/2. So far the performace seems to be great (100-95 lighthouse score with cache enabled). However I only testet with 4 extra files (files are about 10-15KB). So I can imagine that it would cause some performace loss with more files. But it might not be worth the trouble..
  21. Hey folks. My soon to be released pagebuilder modules has a feature, that it will automatically load css files. A page can be composed by multiple block items and each block has a template file. For each block that is added to a page, the module also looks for a css file with the same name as the template file and loads it, if it's avalable and not already loaded. This works great and it only loads the css if it is really needed. But I am a bit worried of the performance, since there is a request for each file (if not cached already). Iam not sure if the ProcessWire cache or ProCache can help here? So now I am looking for a good way to combine the files into one request/file and also enable that file to be cached. The problem I see here is that every page can load different files, or load them in a different order, so even if two pages share most of the same files, the combined files for these pages would be different and a request for each page would be needed, even if the file of one page is already in the cache. Maybe someone has an idea how to optimise this? Do you think it's better to combine the files or just load and cache those smaller files?
  22. @theo Hi Theo. Are you still working on this? I will release my pagebuilder module as a closed beta soon and plan to release it as a comercial module later. My module is NOT based on your module and is not using any of your code (it also works different than yours). But I like the name "PageGrid" because it really fits my module and also makes sense in the context of ProcessWire. So my question would be if it is ok to use that name for my module or if you plan to release your module with that name any time soon?
  23. the layout functionality is creating the initial page structure, but It's not creating a template with fields on the fly, if that's what you mean. The page structure is defined by the items you add to your page. PageGrid creates a hidden page for every item that gets added to it (similar to how PageTable or Repeater Matrix work). Each item is based on a block template. A template can have multiple fields to hold your data (native ProcessWire templates and fields). You can use all the fields ProcessWire provides or add even more fields using external Fieldtype modules. But you have to create these templates yourself, as well as the markup that gets rendered. If you want to get started quickly, I also developed some block modules that you can install optionally, these will create templates, fields as well as a template files automatically, without the need to write any code. These blocks will cover the basic needs for most websites (containers, text, images, video, slider, maps, etc..). More information and documentation is coming soon. Until then have a look at the first post 😋
  24. I might do that, but I am still not sure what's the best way to implement this. I made changes to the PagesExportImport Module, but I think it would be better to implement this in the core PagesExportImport Class. That would make the feature available to the API and other modules as well. But I am not sure how to do that, because to import the meta data, the pages must be created first, so the code might only work in the module, after the pages are created. EDIT: I made a PR
  25. I had a look at it and it wasn't that complicated to implement. Here is a version of the ProcessPagesExportImport module that support export/import of $page->meta(): https://github.com/jploch/ProcessPagesExportImport Would be nice to have this in the core.
  • Create New...