Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 11/25/2021 in all areas

  1. Hello! I wanted to share my latest website with you. https://www.reese-moden.de It's called "Reese Modehäuser" (beware! It is a german speaking website...) which loosely translates to "Reese Fashion Boutiques". A translator is not needed at all. The whole content is "picture-heavy" and there is not much text. I wanted to create a fashion boutique site that has a very crisp and clear look with huge magazine-like images that showcase the current fashion trends that are for sale. The page also features a simple blog/news system for posting new content. Because there are lots of large pictures I wanted to keep those loading times small. So the whole site makes full use of the processwire WEBP image support. In order to make responsive images in WEBP format available this site makes use of @nbcommunication fantastic PageimageSrcset module: https://github.com/nbcommunication/PageimageSrcset I can highly recommend this module! Nowadays everyone has an Instagram page. So I included an Instagram feed directly to the site, again with the help of @nbcommunication and his Instagram Basic Display Api Module: https://processwire.com/modules/instagram-basic-display-api/ This is another fantastic module which I am looking forward to use on other pages. Other modules I used on this site (als recommended): - AIOM+ (https://github.com/matjazpotocnik/ProcessWire-AIOM-All-In-One-Minify) for the compression of all JS and CSS files - Wiremail SMTP (https://processwire.com/talk/topic/5704-module-wiremailsmtp/) for sending mails. I am using a custom form builder system I created myself with some repeater fields. - Redirects (https://processwire.com/talk/topic/148-release-redirects/
    5 points
  2. It looks like has_parent now supports multiple pages and I think it has served all my needs around this. What can't it do in your use case?
    3 points
  3. I went ahead and pushed the latest release. I tested uninstalling LanguageSupportPageNames while still having LanguageSupport and it works as expected, outputting only the default language URL. I also namespaced the QR code php generator and it should help solve your issue with TOTP. Let me know if you notice anything else @adrian and otherwise thanks for your feedbacks!
    3 points
  4. https://www.mamp.info/mamp-friday/ I'm a MAMP Pro + Nano user, I can recommend them. Especially MAMP Pro saves me a lot of time, with features like: 1 click site cloning 1 click site spanhost & restore 1 click SSL config zero configuration Mailhog and more...
    2 points
  5. Do you mean like relying on urlSegment instead ? Implementing your feature I actually came across a situation where it would output the same URL twice because the page name of the root page wasn’t defined in the non-default language. So what I did is to add a check to make sure to not output the same QR code twice (plus the default language will just be labeled “URL”). Does it sound like it would help in your situation ? Even if not checking for LanguageSupportPageNames.
    2 points
  6. Nice one... it's amazingly fast even though there are tons of images. TTFB is almost instant. Where is the site hosted and what kind of hosting is this? Standard webhosting isn't that fast usually. Another funny side note... I know this company and actually have bought some of my suits and wardrobe there. Funny how small the world is. That's weird!
    2 points
  7. I just published a new release of the Fieldtype and updated the original post with a copy of the README. I think it's pretty complete at this point: you can output several QR codes by specifying the sources in the field's config (limited to httpUrl, editUrl and PageFiles/PageImages fields), it supports multi-languages by outputting as many QR codes for httpUrl as there are languages (only those visible to the user when output in the front-end), there is now a static function to generate any QR code you want and there are several functions you can hook at to adjust according to your needs. Let me know if you notice anything strange or a bug!
    2 points
  8. (once again I was surprised to see a work of mine pop up in the newsletter, this time without even listing the module on PW modules website ?. Thx @teppo !) FieldtypeQRCode Github: https://github.com/eprcstudio/FieldtypeQRCode Modules directory: https://processwire.com/modules/fieldtype-qrcode/ A simple fieldtype generating a QR Code from the public URL of the page, and more. Using the PHP library QR Code Generator by Kazuhiko Arase. Options In the field’s Details tab you can change between .gif or .svg formats. If you select .svg you will have the option to directly output the markup instead of a base64 image. SVG is the default. You can also change what is used to generate the QR code and even have several sources. The accepted sources (separated by a comma) are: httpUrl, editUrl, or the name of any text/URL/file/image field. If LanguageSupport is installed the compatible sources (httpUrl, text field, ...) will return as many QR codes as there are languages. Note however that when outputting on the front-end, only the languages visible to the user will be generated. Formatting Unformatted value When using $page->getUnformatted("qrcode_field") it returns an array with the following structure: [ [ "label" => string, // label used in the admin "qr" => string, // the qrcode image "raw" => string, // the raw qrcode image (in base64, except if svg+markup) "source" => string, // the source, as defined in the configuration "text" => string // and the text used to generate the qrcode ], ... ] Formatted value The formatted value is an <img>/<svg> (or several right next to each other). There is no other markup. Should you need the same markup as in the admin you could use: $field = $fields->get("qrcode_field"); $field->type->markupValue($page, $field, $page->getUnformatted("qrcode_field")); But it’s a bit cumbersome, plus you need to import the FieldtypeQRCode's css/js. Best is to make your own markup using the unformatted value. Static QR code generator You can call FieldtypeQRCode::generateQRCode to generate any QR code you want. Its arguments are: string $text bool $svg Generate the QR code as svg instead of gif ? (default=true) bool $markup If svg, output its markup instead of a base64 ? (default=false) Hooks Please have a look at the source code for more details about the hookable functions. Examples $wire->addHookAfter("FieldtypeQRCode::getQRText", function($event) { $page = $event->arguments("page"); $event->return = $page->title; // or could be: $event->return = "Your custom text"; }) $wire->addHookAfter("FieldtypeQRCode::generateQRCodes", function($event) { $qrcodes = $event->return; // keep everything except the QR codes generated from editUrl foreach($qrcodes as $key => &$qrcode) { if($qrcode["source"] === "editUrl") { unset($qrcodes[$key]); } } unset($qrcode); $event->return = $qrcodes; })
    1 point
  9. Can it be ProcessWire could be listed there? Do we have anything to contribute?
    1 point
  10. I used to "play" with VMs but I did not find them to be particularly useful, but that is a subjective topic, of course, as it depends on one's needs. Besides, I do not have Windows since I am not fond of it either. Anyway, for anyone who likes MAMP, I think saving some money on it cannot hurt ;)
    1 point
  11. That is why I like VirtualMachines. It let's you bring together the best of different worlds. Oracle VirtualBox is there for Windows, Linux and for Mac also. https://www.virtualbox.org/wiki/Downloads
    1 point
  12. I am a Laragon5 User + HeidiSQL + WinSCP , all 3 in a virtual machine, saves me a lot of time , fast, powerful, stable ... and for free
    1 point
  13. Wow it seems the world is getting smaller and smaller ? I never thought that there are people around here who know this company. But it seems people who like processwire have a good taste overall ? The hosting service is Domainfactory. I work on a freelance base and am hosting multiple sites via a reseller hosting solution that Domainfactory offers. The server performance you get there is a little bit better that the usual hosting package you would chose when running a single site only. I am running a few other processwire sites on other servers and can confirm that everything - even the backend - is really fast on this one. Can't wait to put the next site online.
    1 point
  14. I just implemented this inside a autoload module and discovered that this hook only works in application ready state. So if you are utilizing this inside a module, you need to call the hook inside ready() method like this public function init() { // handle render of correct page from urlSegements $this->addHookAfter('ProcessPageView::execute', $this, 'hookPageView'); } public function ready() { // need to call this in ready. Not working in init() $this->pages->addHookAfter('Page::path', $this, 'hookPagePath'); } public function hookPagePath(HookEvent $event) { $page = $event->object; // page ROW and all children recursively if ($page->id == 1043 || $page->rootParent->id != 1043) return; $orgPath = $event->return; $pathSegments = explode('/', trim($orgPath, '/')); // $pathSegments[0] is language segment // get rid of $pathSegments[1] 'row' unset($pathSegments[1]); $newPath = '/' . implode('/', $pathSegments) . '/'; $event->return = str_replace('//', '/', $newPath); } public function hookPageView(HookEvent $event) { $page = $event->page; // only act on homepage if ($page->id != 1) return; // get last urlSegment to retieve page with that name if (count(input()->urlSegments())) { $wantedName = sanitizer()->pageName(input()->urlSegmentLast); $wantedPage = pages()->get("name={$wantedName}"); if ($wantedPage && $wantedPage->id) { $event->return = $wantedPage->render(); } else { throw new Wire404Exception(); } } } If knew this earlier it would have saved me some time and frustration...
    1 point
  15. I'm excited to buy this! I was on vacation (first time in a very long long time) and missed the sign up opportunity to test the alpha. I guess I'll catch it on the production release!
    1 point
  16. Re: this, it seems to be because constants declared using define() do not respect namespace unless explicitely specified. One solution though seems to be to replace define() by const declarations. I'll try to do that tomorrow (also what you suggested is done but I want to also fix this first).
    1 point
  17. I resolved the problem in a bit of an odd way. The 'deprectated' version of the module that I was using mostly worked, except links to site admin somehow ended up broken. Soma's module didn't work at all. I was able to patch together some bits from the newer module to ignore admin urls, and that got the older module working again fine on my site(s). It got it working for 3.0.184 but I can confirm it broke again with 3.0.189.
    1 point
  18. Hey @mel47 What you mean by can't see data? Is the grid displayed, but the cells are empty? Is nothing displayed? Do you get Javascript errors in the dev console or maybe PHP errors (turn on debug mode). Can you share the JSON response?
    1 point
  19. @bernhard, I think that shouldn't be a problem. I also have other updates on the to-do list. I'll try to push it this year during my Christmas holiday. Unfortunately, I really don't have time at the moment to roll that out sooner.
    1 point
  20. Great read! Thanks @szabesz. Hopefully we get this right. We can learn a lot from Apache, both what ASF have got right and the things they didn't get right. I loved this one ?:
    1 point
  21. Confirming that the expressions of interest is now closed. I will collate the responses and get back to all who registered. I am working on a getting started frontend that will help with the testing. I am also working on a minimal API documentation to help you put it all together. Thanks to all who have responded and/or have an intention to support this work in the future ?.
    1 point
  22. Good ideas. I think both of the things mentioned (autosave only while live preview active) and some kind of obvious toggle/checkbox would both be good to have. I'll plan to add.
    1 point
  23. In other news: Color-coding content blocks is such a great addition. Even those who don't use the backend that often find the right spot way easier now. Thanks @Ivan Gretsky for the idea and @ryan for adding this to the latest dev branch.
    1 point
  24. Okay so I boiled it down to this: Apparently there's no need to have markupValue() return anything else other than $value as it most likely calls wakeupValue() in any case. Also I went ahead and removed the part hooking into the render() function of the InputfieldMarkup. This removed the double call on the back-end while keeping the front-end call working. Thanks again, I'm pushing the update right now!
    1 point
×
×
  • Create New...