Jump to content


  • Posts

  • Joined

  • Last visited

  • Days Won


matjazp last won the day on March 11 2020

matjazp had the most liked content!

1 Follower

About matjazp

  • Birthday 04/27/1969

Profile Information

  • Gender
  • Location
    Maribor, Slovenia

Recent Profile Visitors

5,055 profile views

matjazp's Achievements

Hero Member

Hero Member (6/6)




Community Answers

  1. @ryanI'm also having problems. If I try to change the template I get: ProcessWire: ProcessPageEdit: Page cannot be its own parent DEBUG MODE BACKTRACE ($config->debug == true): #0 C:\inetpub\wwwroot\wire\core\Page.php(708): ProcessWire\Page->setParent(Object(ProcessWire\Page)) #1 C:\inetpub\wwwroot\wire\core\Page.php(1769): ProcessWire\Page->set('parent', Object(ProcessWire\Page)) #2 C:\inetpub\wwwroot\wire\modules\Fieldtype\FieldtypeRepeater\FieldtypeRepeater.module(1126): ProcessWire\Page->__set('parent', Object(ProcessWire\Page)) #3 C:\inetpub\wwwroot\wire\modules\Fieldtype\FieldtypeRepeater\FieldtypeRepeater.module(766): ProcessWire\FieldtypeRepeater->getRepeaterPageParent(Object(ProcessWire\Page), Object(ProcessWire\RepeaterField)) #4 C:\inetpub\wwwroot\wire\core\Wire.php(423): ProcessWire\FieldtypeRepeater->___wakeupValue(Object(ProcessWire\Page), Object(ProcessWire\RepeaterField), NULL) #5 C:\inetpub\wwwroot\wire\core\WireHooks.php(951): ProcessWire\Wire->_callMethod('___wakeupValue', Array) #6 C:\inetpub\wwwroot\wire\core\Wire.php(485): ProcessWire\WireHooks->runHooks(Object(ProcessWire\FieldtypeRepeater), 'wakeupValue', Array) #7 C:\inetpub\wwwroot\wire\modules\Fieldtype\FieldtypeRepeater\FieldtypeRepeater.module(636): ProcessWire\Wire->__call('wakeupValue', Array) #8 C:\inetpub\wwwroot\wire\core\Field.php(980): ProcessWire\FieldtypeRepeater->getInputfield(Object(ProcessWire\Page), Object(ProcessWire\RepeaterField)) etc... It happens on pages with templates that have repeaters. It looks like this commit https://github.com/processwire/processwire/commit/b47297fd4adafcd6f1b12e943380e3f796793b7b is the culprit? Pages.php, line 1899, commenting this line: if($id !== null) $options['id'] = $id; fixes the error.
  2. Those hover dropdowns bothers me too. I use desktop browser and sometimes my hand shakes and can't move my mouse with enough precision. When you hover over top level menu, the second level menu is opened and if you happen to move your mouse outside of the menu area, the menu closes. So I usually just click on Pages, Setup, Modules.
  3. I worked on this too. Attached is my modified admin theme I posted somewhere on the forum, but this version is bit modified, I tried to fix some focus issues... admin.less
  4. I don't remember if I fixed that or not, but the module will perform update when you edit a page that has CI field.
  5. "data-phc" attribute is missing on body tag. Are you sure you have body at all?
  6. More fun (can't upload animated gif) with style switcher... style-switcher.mp4
  7. And perhaps an option for each user to select it's own skin/style/theme (whatever it's named) in his profile...
  8. I had some fun too. Created another theme/style based on default reno style but tried to add more contrast (WCAG AA). It's also more in blue tones (but I kept PW pinky color) to match our website color theme. There are also some other tweaks. admin.less
  9. Note that rename() will not rename variations... you should track changes on basename: $p->singleImage->trackChange("basename"); $image->removeVariations(); $image->rename($newFilename); $p->save("singleImage"); https://processwire.com/talk/topic/4299-how-to-rename-a-file-properly/?do=findComment&comment=42213
  10. Thank you (and Ryan) for your work on AdminThemeUikit. What I'm missing is an option to select between styles quickly. I was expecting something like this: I create a folder /site/modules/AdminThemUikit/styles/ and copy many different less files. The core AdminThemeUikit would then scan for this folder and allow me to choose between them in the module settings, similar to what we have in AdminThemeDefault, where we can select different Color Sets (classic, Warm, Modern, Futura).
  11. The problem is in your system, it's missing utf8 locale. 'locale -a' in the terminal window will tell you what are available locales. If the problem would be benign, as you think, then PW would not warn you about it.
  12. $items = $pages->find("id>1"); $home = $pages->get("id=1"); $customPaginatedArray = new PaginatedArray; foreach ($items as $item) : if ($item->parent == $home) : $customPaginatedArray->add($item); endif; endforeach; // should return an array of pages that are direct children of the homepage $limit = 10; $start = ($input->pageNum-1)*$limit; $total = $customPaginatedArray->count(); foreach ($customPaginatedArray->filter("limit=$limit, start=$start") as $c) : echo $c->title . '<br>'; endforeach; $customPaginatedArray->setStart($start); $customPaginatedArray->setLimit($limit); $customPaginatedArray->setTotal($total); echo $customPaginatedArray->renderPager();
  13. $limit = 6; $items = $pages->find("template=basic-page, limit=$limit, body!=''"); //alternative /* $decider = "body"; $items = $pages->find("template=basic-page, limit=5); foreach($items as $item) { if($item->$decider != '') $items->remove($item); } */ $start = $items->getStart() + 1; $end = $start + count($items) - 1; $total = $items->getTotal(); if($total) echo sprintf(__('%1$s %2$d to %3$d out of %4$d'), "Showing items ", $start, $end, $total)."<br><br>"; foreach($items as $item) echo $item->title . "<br>"; echo "<br>"; if ($items->getLimit() < $total) echo $items->renderPager();
  14. //$page->imge is PageImages with the total of 38 files $object = $page->imge; //total number of items, in this case total number of files in Images field $totalItems = count($object); //number of items to display per page $itemsPerPage = 5; //current page number, starting with 1, if no page specified, it defaults to 1 $pageNum = $input->pageNum; //start item, depending on the current page number $startItem = ($pageNum - 1) * $itemsPerPage; //current items $items = $object->slice($startItem, $itemsPerPage); //debug info echo "totalItems=" . $totalItems . "<br>"; echo "itemsPerPage=" . $itemsPerPage . "<br>"; echo "pageNum=" . $pageNum . "<br>"; echo "startItem=" . $startItem . "<br>"; echo "<br>"; //show info $start = $startItem + 1; $end = $start + count($items) - 1; $total = $totalItems; echo sprintf(__('%1$s %2$d to %3$d out of %4$d'), "Showing items ", $start, $end, $total); echo "<br><br>"; //render items foreach($items as $item) { echo $item->name . "<br>"; } echo "<br>"; //create a new pageArray to give MarkupPagerNav what it needs $a = new PageArray(); //tell the PageArray details it needs for pagination $a->setTotal($totalItems); $a->setLimit($itemsPerPage); $a->setStart($startItem); //show pager echo $a->renderPager(array('nextItemLabel' => ">",'previousItemLabel' => "<"));
  15. I use pagearray not paginatedarray
  • Create New...