Jump to content


  • Posts

  • Joined

  • Last visited

  • Days Won


Everything posted by gmclelland

  1. That could be an option. Although that would probably be my last option. I prefer to prevent the extra data from being loaded in the first place.
  2. So it seems like both Page Trees (the one at /processwire/pages/ and the one shown in the picture above) have an id = 3. So I guess you would somehow have to determine if the page is displayed in some kind of modal or not and then apply the hook or MarkUpPageTree? Does that sound right or even doable?
  3. Thanks @tpr and @Robin S! Your module update **very quickly** fixes the immediate problem with the breadcrumb trails and breadcrumb dropdown menu items when used with the MarkUpPageTree module. A little off topic to this thread now, but I would still like to modify the MarkUpPageTree module to only operate on the Page Tree on /processwire/page/. Do you know of any way to do that? Maybe only somehow autoload on page id = 3 or something like that? This is what I want to prevent. In the picture you can see the MarkUpPageTree module showing the template names in Page Tree Side Panel. I really only want to show that on /processwire/page/
  4. Just tested the new feature in 0.1.16. It worked great except I had to disable the MarkInPageTree module from https://github.com/benbyford/MarkInPageTree I use that module to include the template name floated to the right of the Page name when viewing the Page Tree. Ideally, I only want the MarkInPageTree's Page Tree modifications to only show when I'm on the Page Tree at /processwire/page/. I've tried modifying the MarkInPageTree module's autoload key to the following: using a selector string 'autoload' => 'id=3', and using an anonymous function 'autoload' => function() { if((wire('page')->template == 'admin') && (wire('page')->id == 3)) return true; else return false; }, as seen from Both didn't seem to work. The labels on the Page Tree stopped showing on /processwire/page Any idea of how I can get the MarkInPageTree module to only show when viewing the Page Tree on /processwire/page and not show in the breadcrumbs when the BreadcrumbDropdown module is enabled? I also don't want the MarkInPageTree module to show when the sidebar is opened and the Page Tree is displayed when clicking on the tree icon.
  5. The TracyDebugger module and Processwire was mentioned on the PHP Weekly email newsletter http://www.phpweekly.com/archive/2019-02-14.html - It was the last thing mentioned at the bottom.
  6. Thanks for sharing your module. For more exposure, you might want to submit a PR to https://github.com/wanze/TemplateEngineFactory to update the README.md under "Implemented Engines" to include a link to your module?
  7. @ryan Is the code examples correct on this page? https://processwire.com/api/ref/sanitizer/min/ https://processwire.com/api/ref/sanitizer/max/ It looks like it is missing the first argument in the function calls? $n is defined, but isn't used. Thank you for all your work in updating the documentation.
  8. Sorry flydev, I'm not sure about that?
  9. On mobile right now, but try Adrian's modulesettingsimportexport module. It allows you to export/import module settings. Works great for me.
  10. @horst There's also TracyDebugger's Diagnostics panel https://adrianbj.github.io/TracyDebugger/#/debug-bar?id=diagnostics that you can use.
  11. - Sorry if I wasn't fully clear. I meant to only left justify these elements on the mobile breakpoint/view when everything is vertically stacked. Above that breakpoint everything looks fine center justified.
  12. Would you also consider adding more contrast/weight to the active link to help show your current position/location in the sidebar navigation? Maybe something like this?
  13. Hi Ryan, can you make all the text left justified instead of centered when viewing the site on mobile? I find it hard to read when the text is ragged. I'm referring to the blog posts and the blue footer text (twitter posts, forum postings, Latest news, etc.) I also noticed after typing in the search field on the site, every time you hit the down arrow key to try to select one of the autocomplete suggestions a spinner shows like it is searching again.
  14. For what is worth... Here are my notes that I've gathered from the forums and other places. Maybe something like this can be used somewhere? from @kongondo and others **************************************** When coding inside of modules you cannot directly access the PW API variables like $pages, $session, $input etc.. Those are available at $this->pages or wire('pages'). If you have static method(s) in your modules then you need wire('pages') there - so if you want to play it safe always use that (it works on command line scripts also) **Outside a function and class. Ex. in templates $page; $pages; $sanitizer; $input; $modules; $templates; $fields; $user; $users; $log; $session; $config; __('Translate me baby'); **Inside a function or classes not extending WireData wire('page'); wire('pages'); wire('sanitizer'); wire('input'); wire('modules'); wire('templates'); wire('fields'); wire('user'); wire('users'); wire('log'); wire('session'); wire('config'); **Inside classes extending WireData $this->pages->find('something'); **Inside a class not extending WireData $this->wire('page');// also $this->page; $this->wire('pages');// -ditto- $this->wire('sanitizer');// -ditto- $this->wire('input');// -ditto- $this->wire('modules');// -ditto- $this->wire('templates');// -ditto- $this->wire('fields');// -ditto- $this->wire('user');// -ditto- $this->wire('users');// -ditto- $this->wire('log');// -ditto- $this->wire('session');// -ditto- $this->wire('config');// -ditto- $this->_('Your string to translate’); $title = wire()->fields('title'); // in a regular function outside of an object $title = $this->wire()->fields('title'); // in a Wire-derived object $title = $this->fields('title'); // in a Wire-derived object (alternate syntax) from here /** * Global function, therefore does work everywhere, * but will always refer to the first pw instance * in case of multi instance usage. * Because of that it's discouraged to use this in * modules. */ wire("apivar") /** * Safest way to get the api variable in wire derived * classes like modules. */ $this->wire("apivar") /** * Does work as well, but some (core) classes have that * type of access disabled. It also prevents you from * using a custom paramater $apivar in your class. */ $this->apivar From here In hooks use $event->wire() instead of wire() because it is multisite instance aware ****************************************
  15. @Craig A Rodway - I'm not seeing the horizontal scrollbars anymore unless I resize the text to 120% at that point the Docs menu is off. At the standard 100% the menus open correctly for me in Chrome / Firefox Mac. Ryan, on the latest blog posting https://processwire.com/blog/posts/rebuilding-the-pw-site-5/ I still see 2 "Prev" links which seems confusing. If it is the latest blog posting, I would think it should only show 1 "Prev" posting instead of two previous postings? Other blog posts look correct like on https://processwire.com/blog/posts/pw-3.0.123-master/ Thank you for all the work that you have put into this!
  16. @Chris Bennett - is right. The .blog-posts rule negative margin-left and margin-right on the home page are causing the horizontal scrollbars. It happens when the blogposts go edge to edge at less than 1599px width. Here is how I found out. From https://css-tricks.com/findingfixing-unintended-body-overflow/ In chrome's dev console, run the following when you see the horizontal scrollbars. The console will print which html element causes the overflow. Right click on it and choose "Reveal in Elements Panel" to see the offending element. Another way to try to find this using the following css: * { outline: 1px red solid !important; } and look for the elements that have excessive width. Here are some other items causing the horizontal scrollbar. The .footer and the header the .pw-plug>div rule with width: 4%; is causing an overflow when viewing the site on small mobile viewports (444px width). In the Processwire Showcase carousel left/right arrows using the .uk-slidenav rule with padding: 5px 10px is causing the right arrow to overflow the page at smaller breakpoints 908px. In the Processwire Showcase carousel dots menu using the .uk-dotnav rule with margin-left: -12px; might cause a horizontal scrollbar. .uk-slidenav rule with padding: 5px 10px; at 699px width might cause a horizontal scrollbar. You probably could get around all these issues with overflow-x:hidden; rule on the html/body element, but it might be better to find out and fix what is causing the scrollbars so that it doesn't causes other bugs? The overflowing elements might be the cause of the dropdown menus not positioning correctly. Hope that helps
  17. Couple of bugs: Broken Link - "Oliver's ProcessLanguages" https://processwire.com/newsite/docs/multi-language-support/multi-language-fields/ Broken Link - "See these examples of how multi-language fields can be used to produce a multi-language website." https://processwire.com/newsite/docs/multi-language-support/multi-language-fields/ Old admin theme images displayed - https://processwire.com/newsite/docs/multi-language-support/multi-language-urls/ Some videos show an older version of processwire. Maybe add a caption underneath the videos that indicates that the video's content is using an older version but is still relevant? On https://processwire.com/newsite/docs/start/install/upgrade/ Maybe mention @adrian ModuleToolkit module for bulk module upgrades?
  18. I see it because I had my Chrome browser zoomed to 110%. I think it might be caused by the overflow issue that @Jonathan Lahijani mentioned at
  19. @Robin S - haven't tried these, but maybe https://sitemod.io/ or https://userstyles.org/ or https://www.styleurl.app/ or https://www.canvasflip.com/visual-inspector/?
  20. Looking good Ryan. One thing I noticed is the last dropdown menu "Docs" should open the same direction/way as the "Download" menu item but it doesn't. It opens off screen causing horizontal scrollbars. When viewing on Chrome. Edit: it looks like jmartsch beat me to it. Please consider giving the light grey and other muted text more contrast for accessibility. See https://contrastrebellion.com/ for humor. #666 for body copy gives AA, but #565656 gives AAA for example. Chrome's inspector now includes a contrast accessibility checker when you click on the color swatch/square. The curved line represents what passes the AA or AAA rating. After reading the API examples, I want to know more about it. I think we need a link or outlined button below the examples "Get started with the API" or "Learn more" so they can continue reading. Now that I look at it more, maybe each homepage section needs it own call to action button below. At first it wasn't entirely obvious that the headers on the homepage were links. Ex. Blog posts - might need a button below that say's "View all" or something similar. Same for the Processwire Showcase and Shop. - This might actually motivate new users to join the forums as well. Those are just a few of the first things that come to mind when viewing the site. Hope that helps
  21. Do you have a "Portfolio" page with "Project" pages below it? What does you setup look like? Maybe you describe what your template is trying to do?
  22. Perhaps it should be: $portfolio_pages = $pages->get('/portfolio/')->projects;
  23. $pages->get->projects; That looks strange to me. Maybe you can look at the examples on https://processwire.com/api/variables/pages/ ? I'm not sure why it worked before?
  24. See this post. It has some good code comments: and Also check the module's source code. That helped me. https://github.com/processwire/processwire/blob/dev/wire/modules/Markup/MarkupAdminDataTable/MarkupAdminDataTable.module Hope that helps you
  • Create New...