
dab
Members-
Posts
156 -
Joined
-
Last visited
dab's Achievements

Sr. Member (5/6)
62
Reputation
-
dab started following [SOLVED] Real estate site - project on start page and Module: ProcessWire Core Upgrade
-
I love this module, thanks. It's makes upgrading so easy. Across a few sites that I've upgraded PW core (the latest was from PW 3.0.210 to PW 3.0.246) I'm getting an error showing: SQLSTATE[42000]: Syntax error or access violation: 1067 Invalid default value for 'created'. I spotted using "Tracy/Adminer" that some Module "created dates" were showing as created "0000-00-00 00:00:00", but replacing this with real date/times made no difference. It's not affecting functionality, but curious how to identify the cause & find a fix! Thanks. Ha, sorted it! Edited the sql file directly "find & replace" 0000-00-00 00:00:00 etc with a valid date & it's fixed!
-
@Soma Working OK on PW 3.0.244! Many thanks.
-
I use https://perishablepress.com/7g-firewall/ on many sites, stops bots etc.
-
& this from Google search (not tested):
-
Password reset here:
-
Fantastic site, great job ? Ditto some random postcodes threw an error e.g. IV42 8YD, IV41 8WZ (selected off the web to compare against my home postcode).
-
I've been using this: 7g firewall with my Processwire sites: https://perishablepress.com/7g-firewall/ Seems to be working effectively.
-
Is this any use?
-
@jor Not sure if this is the correct way, but on my map template I wrap my code with: if($page->marker->address) { } e.g. if($page->marker->address) { $map = wire('modules')->get('MarkupLeafletMap'); $options = array( 'markerFormatter' => function($page, $marker_options) { if ($page->marker_icon->title) { $marker_options['icon'] = $page->marker_icon->title; } if ($page->marker_colour->title) { $marker_options['markerColor'] = $page->marker_colour->title; } // And the icon colour. This is another text field. Colour values like White, Black or an RGB value are ok here. if ($page->marker_icon_colour->title) { $marker_options['iconColor'] = $page->marker_icon_colour->title; } return $marker_options; }, 'popupFormatter' => function($page) { $out[] = "<strong>$page->headline</strong>"; return implode('<br/>', $out); } ); $content.= $map->render($page, 'marker', $options); } If no address is entered, no map is shown.
-
Have a look at delayed output strategy. You have one main "template"(_main.php) & can then simply create a new template for a sub-section page where you just add code for regions/sections of your _main template where you want to show different content (summaries, other content etc.). I found the intermediate templates a good starting point to see how _main.php & e.g. home.php or basic.php interact. Once you've learnt this, look at markup regions - super powerful (once mastered)!
-
@adrianThanks for the speedy reply. Most odd, WHM/Cpanel was reporting PHP 7.2, but I double checked with a "phpinfo" file & it showed PHP5.6! I reset the PHP version to PHP 7.2.32 & it's cleared the error. Apologies for the incorrect info & thanks for the fix for <7 (& for such a great module)!
-
Has anyone come across this error? Parse error: syntax error, unexpected ':', expecting ';' or '{' in /home/********/public_html/site/assets/cache/FileCompiler/site/modules/TracyDebugger/includes/PwApiData.php on line 516 PW 3.0.148, Tracy Debugger 4.21.20, PHP 7.2. line 516 is private function phpdoc_params(ReflectionMethod $method) : array { Have tried a reinstall & cleared complied files from > Modules. No errors on other sites on same server with same setup.
-
@Robin S thank you you are lifesaver - I missed this completely. With the addition to the hook it's working perfectly now!
-
I noted that you can't add an unpublished page to the list of pages a user can edit. It results in error: "Unpublished page /en/members/test/ is not allowed in field "Pages user may edit". To allow unpublished pages, edit the “editable_pages” field and see the setting on the “Details” tab." I'm not sure where to find this - or if it is applicable as Page Edit Per User is a hook in to the system.