Leaderboard
Popular Content
Showing content with the highest reputation on 10/16/2023 in all areas
-
Hey there, born out of a personal need I've implement a lightweight version of @Robin S' Hanna Code Dialog module for TinyMCE. In a bout of creativity, I've named it HannaCodeDialogTiny This module is still in alpha state and needs some extensive testing. If you encounter any problems, please open an issue on GitHub. It has no select options, descriptions or cheat sheets (yet), and it doesn't cope well with nested Hanna Codes. What it does have is the Insert Hanna Code dropdown in the TinyMCE menu bar with dialog-based insertion, non-editable Hanna Codes in the editor, double click on existing codes for editing in a dialog. Hanna Codes are also highlighted, and you can drag and drop them around. The dropdown: Double click on any highlighted Hanna Code: Fill in your values: The Hanna Code has been changed: Have fun!2 points
-
Add support for the Latte templating language to the Template Engine Factory. Available on the module directory and on GitHub. The latest version uses Latte v3. Configuration The module offers the usual the following configuration: Template files suffix The suffix of the Latte template files, defaults to latte. Default layout file Layout that all views will extend from unless overwritten. Provide ProcessWire API variables in Latte templates API variables ($pages, $input, $config...) are accessible in Latte, e.g. {$config} for the config API variable. Simplified path resolution Enable Blade-style dot syntax for directory traversal, e.g. partials.navigation instead of ../../partials/navigation.latte Auto refresh templates (recompile) Recompile templates whenever the source code changes.2 points
-
@FireWire It is working great. Thanks again!1 point
-
Nope. I have a fix coming today, this is a bug. I'll add another comment here when it's ready!1 point
-
@markus_blue_tomato I'm also thinking of adding support for alternative hashing methods, specifically ThumbHash. The colors with ThumbHash seem to be a bit closer to the original and it also supports alpha channels. Would you be willing to accept a PR for that? I'd love to avoid creating a separate module, as the core logic would just be duplicated. Adding a new setting is much more elegant and allows experimenting with both hashing methods more easily. If it helps and it's possible, I'd be willing to take over maintenance of the module and take it from there.1 point
-
My understanding is that the toolbar defaults are just the settings that get pulled in when you create a field. Once you edit a field's settings, it saves the toolbar config to the database and pulls it from there from then on. If you however prefix your settings with "replace_", "add_" or "remove_", it will still influence the field's behavior. So you should be able to e.g. put { "add_toolbar": "removeformat" } into the " Default setting overrides JSON text" field in the module settings or into your site/modules defaults.php, and the removeformat button gets added to all fields.1 point
-
Hi @markus_blue_tomato I've finally come around to investigating the issue where newly uploaded images would keep the old blurhash. I have a working backward-compatible fix ready in a fork, but I see that the module itself has been marked as readonly for a while and I can't create any PRs against it. Would you accept this fix via some other means?1 point
-
Thanks for reporting the issue; I've pushed a fix as 1.0.6. Updating the composer package should fix it: composer update daun/template-engine-latte1 point
-
Hi @Clarity I'm always using this snippet: <?php // install german language pack for the default language // this will install language support, download the ZIP and install it $rm->setLanguageTranslations('DE'); $rm->installModule('LanguageSupportFields'); $rm->installModule('LanguageSupportPageNames'); $rm->installModule('LanguageTabs'); $rm->setFieldData('title', ['type' => 'textLanguage']); I do that once and then comment everything out so that it does not run on every migration. Once I have the files in the project I simply git push them to live.1 point
-
Hey @wbmnfktr, now we wait... https://github.com/devicons/devicon/pull/19051 point
-
Welcome to ProcessWire! Hope your experience has been great thus far (well, aside from this error you're seeing) and thank you for the kind words. 1. Absolutely will be adding it to the modules directory. I'd like to get a couple of tweaks in and iron out any bugs that may pop up, I have done as much testing as I can on my own and I need to make sure that "it works for me" means "it works for everyone" haha. @bernhard had a great suggestion for using hooks. As soon as it's had a little bit of usage I think it will be ready for the modules directory, so your feedback and bug reports are very helpful. 2. Translation engine requests are logged, so check the 'fluency-engine' log. That should help figure more out. If that isn't helpful then try using the network tab under your browser development tools, try translating something, then check the JSON response. Another question- does the translation tool accessed by the menu at the top of the page work? I too have had some secondhand experience with the challenges of adding multi-language capabilities to WordPress. My partner manages a WP site for the company they works for and had to try several plugins, some worked partially, all were difficult to use. Fluency was designed to be better than anything WP has available and those problems guided my work. Feel free to share your story over in this forum post celebrating WordPress.1 point
-
PS Maybe you can share more details about this here or in the pub? It's always good to know the competition and to know what problems client might face if they want to use WordPress... PPS: I tried to edit my post but the forum software decided to create a new one, sorry ?1 point
-
I've had a similar issue and for me it was the problem that the endpoint was not reachable. The reason was that I moved the fluency page in the admin from the top level down into the setup tab. You can try to inspect the network tab of your devtools and see what response you get from the fluency api request. It should be JSON - for me it was HTML. I've talked to @FireWire about changing his implementation to url hooks to prevent this issue. Maybe it's something similar for you. Maybe you moved the page as well or maybe you have any other redirects going on from some hooks?1 point
-
Awesome, thanks for creating this @BitPoet! I am going to be locked into CKEditor for the foreseeable future because in addition to my public modules I have a number of private modules that integrate with CKEditor and rebuilding them all for TinyMCE will be a big job. And for the types of sites I work on I don't see many advantages of TinyMCE over CKEditor so I don't have much motivation to do all the rebuilding at the moment - I'll probably get to it eventually but not any time soon. So it's great that HannaCodeDialogTiny is available for anyone who wants to switch to TinyMCE sooner than I do.1 point
-
I did something similar to this with a website for a photography club. In this case the equivalent of your projects would be competition entries. I wrote a custom dashboard module for this and hooked into ready.php to prevent display of the normal page tree for normal admin users, used AdminRestrictBranch, and ListerPro from a link in the dashboard module, so users could list, edit, and create just pages that belonged to them.1 point
-
Finally got some time and it looks good to me. File names looking good as well. See here. I couldn't find anything about transparency in logos (besides that all colors will be stripped out at some point) so processwire-original-wordmark.svg seems to be a good fit.1 point
-
There is a workaround if you're willing to edit the core: https://github.com/processwire/processwire-requests/issues/2391 point
-
Looks like theres an issue with this module and PHP 8+ Fatal Error: Uncaught TypeError: round(): Argument #1 ($num) must be of type int|float, string given in site/modules/FieldtypeMapMarker/InputfieldMapMarker.module:2081 point
-
If you are looping over the whole PageArray then the sort position is the key (zero indexed). foreach($items as $key => $item) { echo "$item->title - sort position is $key"; } If you want to get individual pages from the PageArray and know their sort position you can first loop over the PageArray and save the sort position to a custom property on each page. foreach($items as $key => $item) { $item->sort_position = $key; } $one = $items->get("foo=bar"); echo "$one->title - sort position is $one->sort_position";1 point
-
1 point
-
Here is something I hacked together quickly for automatically adding new child pages to the pagetable field. This is only if you are using the page as the parent. It also handles deletion of items if they are trashed externally. I also disabled the internal check for orphans - because they have been automatically added already, there is no need for the "Children were found that may be added to this table. Check the box next to any you would like to add." option. I seems to be working great here, but please test carefully!! Add this to your admin.php file: wire()->addHookBefore('InputfieldPageTable::render', function($event) { $pp = wire('pages')->get(wire('input')->get->id); $ptf = $event->object; //remove pages from pagetable field if they were externally trashed foreach($pp->{$ptf->name} as $item) { if($item->is(Page::statusTrash)) $pp->{$ptf->name}->remove($item); } //add pages to pagetable field if they were created externally foreach($pp->children as $child) { if(!$ptf->has($child->id)) { $pp->{$ptf->name}->add($child); $pp->of(false); $pp->save($ptf->name); } } //reset orphans property so that we don't get a message asking to add new pages that are now already automatically added $ptf->setOrphans(new pageArray()); });1 point