Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 10/25/2023 in all areas

  1. Hello friends, I was playing around with the clamp techniques used to provide progressive font sizing, and it has replaced flowtype.js in most projects. But one of the things that I really missed was the ability to scale based on container width - rather than full viewpoint width. I was also interested in trying to replace fittext.js and learned a very useful technique with reasonable browser support: https://codepen.io/solonmg/pen/ZEwGEay instead of using vw units, you can apply: container-type: size; container-type: inline-size; And then by dividing the character count of a line by 100 and applying the outcome to use cqw units instead of vw units, you get the same scaling type features. If you are trying to get that optimal character/word line length in a given column, this will certainly help! The same clamping limits that already exist based on viewport widths work for containers. I don't know if it makes sense to have separate clamping settings for display text (like headings) and body text, but this is just something I have been playing around with.
    3 points
  2. Last time it did, but I guess not being a complete failure this time is something to celebrate. Kudos to WordPress for doing the bare minimum! Here's a gold star ⭐
    2 points
  3. I have just released version 2 of RockMigrations: GitHub: https://github.com/baumrock/RockMigrations Modules Directory: https://processwire.com/modules/rock-migrations/ Please star the module on GitHub if you like it ? Are you unsure if RockMigrations is the right tool for you? @Jonathan Lahijani in a very nice PM ? Read the full post here Read the full post here Read the full post here QuickStart The example code uses bd() calls for dumping data. You need TracyDebugger installed! Put this in your site/migrate.php /** @var RockMigrations $rm */ $rm = $modules->get("RockMigrations"); bd('Create field + template via RM'); $rm->createField('demo', 'text', [ 'label' => 'My demo field', 'tags' => 'RMDemo', ]); $rm->createTemplate('demo', [ 'fields' => [ 'title', 'demo', ], 'tags' => 'RMDemo', ]); Reload your site and you will see the new field and template in the backend and you'll see the message in the tracy debug bar.
    1 point
  4. This is a great case for including a "Translate to All Languages" button on all language tabs! I didn't think about that. This is a great real-world example. I'll add that to the roadmap. Very awesome to see that feature solve an immediate need!
    1 point
  5. Ok so ALFRED will stay in RockFrontend, thx for letting me know @gornycreative and @MarkE That's not intentional behaviour and I've never experienced something like this. If you provide instructions on a fresh installation with step by step guide to reproduce the issue I can have a look into it.
    1 point
  6. Thanks, looks great already ?
    1 point
  7. @Spinbox if @kongondo isn't going to have a release for that feature soon, I'll finish working on the module I was creating ASAP and share it. I was/am 80% there with it, but got sidetracked with a large project. But happy to set dive back in and get on it. I'll await his response though before I spend time needlessly ?
    1 point
  8. Hi @kongondo, Do you have an update for the 'Gift Cards/Vouchers' feature and 'Discounts' feature? Thank you
    1 point
  9. FieldtypeListLinks If somehow found myself needing a means to associate items between two lists, and pages this time weren't the answer. So I started to develop this little Fieldtype/Inputfield. It lets you define two lists (let's call them "left" and "right") and declare a mapping between those. 1. Create your field and add options for the "left" and "right" select: 2. Set your labels and how many items it should show: 3. Edit your page and assign items: The module is still very much experimental and the API subject to change. However, I wanted to share what I have and maybe get some ideas and feedback before things get wired too tightly. The module and a little more documentation can be found in its GitHub repo.
    1 point
  10. I think that the new TinyMCE field offers you exactly what you need. You can configure the toolbar to only contain the controls you want. You can completely redefine the styles menu available and you can configure tags to be removed. Have a look at @ryan's post here.
    1 point
  11. TinyMCE inherits this class names from the Page Edit Image module, you can change these classes in the: modules -> configure -> ProcessPageEditImageSelect module
    1 point
  12. Here's a Google Maps WordPress plugin that takes advantage of needing a Google Maps Platform API key. They redirect the user to this page to promote their $12/mo. paid plan even though Google will charge you $0. They're happy to charge you up to $109/mo. for 10,000 views even though Google's platform affords 26,000 under their monthly free credits. Stay classy.
    1 point
  13. I think what happens is this: When you try to view [localhost/myprocesswiretestsite]/informations-generales/ processwire does not find any associated template and gives you a 404-Error. And your 404-Error-Page has the basic-page.php template. This is how it supposed to be. This happens also if you type in [localhost/myprocesswiretestsite]/qwer1234/.
    1 point
  14. I just tried and everything seems to work as expected if you set the correct import path (see docs https://scssphp.github.io/scssphp/docs/ ). I've added an example to the readme. <?php // for development you can put this in site/ready.php /** @var Scss $scss */ $scss = $this->wire->modules->get('Scss'); // watch all files in /site/templates/scss $watchFiles = $files->find( $config->paths->templates . "scss", ['extensions' => 'scss'] ); // set the import path so that relative @import statements work $scss->compiler()->setImportPaths($config->paths->templates); // compile SCSS to CSS if any of the watched files changed $scss->compileIfChanged( // create this file with the content from the uikit docs: // https://getuikit.com/docs/sass#how-to-build input: $config->paths->templates . "scss/uikit.scss", watch: $watchFiles, output: $config->paths->templates . "scss/uikit.css", style: 'compressed', );
    1 point
  15. Like most newbies (I suspect) I am now exploring different Modules. To be honest some of them leave me wondering "how and when would I use this?" I bet most of you have favorites, a few oft deployed modules, that you reach for most of the time. I wonder if the most used modules would be the same for most of you? Anyways, I am interested (maybe others as well) in learning what modules you guys reach for most of the time... Thanks!
    1 point
  16. I've been interested in sharing my setup since it's radically changed over the last year for the better. Wish I could open the repo for the code of my flagship project, but it's the site for the company I work for and isn't mine, www.renovaenergy.com Local Dev: Code editor is Sublime Text tuned for my preferences/workflow. OS is Ubuntu Linux, will probably distro-hop at some point like Linux users do. Environment is provided by Devilbox, which I can't recommend enough. It's a fast (mostly) pre-configured yet customizable Docker tool with outstanding documentation. A ProcessWire ready container is available. CSS/JS compiled by Gulp/Babel/Browserify for local dev and production builds. ES6 modules. Zero frameworks, no jQuery. Focus on lightweight JS and code splitting for better load times. CSS is compiled and split into separate files by media queries which are loaded by browsers on demand based on screen size. Currently building out website unit/integration tests using Codeception. This is becoming increasingly necessary as the site becomes more complex. Firefox Developer Edition Tilix terminal emulator, Quake mode is awesome Cacher stores code/scripts/configs in the cloud for easy sharing across machines. IDE integration is solid Meld for fast diffs WakaTime because who doesn't like programming metrics for yourself? DevDocs but locally in a Nativefier app. REQUEST: Star ProcessWire on Github. If a project has 7k+ stars it is a candidate to have it's documentation added to DevDocs. Production: Code editor is Vim on server Deployment is via Git. Local repositories have a secondary remote that pushes code to production via a bare GIT repo which updates assets on the server using hooks. Access to server via SSH only. Changes to files only made locally and pushed. Hosting by DigitalOcean with servers custom built from OS up for performance/security. Custom PageSpeed module implementation. Automatic image conversion to webp, file system asset caching, code inlining, delivery optimization, cache control, etc. Driven down TTFB <=500ms on most pages with load times around 2 seconds sometimes less if I'm lucky haha StatusCake monitors uptime, automated speed tests, server resources, and HTTPS cert checking. PagerDuty is integrated with StatusCake so issues like servers going down, server resources (ram/disk/memory) low, and whatever else get notifications on all your devices. 7G Firewall rules are added to the PW .htaccess file to block a ton of bots and malicious automated page visits. Highly recommended. Mailgun for transactional email ProcessWire Modules & Features: Modules (most used): CronjobDatabaseBackup, ProFields, Fluency, ImageBlurHash, MarkupSitemap, PageListShowPageId, ProDevTools, TracyDebugger, ListerPro, ProDrafts Template cache. We used ProCache initially but saw some redundancies/conflicts between it and PageSpeed tools on the server. Would absolutely recommend ProCache if your hosting environment isn't self-managed. All configurations are saved in .env files which are unique to local/staging/production environments with contents stored as secure notes in our password manager. This is achieved using the phpdotenv module loaded on boot in config.php where sensitive configurations and environment-dependent values are made securely available application-wide. Extensive use of ProcessWire image resizing and responsive srcset images in HTML for better performance across devices. URL Hooks - Use case- We rolled out a Web API so external platforms can make RESTful JSON requests to the site at dedicated endpoints. The syntax resembles application frameworks which made development really enjoyable and productive. The code is organized separately from the templates directory and allowed for clean separation of responsibilities without dummy pages or having to enable URL segments on the root page. Also allowed for easily building pure endpoints to receive form submissions. Page Classes - My usage -This was a gamechanger. Removing business logic from templates (only loops, variables, and if statements allowed) and using an OOP approach has been fantastic. Not sure if many people are using this but it's made the code much more DRY, predictable, and well organized. Implementing custom rendering methods in DefaultPage allowed for easily "componentizing" of common elements (video galleries, page previews, forms, etc) so that they are rendered from one source. Helped achieve no HTML in PHP and no PHP in HMTL (with the exceptions above). Also allows for using things like PHP Traits to share behavior between specific Page Classes. I completely fell in love all over again with PW over this and now I couldn't live without it. This literally restructured the entire site for the better. Probably other stuff but this post is too long anyway haha.
    1 point
  17. Seeing the forgot password, I want a "forgot module" module. Basically, it automatically installs the module you forgot about......
    1 point
×
×
  • Create New...