In the 302nd issue of ProcessWire Weekly we're going to dig into ProcessWire 3.0.151, introduce a new third party module called PrivacyWire, and showcase some interesting ProcessWire highlights from the past week or so. Read on!
Welcome to the latest issue of ProcessWire Weekly! This week we're going to kick things off by summarizing the latest processwire.com blog post from Ryan, in which he shares details regarding two new core features available as of ProcessWire 3.0.151: predefined image sizes and translation fallbacks.
In other news we'll introduce a brand new third party module focusing on the topic of cookie consent: PrivacyWire. There's also a pretty long list of other highlights, such as modules and tutorials, so be sure to check those out as well — and, finally, we've got a splendid new site of the week belonging to a Belgian company called Huysman Yacht.
Thanks to all of our readers for being here with us again, and as always, any feedback is most welcome – please don't hesitate to drop us a line if there's anything in your mind you'd like to share with us. Enjoy our latest issue and have a great weekend!
Latest core updates: ProcessWire 3.0.151
This week's processwire.com blog post introduces ProcessWire 3.0.151 — our latest dev release, which includes a couple of new features: predefined image sizes and fallback translations. Translation fallbacks were briefly covered in last week's ProcessWire Weekly (#301), while predefined image sizes are a brand new addition.
In a nutshell translation fallbacks provide a way to declare in template or module code that "this text has changed for the primary language, but other languages can still use existing translations for the time being":
<button type="submit" name="submit"> <?= __([ 'Click here to send now', 'Submit' ]) ?> </button>
This is quite useful if you can't update all the translations right away — perhaps you're relying on someone else to do that, and they're not available right away, etc. — or want to make non-critical improvements to existing texts without any unnecessary hassle.
As a module developer myself I can definitely appreciate this: normally if I'd change a translation in one of my modules any existing translations would break right away, but this way I can introduce incremental updates without necessarily forcing existing module users to update their translations.
Predefined image sizes
Predefined image sizes are a way to configure commonly used image sizes — and other settings! — for your images in one place, and then reuse them as many times as you need to. This makes it easier to keep things consistent, and if things need to be updated, it's much easier to do.
Predefined image sizes are defined via $config->imageSizes array:
$config->imageSizes = [ 'landscape' => [ 'width' => 600, 'height' => 300, ], 'portrait' => [ 'width' => 300, 'height' => 500, 'quality' => 80, 'suffix' => 'portrait', ], ];
Note that while it's often enough to just define width and height, you can also set any other ImageSizer settings here — including, but not limited to, quality, suffix, cropping, and upscaling behaviour.
For more information, examples, and things to keep in mind when applying this week's updates to practice, be sure to check out the weekly blog post from Ryan. Thanks!
New module: PrivacyWire
PrivacyWire is a new module that adds support for opt-in cookie management — or, in other words, lets the user decide which cookies they want to allow: just the necessary ones (required by the service to function), statistics, marketing, and external media.
PrivacyWire provides a rather extensive set of configuration options:
- You can choose which specific cookie groups are currently used on your site, and what their visible labels should be.
- You can choose to respect the Do Not Track browser setting, automatically enabling only the necessary cookies.
- And, finally, you can increment the version number, forcing users to revisit their cookie settings (a very useful feature in case you add new scripts etc.)
Once you start adding scripts to your site that would result in new cookies — such as injecting the Google Analytics code — the module provides a mechanism to only load them if they are indeed sanctioned by the user:
For more details be sure to check out the dedicated PrivacyWire support forum thread, and if you'd like to give this module a try, you can clone or download the module files from the PrivacyWire GitHub repository.
Weekly forum highlights, tutorials, and other online resources
Here's a list of support forum highlights and other useful and/or interesting resources. As always, please let us know if there's anything important we've missed, so that we can include it in one of our future issues.
- First of all, here's a sneak peek into a very interesting new module from BitPoet: CacheRedis. We'll cover this one in more detail in our future issues, but the long story short is that it's a module for caching content into a Redis data store.
- Next up is a tutorial for setting up a (pretty) easy A+ content security policy (CSP) for ProcessWire; big thanks to Chris Bennett for simplifying a seemingly complex topic! Note that anyone interested in this topic might also want to check out the Markup Content Security Policy module from NB Communication Ltd.
- Everyone likes a happy story, right? If this sounds like you, definitely go check out the update on running blog sites using ProcessWire thread, from which you'll find a summary of observations made while running two blog sites, GoodKidsClothes and FlipFall, on ProcessWire. Great stuff!
- Another showcase post to check out would be this update from Macrura on the Aaron Copland case story, in which you'll get a nice glimpse on some of his admin views — including a really neat dashboard setup.
- Last but not least, there's an update on one of our most anticipated modules from past year, which — sadly — has hit a bit of a snag: DesignMe, the module that was going to provide really slick features for visually setting up edit screens, has been discontinued. There's a silver lining, though: the module files are available for anyone to download, so feel free to grab a copy and see it for yourself. (Perhaps we'll even find a new developer to continue the work?)
If you're interested in ProcessWire news, discussions, and updates, there's always something going on at the support forum. Since we're only able to include a tiny selection of all that in our weekly updates, head down to the forum for more.
Site of the week: Huysman Yacht
Our latest site of the week belongs to Huysman Yacht — a Belgian company specialized in services for yachts. Developed by Nicolas Grande, the website currently contains details of the company and their services, while a sales portal for yachts is planned as a future addition.
The design of the Huysman Yacht website could be described as stylish and "Airy": plenty of light shades and unobtrusive colors, Typography has a very classy feel to it, and white space is used generously. Combined with some well-placed transition effects, gorgeous images, and quality content, the end result is both peaceful and appealing at the same time.
According to the sites directory entry this multi-lingual website was developed fairly quickly using ProcessWire's capabilities, and has a user-friendly admin portal. The front-end doesn't seem to use any full-featured front-end framework (as far as we can tell), but behind the scenes this site is utilizing two familiar Pro modules: ProCache and FormBuilder.
Thanks to Nicolas for sharing this project with us — great work from everyone involved!
Stay tuned for our next issue
That's all for the 302nd issue of ProcessWire Weekly. We'll be back with more news, updates, and content Saturday, 29th of February. As always, ProcessWire newsletter subscribers will get our updates a few days later.
Thanks for staying with us, once again. Hope you've had a great and productive week, and don't forget to check out the ProcessWire forums for more interesting topics. Until next week, happy hacking with ProcessWire!
Post a comment