Jump to content

ngrmm

Members
  • Posts

    251
  • Joined

  • Last visited

Contact Methods

  • Website URL
    http://www.engramm.com

Profile Information

  • Gender
    Not Telling

Recent Profile Visitors

2,786 profile views

ngrmm's Achievements

Sr. Member

Sr. Member (5/6)

56

Reputation

2

Community Answers

  1. @Bacelo did you find any solution back then? @Roope I'm using PW 3.0.200 and it looks like the module is stuck somewhere in the process. Script is not added automatically. When I add it manually it does not find anything in the document. So with script added manually and using $sanitizer->emo($string) it find the email and replace it completly with a noscript tag.
  2. yes, your update fixes the issue, thanks!
  3. @teppo I get this error when I add a repaterMatrix field to indexed fields TracyDebugger: TypeError SearchEngine\IndexValue::__construct(): Argument #1 ($value) must be of type string, null given, called in /…/htdocs/domain.com/_NEW/site/modules/SearchEngine/lib/Indexer.php on line 297 search► –––– File: .../domain.com/_NEW/site/modules/SearchEngine/lib/IndexValue.php:33 23: * 24: * @var array 25: */ 26: protected $meta = []; 27: 28: /** 29: * Constructor 30: * 31: * @param string $value 32: */ 33: public function __construct(string $value = '') { 34: $this->value = $value; 35: } 36: 37: /** using pw 3.0.200 © 2022, search engine 0.35.0 and php 8
  4. @joshua does privacywire log user clicks? As far as I understood you must have a „consent log“. „… By default, consents collected through the Cookie Notice banner and/or the Privacy Notice link are automatically logged so that you can access the information at any time. Your consent log is basically a list of users who interact with the banner by either consenting or declining to the use of their information.“ CookieBot for example does this: „Cookiebot CMP stores the user's selection for 12 months, after which the banner automatically reopens to renew the user's consent. … All user consents are automatically logged in anonymized form and encrypted. A data processing contract (DSGVO) is not required. The consent log can be downloaded from the manager and used for documentation.“ or cookiehub: https://www.cookiehub.com/de/produkt/premium/einwilligungsprotokoll
  5. I have a page which imports external json-feed into pages and would like to run this page every day. The Problem is that the import take 10–20 seconds. Is there a way to trigger this import from any other page and let in run in the background? I would like to avoid slow pageloads of other pages, even if it's once a day.
  6. Did you check your Browser-Settings? DNT-Mode? Ad-Blocker?
  7. I use the explode function to generate a json-feed like this $list = $pages->get(1234)->children; $toJSON = $list->explode(function ($item) { return [ 'title' => $item->title, 'id' => $item->id, 'start' => $item->summary, ] } But i would like to use the sanitizer on the summary field. Like this: Obviously this can not work. But how can sanitize the summary before the output? $list = $pages->get(1234)->children; $toJSON = $list->explode(function ($item) { // $itemSummary = $sanitizer->truncate($item->summary, [ // 'type' => 'punctuation', // 'maxLength' => 155, // 'visible' => true, // 'more' => '…' // ]); return [ 'title' => $item->title, 'id' => $item->id, 'start' => $itemSummary, ] }
  8. Looks like it's not possible. It says: • settingsField: Specify a PW field that uses CKEditor to use for the settings of this column. Note that inline mode is always used, regardless of field settings. • …
  9. @FireWire thanks for the module! Is there a way to force regular mode for CKEditorfields inside tables and use fluency? Or are they always in inline-mode, no matter what setting are set?
  10. it's solved. There was an issue with https://www.domain.com and https://domain.com. $config->httpHosts = array('domain.com', 'www.domain.com'); was missing and I activated redirects from https://domian.com to https://www.domain.com
  11. On one of my PW-installations I'm not able to view unpublished pages as superuser. Getting redirected to the 404-page running ProcessWire 3.0.184 and no errors showing up.
  12. Actually this is perfect, as I don't need all the page data. But unfortunately it outputs the page ID as key, what don't want to have. Maybe there will be some options in the future to change this default behaviour. Thanks @Zeka anyway, the other solution works perfectly!
  13. wow much easier than i thought. And what is the correct syntax to go more levels deeper? Let's say one my tags has also page-reference-field itself.
  14. thx @Zeka I got it working with a temporary loop inside my foreach-loop (see update on my post). Actually I needed the tags to be arrays themself. But your method looks better. Is there a way to output the tags as arrays themself with your method?
  15. I know there are some modules (pageQueryBoss, GraphQL, …) this. But non of them outputs exactly how i would like my json to be. So i tried to do it manually: $list = $pages->get(1234)->children; $list_array = array(); foreach($list as $listItem) { $list_array[] = array( 'title' => $listItem->title, 'id' => $listItem->id, 'tags' => array( 'ids' => $listItem->page-reference-field ) ); } $list_json = json_encode($list_array, true); echo $list_json; How do I loop through a page-reference-field inside an array? UPDATE: i think, thats the way to do it $list = $pages->get(1234)->children; $list_array = array(); foreach($list as $listItem) { $listItemTags = array(); foreach($listItem->tags as $tag) { $listItemTags[] = array( 'id' => $tag->id, 'title' => $tag->title, ); } $list_array[] = array( 'title' => $listItem->title, 'id' => $listItem->id, 'tags' => $listItemTags ); } $list_json = json_encode($list_array, true); echo $list_json;
×
×
  • Create New...