Leaderboard
Popular Content
Showing content with the highest reputation on 05/26/2022 in all areas
-
v. 1.2.0 is now released Twitter tags will be rendered by default Added support for image alternative text using custom fields in images Added support for inheriting image from parent pages (including home page) Added support for fallback page for image. If the image cannot be found from the current page (and possibly enabled inheritance fails), the module will try to find the image from the given page. You can use this to define default image for all pages. Fixed crash when passing an empty Pageimages object as an image Fixed crash when supplying an invalid image width or height Note that module now requires PW 3.0.142 or later, as custom fields for image and file fields were introduced in that version.3 points
-
We had a smooth rollout of the new main/master version 3.0.200 last week (read all about it here). If you haven't upgraded yet, consider doing so, this new version is a great upgrade. I'm going to add the 3.0.200 tag shortly after I finish this post, which should trigger other services (like packagist) to upgrade. I've had a new client project in the pipeline that I've been waiting to start till the new main/master version was out, so this week I started that project. Pete and I are working together on it, like we've worked on others before. It involves taking a popular WordPress site and rebuilding it completely in ProcessWire. I've done this a couple times before, but this time it's bigger and broader in scope. I always find the large site conversions to be great learning experiences, as well as great opportunities to show how ProcessWire can achieve many things relative to WordPress, in this case. At this stage, I'm having to spend a lot of time in WordPress just to get familiar with the content, fields, etc., as well as in the theme files (php and twig). The more time I spend in these, the more excited I get about moving it into ProcessWire. For this particular site, moving from WordPress into ProcessWire is going to result in a big boost in efficiency, maintainability, and performance. Part of that is just the nature of PW relative to the nature of WP. But part of it is also that the WP version of the site is kind of a disorganized patchwork of plugins, code files, and 3rd party services, all kind of duct taped together in an undeniably confused, undisciplined and fragile manner. (Though you'd never know it by looking at the front-end of the site, which is quite nice). This has been a common theme among WordPress sites I've dug into. Though to be fair I don't think that's necessarily the fault of WordPress itself. I always enjoy taking a hodgepodge and turning it into an efficient, performant and secure ProcessWire site. I love seeing the difference it makes to clients and their future by taking something perceived as a "necessary liability to run the business", and then turning it into the most trusted asset. I think the same is true for a lot of us here. We love to develop sites because it's an opportunity to make a big difference to our clients… and it's fun. Ironically, if past history is any indicator, I seem to get the most done on the core (and modules) when I'm actively developing a site. Needs just pop up a lot more. I don't know if that'll be the case this time or not, but I do expect to have weeks with lots of core updates and some weeks with no core updates, just depending on where we are in the project. This particular project has to launch phase 1 by sometime in July, which is kind of a tight schedule, and that may slow core updates temporarily, but who knows. I'll share more on this project and what we learn in this WP-to-PW conversion in the coming weeks. Thanks for reading and have a great weekend!2 points
-
Hi @wishbone I fully understand your feeling. I came from a non coder background, too. If you are willing to pay for a working contact form. I suggest you to buy Ryan's FormBuilder. Gideon2 points
-
You need to get $inputfieldTextTags from the field itself: $inputfield = $page->getInputfield('tags_field'); $list = $inputfield->getTagsList(true); foreach($list as $item){ // echo tags ? }1 point
-
This is useful? https://processwire.com/api/ref/inputfield-text-tags/get-tags-list/1 point
-
ProcessWire 3.x markup module for rendering meta tags in HTML document head section. Note that this module is not a full-blown SEO solution, but rather a simple tool for rendering meta tags based on module configuration. Adding custom meta tags is also supported. Built-in meta tags The following meta tags are supported out-of-the-box: Document title consisting of page title and site name Character set Canonical Viewport Description Keywords Hreflang tags Open Graph og:title og:site_name og:type og:url og:description og:image og:image:width og:image:height Twitter meta tags twitter:card twitter:site twitter:creator twitter:title twitter:description twitter:image Facebook meta tags fb:app_id The full documentation with configurable options can be found here: https://github.com/Fokke-/MarkupMetadata Requirements: ProcessWire>=3.0.0 PHP >=7.1 Installation using Composer composer require fokke/markup-metadata Manual installation Download latest version from https://github.com/Fokke-/MarkupMetadata/archive/master.zip Extract module files to site/modules/MarkupMetadata directory.1 point
-
I think I will have a look at the changes on friday, if I find the time.1 point
-
Hey Philipp, have a look at this topic - seams to be nearly the same question you asked for: Many greets11 point
-
1 point
-
This new main/master version has more than 220 commits, resolves more than 80 issues, adds numerous new features, performance improvements and optimizations, and consumes HALF the disk space of our previous release— https://processwire.com/blog/posts/pw-3.0.200/ I've just merged the dev branch to the master branch so this new version is available now. I will add the 3.0.200 tag (which should trigger packagist and others) over this weekend or Monday.1 point
-
what about the module SimpleContactForm. https://processwire.com/modules/simple-contact-form/ Wouldn‘t do that what you want?1 point
-
We upgraded a big multi language site to 3.0.200 and to PHP 8* + MySQL 8 a couple of days ago, several thousands pages, lots of templates and fields (120MB DB). The upgrade went fine, and the site is running super fast! I didn't measure with tools, but just by reaching the URLs of some complex pages and you can see it loading waaay faster. The client could not be happier. ? Fantastic job, Ryan and the other contributors! Thank you, Sergio --- * I used RectorPHP to help upgrading my custom modules, which was nice.1 point
-
We check the stock trough an Ajax call each time the user selects an option. If it's not in stock anymore, the button "add to cart" stays not clickable. If it's in stock the user can add it to the cart. We also set an max in the quantity field, that's the same value as the stock is. Javascript clothing = { size: "", sex: "", product_id: "", init: function() { $('input[name="Size"], input[name="Sex"]').on('change', function (e) { clothing.size = $('input[name="Size"]:checked').val(); clothing.sex = $('input[name="Sex"]:checked').val(); clothing.product_id = $('#product_id').val(); if(clothing.sex && clothing.size && clothing.product_id) { clothing.getVariationId(); } }); }, getVariationId: function() { var url = '/api/?id=' + clothing.product_id + '&variation=clothing&size=' + clothing.size + '&sex=' + clothing.sex; $.ajax({ type: 'GET', url: url, success: function(result) { if(result){ var res = JSON.parse(result); if(res.success){ if(res.qty > 0){ $('#qty').prop('disabled', false); $('#qty').parent().removeClass('c-form-group-disabled'); $('#qty').attr("max", res.qty); $('#variation_id').val(res.id); $('#clothing .c-button').prop('disabled', false); $('#clothing .c-button').removeClass('c-button-disabled'); } else { $('#qty').prop('disabled', true); $('#qty').parent().addClass('c-form-group-disabled'); $('#qty').attr("max", 0); $('#qty').val(0); $('#variation_id').val(""); $('#clothing .c-button').prop('disabled', true); $('#clothing .c-button').addClass('c-button-disabled'); } } } }, error: function(jqXHR, textStatus, errorThrown){ } }) }, }; api.php <?php namespace ProcessWire; if(config()->ajax()) { $data = array( 'success' => input()->get('id') ); if(!input()->get('variation')){ return json_encode($data); } else { switch (input()->get('variation')){ case "clothing": if(!input()->get('id') || !input()->get('size') || !input()->get('sex')){ return json_encode($data); } else { $product_id = input()->get('id'); $size = input()->get('size'); $sex = input()->get('sex'); foreach (pages()->get($product_id)->product_variations as $v) { if (($v->size == $size) && ($v->sex == $sex)) { $data = array( 'success' => true, 'id' => $v->id, 'qty' => $v->product_quantity ); return json_encode($data); } } } break; case "default": return json_encode($data); break; } } Indeed we used the demo of @kongondo as a starting point.1 point
-
1 point