Jump to content


  • Posts

  • Joined

  • Last visited

  • Days Won


Pixrael last won the day on April 29 2020

Pixrael had the most liked content!

Profile Information

  • Gender
  • Location
    Florida, USA

Recent Profile Visitors

4,210 profile views

Pixrael's Achievements

Sr. Member

Sr. Member (5/6)



  1. To make a POST request using the Fetch API, you need to pass the 'method: POST' to the fetch() method as the second parameter: https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API/Using_Fetch | https://reqbin.com/code/javascript/ricgaie0/javascript-fetch-api-example fetch('https://domain.com/api', { method: 'POST' }) .then(resp => resp.json()) .then(json => console.log(json))
  2. If you still want to review your code, you can also use regular php code in your Processwire projects. Check google for options: https://www.google.com/search?q=php+malware+code+scanner
  3. This error is related to Processwire, not to the module. Check the documentation for the Repeater field in the section "Using the API to add or remove repeater items": https://processwire.com/docs/fields/repeaters/ You can also check this post that talks about the same problem: https://processwire.com/talk/topic/16276-remove-repeater-item-by-page-id-rather-than-item-id/
  4. Alternative, if PHP 7.4+ you can use the null coalescing assignment operator: $browserVersion = $t[0] . "." . $t[1] . $t[2] ??= '';
  5. Are you using innoDB? read: https://processwire.com/blog/posts/using-innodb-with-processwire/
  6. Me too, I always try to import the data using the Ryan module https://processwire.com/modules/import-pages-csv/ .. if not fit the case, then I write some code to create the pages
  7. I'm sorry. Since you said you were a user of Form Builder, which is a licensed product, I assumed you had access to the forum section for users of registered products. In order to see the post I published here, you must register with your purchased copy of Form Builder to access this section: https://processwire.com/talk/forum/27-vip-support/ you can manage your purchases here: https://processwire.com/talk/clients/purchases/
  8. I think in this case PW will generate all that code because the element in the "optional" section is not actually empty. For the region definition, I always use the pw-region tag (placeholder region) instead of the html tags, because the pw-region tags are always removed from the final output. I would do the following: in _main.php <pw-region id="section2"></pw-region> in templatefile.php <pw-region id="section2"> <?php if($content1): ?> <section class="section"> <div class="container is-fluid"> <div id="content2"> <?php echo $content1; ?> </div> </div> </section> <?php endif; ?> </pw-region> .. But there are many ways to do this .. thanks to Ryan 🙂 ..for pw-optional option should be like this in the template file: <section id="section2" class="section" pw-optional> <?php if($content1): ?> <div class="container is-fluid"> <div id="content2"> <?php echo $content1; ?> </div> </div> <?php endif; ?> </section>
  9. I had already suggested to @kongondo that he could use Omnipay Library as part of the Padloper module. But I don't know if this Library is a good choice, since no one here in Processwire has ever implemented it as a module.
  10. What if… Visual Studio Code became the editor of in-browser Developer Tools? www.youtube.com/watch?v=77qEmDlFtzg https://www.youtube.com/watch?v=g_TpkkmYzXs
  11. Yes, it works with this three lines in the home template file, but you must enable the urlSegments in the home template.. now the AppApi configuration still have the "domain.com/api/users" as endpoint but "domain.com/users/" works too.. if you try "domain.com/foo/" the api respond with a 404 json response
  12. @kongondo This does not work, these new hook functions only work when the requested URLs are not mapped directly to a page and the home page is "always there". @Sebi Could it be possible to use the homepage template file to "wireIncludeFile" the routes file, or to directly pass the request to your module, ex. initialize a module static function with the input object? AppApi::Execute($input);
  • Create New...