Recently Updated Topics

Showing topics posted in for the last 7 days.

This stream auto-updates     

  1. Past hour
  2. Which PHP version? No problems here so far with PHP 7.2.11
  3. MarcoPLY

    Hi @adrian, I was working with geoip.nekudo (it was among the services you suggested in another post) and so, geoip.nekudo it's not more free service it was bought by ipapi.com
  4. Peter Knight

    True whatd also be great is a module that watched a Real folder where you added your HC chunks. Anything dropped in there would auto create a matching HC in the admin.
  5. Today
  6. LostKobrakai

    OR-Groups are not supported by the in-memory matcher.
  7. Yesterday
  8. kixe

    @adrian Hi Adrian, I quickly tried your module and find it very useful. But does it work with repeater fields? I couldn't get it working ... I played a bit around and found another simple solution. config.php /** * array of pages or page trees having multilanguage disabled in the edit screen * */ $config->singleLanguagePages = array(11973 => 0, 12334 => 0); ready.php /** * disable multilanguage in Page Edit for specified pages or page trees * define array of single language pages in $config * where the key is the page id and the value defines if the page acts as a tree parent or only for a single page */ $wire->addHookBefore('ProcessPageEdit::execute', function($e) { $page = $e->object->getPage(); $slps = $this->wire('config')->singleLanguagePages; // exit if doesn't match if (empty($slps)) return; $parentIDs = array_intersect($page->parents()->prepend($page)->each('id'), array_keys($slps)); if (empty($parentIDs)) return; foreach ($parentIDs as $parentID) { if ($page->id == $parentID) break; // page matches itself if ($slps[$parentID]) break; // page is part of a single language tree return; } // page is set as a single language page $page->template->noLang = 1; // we want repeater fields single language as well foreach ($page->fields as $f) { if ($f->type instanceof FieldtypeRepeater == false) continue; $this->wire('templates')->get(FieldtypeRepeater::templateNamePrefix . $f->name)->noLang = 1; } });
  9. Zeka

    @tron1000 Do you have any js errors on page? Have you tried to clean the browser cache?
  10. I haven’t really investigated this. But it’s interesting to get a little insight into how PW handles all the database queries when rendering a page. Thanks for that. Perhaps I’m going to play around with the Autojoin settings a little bit. For now, caching does the job. But autoloading fields would perhaps make sense to improve the performance of the first rendering of a page, the result of which is then stored in the cache.
  11. pwired

    Ok, Thanks for your replies. Yes there are other typewriter scripts out there. Thing is I like this script because for one reason it is smart coded together in only 8 kB and it opens up a lot of possibilities. If anyone is interested in it for one of your projects, you can find it here: https://mntn-dev.github.io/t.js/ (no affiliate, mit-license, only wanting to show cool stuff) and here: https://www.youtube.com/watch?v=39NZDe95_g0 Ok, I contacted the coder of the script and he was kindly enough to reply and give a few solutions: one working solution in my main.css del { text-decoration: none; } And guess what, now I have it working in the CKEditor body field Edit: Instead of overriding globally in my main.css I override it locally directly in the hanna code snippet This sets it actually to: problem solved. Remains the overrides not working in the quirky behaviour of mystyles.js and config-body.js files, see below. ================================================================================================= I am already happy with the solution above, but I am not satisfied yet. I was digging through the forum because I remembered a few posts about mystyles.js that reside in site/modules/InputfieldCKEditor/mystyles.js If you have the Button Styles enabled in the Toolbar of CKEditor, it should be possible to put inside mystyles.js the same override, right ? /** * mystyles.js * * This file may be used when you have "Styles" as one of the items in your toolbar. * * For a more comprehensive example, see the file ./ckeditor-[version]/styles.js * */ CKEDITOR.stylesSet.add( 'mystyles', [ { name: 'Inline Code', element: 'code' }, { name: 'Inline Quotation', element: 'q' }, { name: 'Left Aligned Photo', element: 'img', attributes: { 'class': 'align_left' } }, { name: 'Right Aligned Photo', element: 'img', attributes: { 'class': 'align_right' } }, { name: 'Centered Photo', element: 'img', attributes: { 'class': 'align_center' } }, { name: 'Small', element: 'small' }, { name: 'Deleted Text', element: 'del', attributes: { 'text-decoration': 'none' } }, { name: 'Inserted Text', element: 'ins' }, { name: 'Cited Work', element: 'cite' } ] ); I would like to have it working there also, but it doesn't work there and I have read a few posts that for some reason you have to rename the file mystyles.js to make it work in CKEditor ? https://processwire.com/talk/topic/17862-share-your-ckeditor-settings/ ====================================================================================== Besides the file mystyles.js there is the file config-body.js I tried the following in this file config-body.js CKEDITOR.editorConfig = function( config ) { // Define changes to default configuration here. For example: // config.uiColor = '#AADC6E'; CKEDITOR.config.coreStyles_strike = { element : 'del', attributes : { 'text-decoration' : 'none' }, }; }; But same as with the mystyles.js here also it doesn't work with CKEditor
  12. arjen

    Hey @louisstephens, how are your experiences with this tool? Like @elabx, I'm curious since Serverpilot is rock solid, but lacking some features. Thanks!
  13. horst

    Not while programming, but when doing image manipulations and administrative tasks like site transitions (dev > stage > public) etc: HipHop in german language, from a young women living in cologne (germany), Leila Akinyi. For those who do not understand the text, it also is worth to listen the music and view the videos. My favourite is this one: And my second favourite:
  14. Last week
  15. Those sound exactly like the migrations / helper functions my Migrations module does provide
  16. arjen

    Nice, "pw-optional". Right now I'm finally back in ProcessWire re-building some websites and Markup Regions is a breeze to work with.
  17. bernhard

    Thx robin I know about that but somehow it didn't work. I need to see why and when that happens, but setting the maxage didn't solve it unfortunately.
  18. LostKobrakai

    Your posts sound like you have two problems here: One is code organization and the other is performant calculation of leaderboards. This is why people usually use some kind of separation between core domain logic (ranking of restaurants) and the website layer (actually serving a website) in their code. Duplicating such essential code as calculating the position of a restautrant because it‘s needed in multiple places of your website is a bad idea. The risk of both places getting out of sync over the time of development is one I'd not like to take. For the leaderboard calculation you seem to currently use the most simple but inefficient way: Load all the information needed into php and calculate the positions for the set of data in memory. There are two types of optimizations from here: Move the calculation logic nearer to the data it needs to work on, a.k.a. do the calculation in mysql instead of in php; This saves on the need to move all the data from mysql to php, which scales very poorly. Persist positions for as long as possible, a.k.a. caching; It seems you currently recalculate positions each time someone visits that page. But they do only change when a new ranking / comment is posted on your website. Also usually a little bit of delay between new comments and updating the ranks is not a problem. Given those two optimizations there are three concrete ways to handle things: Just Opt. 1: Write an SQL query, which can just return e.g. restaurantID + position in sorted order for all the leaderboards you have: global / per city / …. Just Opt. 2: Use some of ProcessWire's caching options to save your various leaderboards still calculated in php. Both Opt. 1 and Opt. 2: Write an SQL query and create a materialized view in the db to query. This way the calculation and caching happens in mysql, which is probably as performant as it can be. Edit: The missing puzzle piece here is treating those leaderboards as the data to store.
  19. Guy Incognito

    I'm still fairly new here having switched to using ProcessWire for pretty much every project (hence the frequent questions ) from Concrete5. Concrete5 has had Gutenberg-esque block-based front-end editing for nearly 10 years longer than Wordpress. Although a finished site using C5 can look great for a site editor/frontend-only user with various drag-drop layout tools, we were finding c5 development had become very convoluted and was starting to make simple website projects unnecessarily complicated. C5's core weighs in at a hefty filesize too. This is why we started researching for alternatives and landed happily at ProcessWire. I already find WP development unnecessarily convoluted, especially compared to the simplicity of ProcessWire. And with Gutenberg, I can only foresee the same sort of headaches ahead for the WP community that we were finding with C5 - namely conflicts between blocks and the core and frontend UI and your design style and functionality being dictated to by the CMS in order to work in the Gutenberg features. Discovering ProcessWire has been a revelation for us - the clean API and design agnostic approach are making everything from simple website projects to complex web apps a breeze, with the added bonus of super simple frontend editing that not only wows client's used to site builder platforms but requires basically zero onboarding too. I would urge anyone thinking of building out Gutenberg inspired modules for ProcessWire to consider the above comments to ensure that what makes ProcessWire special is retained.
  20. sure, no worries, i wish i did know how to do it, but we've never had the need for that yet, but it may be required in a project soon..
  21. AndZyk

    Hello @Ramon, if you want a simple text for the alt tag of your image, than you can just use the description field: https://processwire.com/api/ref/pageimage/ Regards, Andreas
  22. Peter Knight

    Thank you! So straightforward when you see how. I got up at 5AM this morning to work on this project and thought I'd get a good 12 hours at it. Instead, I had computer and internet problems all day. At least I can wake up tomorrow AM (not at 5AM though) knowing I have this fixed
  23. If anybody might wonder. This is how to setup permissions for a sub-page of a processmodule: As easy as adding the permission to the nav item! If you want the permission to be created/deleted on module install/uninstall you also have to add it in the "permissions" array: $info = [ 'title' => 'ProcessProjects', 'summary' => 'ProcessModule to manage all Projects', 'version' => 1, 'author' => 'Bernhard Baumrock, baumrock.com', 'icon' => 'thumbs-up', 'permission' => 'projects', 'permissions' => [ 'projects' => 'Run the Projects Management Module', 'aggregate' => 'Create Aggregated Reports', ], 'page' => [ 'name' => 'projects', 'title' => __('Projekte'), ], 'nav' => [ [ 'url' => '', 'label' => __('Projekte'), ],[ 'url' => 'mails', 'label' => __('E-Mails verwalten'), ],[ 'url' => 'reports', 'label' => __('Berichte verwalten'), ],[ 'url' => 'aggregate', 'label' => __('Aggregierten Bericht erstellen'), 'permission' => 'aggregate', ], ], ]; Make sure to logout/login, otherwise you won't see the changes in the menu! If you call the ProcessModule's page directly you will instantly get the result of the changed permissions: Whereas in the menu it is still there until you logout+login: @szabesz you asked for that in the blog comments...
  24. It both depends on how a server environment is setup. Especially if the PHP running user has write access to these files and directories. So, if you already know that the PHP user has no write access, you can do this before you start the installation process. If you don't know this, you can run the installation process and PW will tell you about the situation and guide you through the manually needed tasks. (Namly: select your drsired site profile or rename it to "site", delete the unused profiles, and also delete the install.php file after finished the process".
  25. Already tried that and it doesn't even getting required at all.
  26. Beluga

    Created this MR https://gitlab.com/baumrock/kickstart/merge_requests/1 so weirdos like me can use kickstart.php?skiplint and the config parameter skipcompat. Other stuff: Maybe there could be a 'httpHosts' in the example kickstartfile, to show the \n and a comment emphasising that you have to use double-quotes for them to work? The function timezones() in install.php gets the tz list with PHP's timezone_identifiers_list and adds some extras. It would seem to me that the number and ordering of this data might change at any point in history, so it feels a bit awkward to rely on the IDs we happen to get at present. On the other hand, the current solution using CURLOPT_POSTFIELDS to pass stuff to install.php is simple and getting the tz IDs by parsing the select option texts would add a gymnastic extra step.
  27. Must have missed that one! Thanks for stepping in.
  28. zoeck

    But this is only a workaround... we need a pw fix here... It makes no sense to use an old version permanently.
  29. PWaddict

    @blynx Unfortunately the showinfo parameter doesn't work anymore since it's deprecated. You should remove it from the module.
  1. Load more activity