Jump to content

tpr

Members
  • Posts

    2,321
  • Joined

  • Last visited

  • Days Won

    44

Everything posted by tpr

  1. Nice solution I just finished to rebuild a WP site to PW. I'm happy with the result, it's fast and feels lightweight. And also has the benefit that the host provider doesn't threat the client to take off the site because it eats 16% of server resources (WPML "side effect")
  2. See if this helps (OR groups): https://processwire.com/api/selectors/#or-groups
  3. @adrianmak just needed the html_entity_decode in the current project so I'll add this to my module, thanks!
  4. Great addition, thanks! Even works in .latte files "{*comment*}". How about cutting off the comment characters in the panel? That would make todos more readable.
  5. Ok, thanks. Don't worry about the errors, I use this module only occassionally, and I just took a look on the opcache viewer as there's opcache on the server. As for issue No1, maybe there's an extra "children('include=hidden')" that doesn't needed? // original - throws error $p = $this->pages->get(22)->children('include=hidden')->get('name=' . AdminLinksInFrontend::opcPageName); // works $p = $this->pages->get(22)->get('name=' . AdminLinksInFrontend::opcPageName); // in one go $p = $this->pages->get('parent=22, name=' . AdminLinksInFrontend::opcPageName); Admin->Setup has the id of 22 here too. I forgot to mention that it's PW 3.021 here but it seems you figured this out
  6. I'm using this module recently to put items to the sidebar, and works well. However, when it comes to editors, they don't have access to pages under Admin, so they can't access these sites. Of course I could add them permission but that's risky. So I went with this route: add a Page under Admin, set a template file to it (_sidebar-item.php) create a page under the Home with similar name in _sidebar-item.php get the page under Home: <?php namespace ProcessWire; $p = $this->modules->get('ProcessPageList'); // try to get a similarly named page in root $rootPage = wire('pages')->get('parent=1, name=' . wire('page')->name); if ($rootPage->id) { $p->set('id', $rootPage->id); return $p->execute(); } This way non-superusers can see the sidebar item and have permission to edit (because the loaded page has a non-admin template). Without this they would get "You don't have access to list page /admin/.../".
  7. Sorry it's me again, 'Warm up opcache with PW files' throws an error here (Tracy): Cannot declare class ProcessWire\InputfieldForm, because the name is already in use 5× PHP Notice: Undefined index: dirname in .../AdminLinksInFrontend/libs/hn_basic.class.php:1748 21× PHP Notice: Use of undefined constant THOUSAND_SEPARATOR - assumed 'THOUSAND_SEPARATOR' in .../site/modules/AdminLinksInFrontend/libs/opcache.php:60 634× PHP Notice: Use of undefined constant THOUSAND_SEPARATOR - assumed 'THOUSAND_SEPARATOR' in .../site/modules/AdminLinksInFrontend/libs/opcache.php:249 1× PHP Notice: Use of undefined constant THOUSAND_SEPARATOR - assumed 'THOUSAND_SEPARATOR' in .../site/modules/AdminLinksInFrontend/libs/opcache.php:183
  8. On module install there's a PHP error: Trying to get property of non-object in .../ProcessAdminLinksInFrontend.module:52
  9. Seems OK to me - google shows that this was already on the table in PW forums: https://processwire.com/talk/topic/10802-issues-with-javascript-setheight-function-in-pw-admin/ AOS v02 is just uploaded, with some AsmTweaks fixes and a feature to move the delete button to the left on Asm fields. I use a wide screen monitor and this bugged me a lot
  10. Maybe you can use Multivalue Textformatter.
  11. I would recommend creating a page for it and add field or fields to translate: https://processwire.com/talk/topic/10443-how-to-do-this-global-vars/ Alternativel you can apply the technique discussed here: https://processwire.com/talk/topic/10447-using-translatable-strings-across-template-files/
  12. I think the admin is meant to be used on desktop but I'll see if there's an easy fix to this, maybe setting height: auto or similar is enough. Could you show an example scenario where this happens? (what field to add with what settings) Edit: try adding this to AdminOnSteroids.css and see if it helps: .maxColHeightSpacer { display: none; }
  13. Just uploaded v019 with the collapsable asmSelect fields update. The screenshot in the previous post was updated because there's always an icon in the beginning of the row to make the hierarchy easier to see (there was only a "+" icon beforehands). Double-clicking on the ending item also collapses the section. The update does not contain the ctrl+s CKEditor feature, I need to think it through how to organize.
  14. Ever got lost in asm field(set) hell? This might help:
  15. It's surely possible. Recently I've done a very similar newsletter solution, see screens here. Basically you need to send an email with contents of the newsletter page body (or other) field. Things get complex when you need things like preview email (which is a must imho), subscriber lists, etc. I've done this addons mainly with JS/Ajax.
  16. This is the first time I heard of this module and it's freaking nice, thanks!
  17. v016 was uploaded today to GitHub: enable setting template latte file with/without extension ($view->viewFile = 'basic-page' and $view->viewFile = 'basic-page.latte') $view->json_encode returns JSON encoded string/markup. Possible values are true and PHP's json_encode options (eg. JSON_PRETTY_PRINT). if "viewFile" begins with "//", $config->paths->templates and viewDir is not prepended to the view path These updates make it easier to get Ajax results, and allow placing latte files outside templates/views directory. The latter was also possible earlier using relative paths ("../"), but now it's more flexible. Getting json output was only possible using wireRenderFile() and applying json_encode() manually, which was less convenient.
  18. I hope Ryan plans to add such features to the panels you requested. I guess some features could be implemented easily, like auto width, position next to content, etc. I'll see.
  19. Thanks kongondo, saveModuleConfigData works fine. I guess @horst did a typo writing setModuleConfigData. Maybe he wrote the whole stuff by head?
  20. setModuleConfigData is a protected function so it doesn't work. Even setting it to public for testing purposes, the default module config is not set after install.
  21. Thanks! Glad to hear you can make use of it. Just tried the ctrl-s combo and I got it working. Here is a snippet I have atm if you can't wait: $(document).ready(function () { var saveButton = $('#submit_save'); CKEDITOR.on('instanceReady', function (evt) { var editor = evt.editor; editor.document.on('keydown', function (e) { if (e.data.getKeystroke() == CKEDITOR.CTRL + 83) { e.data.$.preventDefault(); saveButton.trigger('click'); return false; } }); }); });
  22. v016 is uploaded to GitHub, containing the datalist feature for filterbox + a display bug fix reported by matjazp.
  23. I would prefer drag-and-drop to ckeditor, but atm this is on the very end of the list
  24. Maybe it makes more sense if you use image tags, or descriptions.
  25. Well, for filtering items E.g if you have many images or documents uploaded and you would like to find a specific one. Or if you go to the Language Translator, there can be many translation files and it can be hard finding the one you need without filtering.
×
×
  • Create New...