Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 09/22/2017 in all areas

  1. This week we've got new versions of the Uikit 3 admin theme, a new version of ProCache with SCSS and LESS support, plus a brand new module that provides user login, new user registration and a user profile editor, all for the front-end of your site. And of course, a new core dev version too (3.0.76)! https://processwire.com/blog/posts/pw-3.0.76-plus-login-register/
    17 points
  2. Am I the only one who likes the default admin theme?
    5 points
  3. A fantastic upgrade to ProcessWire's core capabilities. Thanks for making our lives easier.
    4 points
  4. I this is the paradox of PW's admin. It's so simple and efficient that a new user may be a little underwhelmed. As users we all understand why this is. But if you're coming from WP or something with lots of bells and whistles promoted from the initial screen, then PW can seem quite sparse. I don't think this is a bad thing at all but imagine you're a developer trying to sell PW to your team and convince them to abandon CMS X. They're going to have to understand that the beauty is in the API, the flexibility, the scalability etc etc I'm not knocking the Admin here. Just saying you only realise these things (flexibility, scalability, simplicity) when you've crossed that line and are an actual user.
    3 points
  5. I like it in the way it's more functional, and easy to move around, but you have to admit, it looks quite old. It's a bit too colorful for my taste. I like having a clean interface
    3 points
  6. In the past weeks (rather months) I was discussing ProcessWire in our agency and I had some serious trouble convincing my colleagues. The main reason for their criticism was related to the old fashioned website frontend and the older fashioned default admin theme when testing ProcessWire. So I think there is a huge benefit in an overhaul of processwire.com and also in setting RenoTheme as default, but I guess that this won't change because of the upcoming admin theme.
    3 points
  7. Have you ever tried to work with reno for some time? my first steps for every project: - reno - tracy - AOS but it took me some time to get used to reno but it's much nicer to work with imho. you have the quicklinks on the left side always available AND you have more space on the right. i guess i didn't like it in the beginning, because it reminded me of the look and feel of wordpress hope we see some action on the new admin theme soon too. and i agree with you guys that the website looks way more old fashioned than processwire is. It's like visiting a website that has the latest news entry saying "merry christmas 2007 to all our visitors!" i always "apologize" for the look&feel when i present processwire to other devs and i tell them that they should take a look under the surface.
    2 points
  8. I agree and I used to prefer it too but @tpr's AdminOnSteroids made me to switch to Reno.
    2 points
  9. I like it too. I generally mix and match, and often give clients the option. I wonder if we should have a variant of Reno with a top-nav...
    2 points
  10. @SarbjitGrewal The code looks to be from an ASP template. This is a forum for a PHP based CMS called ProcessWire. Are you sure you're at the right place? Edit: Now it's from a Genesis based WordPress theme
    2 points
  11. Cloudinary.com seems to offer everything you need and some more. You can get it to fetch images from your server on the fly and serve the right size image to visitors device without uploading images beforehand. Free tier is quite generous, too. https://cloudinary.com/features
    2 points
  12. nothing fancy here. you see it's not polished and some hardcoded values... the javascript to handle the clicks: $(document).on('click', '.ckesnippet', function() { // find correct ckeditor instance $field = $(this).closest('li.Inputfield'); var id = $field.attr('id'); var ckename = id.replace('wrap_',''); var cke = CKEDITOR.instances[ckename]; var data = cke.getData(); cke.setData(data + $(this).data('snippet')); return false; }); and the hook to modify the field: $this->addHookBefore('InputfieldTextarea::render', $this, function($event) { $field = $event->object; if($field->name == 'rockinvoice_suffix') { $del = ''; foreach($this->wire->pages->get(38967)->texttemplates as $item) { $field->entityEncodeText = false; $field->description .= $del . '<a href="#" class="ckesnippet" data-snippet="' . str_replace(PHP_EOL, '', $item->body) . '">' . $item->title . '</a>'; $del = ' | '; } } elseif($field->name == 'rockinvoice_prefix') { $del = ''; foreach($this->wire->pages->get(38967)->texttemplates_greeting as $item) { $field->entityEncodeText = false; $field->description .= $del . '<a href="#" class="ckesnippet" data-snippet="' . str_replace(PHP_EOL, '', $item->body) . '">' . $item->title . '</a>'; $del = ' | '; } } $this->wire->modules->get('RockTools')->loadAsset('ckesnippets.js', 'HrDiamonds'); }); and a repeater to setup the snippets:
    2 points
  13. Represents the instagram feed of a user. Instructions: Register a new instagram Client: at instagram. It's really important to add the current url as redirect url. (For example "http://page.dev/processwire/module/edit?name=InstagramFeed/"). Complete module settings (Client ID and Secret), leaving the access input token field empty. This value will be generated. Click the "get Access Token" link to generate code and access token in module settings. Configure username to output feed from (default setting is "self": to get the most recent media published by the owner of the access token) ... and use it! > detailed instructions at github
    1 point
  14. FacebookEvents ProcessWire module to get Facebook Page Events using the Graph API. Create an app on Facebook developers website You have to create an app to get appId and appSecret. Those keys are required. Go to Facebook Developers and add a new app. Congrats! Now you can copy your Facebook appId and appSecret. Get your Facebook page ID You can either enter your facebook page ID or the facebook page name. If you enter the Facebook page name, this module will get the page ID for you! Call Module $events = $modules->get('FacebookEvents')->getEvents(); Output Events {% for event in events|reverse %} {% if event.start_time|date('U') > date().timestamp %} <div> {% set dts = modules.get('FacebookEvents').getDates(event) %} <a href="https://www.facebook.com/events/{{event.id}}/" title="Facebook">{{dts.dates}}:</a> {{event.name}} <em>{{dts.times}}</em> </div> {% endif %} {% endfor %
    1 point
  15. Based on this forum post, I wanted to find a more elegant solution for changing a field's settings per template. Hooking the page editor after it generates the form works and may still be needed for more complex modifications. But using field & template context, it's easier to modify the field settings and it greatly reduces the need for creating an almost identical field just to adjust a few things. In my blog post, I've written on how to extend contextual options to allow any fieldtype / inputfield settings to be changed depending on the template. Hope you find it useful, and if you have any questions or comments, feel free to post them here. https://abdus.co/blog/doing-more-with-fewer-fields-in-processwire/
    1 point
  16. @benbyf DropboxAPI.module file fixed and uploaded to GitHub. Please update your version and let me know how you get on.
    1 point
  17. Wow, super update this week! The SCSS compilation feature in ProCache sounds great. Currently I have a roll-my-own solution using scssphp - does the new ProCache feature use scssphp or something different? The front-end users module is awesome news - it's one of those few missing pieces that PW has been really needing. Beginners especially will benefit from this, and because of the security considerations that come with a login system it's great to have a solution from PW's creator. I was expecting that such a module would be a "Pro" release, so big thanks for making this a free module! Can't wait to try it.
    1 point
  18. I haven't checked with PW < 3. But if it worked well so far you can update it (just replace the directory on the server).
    1 point
  19. It's really amazing how much work can be done adding Hooks where needed and you can turn Process modules and Inputfields into powerful interfaces just understanding a bit of the source code, I now don't want to write app interfaces/data models anymore, just think how I can leverage ProcessWire to do anything I want, in a third of the time. Hope everyone keeps sharing their awesome work!
    1 point
  20. Some points: I think you missed the part where you're using $locations, otherwise why are you getting all unit-options and their locations only to scrap all that and fetch it again? $unitOptions = $pages->find("template=unit-option"); // never used $unitResults = $pages->find("template=unit-option, sort=unit_name_ref"); If you're dealing with large number of pages, avoid excessive assignment of large values to variables, it'll increase memory usage, this may fill up the ram and server may start using swap partitions, which is always slower. Instead of $_GET, there's $input->get and for direct sanitization $input->get->text() (and ->selectorValue if you're going to use it in selectors). <?php namespace ProcessWire; /** @var $pages Pages */ /** @var $input WireInput */ // $myLocation = ( !empty($_GET['location']) ) ? $sanitizer->text($_GET['location']) : null; $myLocation = $input->get->selectorValue('location'); $unitResults = null; if ($myLocation) { $unitResults = $pages("template=unit-option, unit_location=$myLocation, sort=unit_name_ref"); } else { $unitOptions = $pages->find("template=unit-option") ->explode('unit_location'); // filter empty values and duplicates $unitOptions = array_unique(array_filter($unitOptions)); $locations = join("|", $unitOptions); $unitResults = $pages("template=unit-option, unit_location=$locations, sort=unit_name_ref"); } Other than these points, I'm not sure why you'd get slow results for several hundred pages. If you give a more complete picture of your page structure, we'd be able to help you better
    1 point
  21. wow, @abdus thank you for that hint! just took a look at their service and played around with their demo (https://demo.cloudinary.com/?mode=default) and this looks amazing! would love to see a module integrating with their service!
    1 point
  22. you have 3 possibilities on any page of the admin. does not seem too hard for me?!
    1 point
  23. 1 point
  24. I prefer it immensely and hope that it stays available/supported (maybe not as the default). We all need choices. I am glad to see and support progress on additional Admin themes.
    1 point
  25. The first thing I do after installing PW is switch to Reno. I see Peter's point but the admin is not for me, it's for the client, and I see them taking Reno much more seriously. When I discovered PW I had an agency that used an in-house CMS. It wasn't very easy to convince the dev team to try PW because they were underwhelmed as well. They were used to the module philosophy where you have a place to manage news, another for events, another for pages and so on. But all it took was one project to get them hooked. I'm hoping the new default theme is here before I start my next project. Fingers crossed.
    1 point
  26. try this one. I forgot to add ->type, when you add it both methods should work.
    1 point
  27. I've been using it a lot more lately and have grown to really like it. I think what I prefer are the drop downs from the top navigation bar. Reno theme doesn't have this and requires an extra click. It just feels less snappy / fast. I know an extra click isn't much but as a "power user" I could be editing multiple sites a day. I'll never get those extra clicks back
    1 point
  28. This seems to work $implements = wireClassImplements($field->type); $isMulti = in_array('FieldtypeLanguageInterface', $implements); // OR $isMulti = $field->type instanceof FieldtypeLanguageInterface; Adapting to your code: $data = []; foreach ($page->template->fieldgroup as $field) { // check if field is multi language if ($field->type instanceof FieldtypeLanguageInterface) { continue; } $data[] = $field; } return $data;
    1 point
  29. +1 Even though the new admin theme is in the works, in the meantime it could help a lot. The possibility to switch to Reno is not obvious at all for a PW newcomer, I would say Reno is kind of "hidden".
    1 point
  30. fox and freedrive offer 10G for free and googledrive 15G. You have to be careful though that the one you choose will still be there tomorrow as a provider or as a service. You wouldnt want to move gigs of pictures around on the net.
    1 point
  31. I shared very little on my Github account. Just what I don't mind making public, simple projects .dotfiles. However on my Gitlab account, that is where I house all my client websites because of the privacy. I do have one repo that gets pushed to both, though!
    1 point
  32. There's nothing invalid about the original page name in your gif. Adding the $beautify argument to $sanitizer->pageName() will give a result that is closer to the JS replacement that happens in the admin interface. But I take your point that it would be useful to have a sanitizer option that is an exact match for the JS replacement.
    1 point
  33. For anyone not following the issues repo: Ryan has committed a fix for this issue to the dev branch.
    1 point
  34. Ah, good'ol brute force solution. Glad you got it working though.
    1 point
  35. @elabx - thought I'd take a quick look into what is actually required and this seems to work well: $this->addHookAfter('ProcessPageSearch::executeFor', function($event) { $response = $event->return; $responseArray = json_decode($response, true); $matches = $responseArray['matches']; $i=0; foreach($matches as $match) { if($match['type'] == 'Pages' && strpos($match['path'], $this->config->urls->admin) === false) $matches[$i]['editUrl'] = $match['path']; $i++; } $responseArray['matches'] = $matches; $event->return = json_encode($responseArray); }); Note that it only changes the link if the match has type of "Pages" and also doesn't point to an admin url. Let me know if this works at your end ok.
    1 point
  36. Hello, this module has been updated and it is now compatible with Graph API version 2.10. Parameters 'description' and 'name' are not supported by the new Graph API version. Therefore, fields for description and name cannot be provided anymore.
    1 point
  37. I think it's important to sync `jobs` `currentJobs` fields such that `currentJobs` doesnt have more jobs than `jobs` field has. You can use the following hook to update `currentJobs`. wire()->addHookBefore('Pages::saveReady', function (HookEvent $event) { $page = $event->arguments('page'); if ($page->template != 'person') return; // make sure currentJobs items <= jobs items if ($page->isChanged('jobs')) { foreach ($page->currentJobs as $cj) { if (!$page->jobs->has($cj)) $page->currentJobs->remove($cj); } } });
    1 point
  38. Nice site! Maybe i should also try to start using the uikit admin theme... @last screenshot: Gallerie should be Galerie
    1 point
  39. Welcome to the forums! You can set it as the default in your config.php file: $config->defaultAdminTheme = 'AdminThemeReno'; User's can change between themes from their edit profile page.
    1 point
  40. Actually $page->viewable(); does check if the template file exists. See the viewable() function in the file /wire/modules/PagePermissions.module. One of the first checks it performs is $page->template->filenameExists(). If you've run into some scenario where viewable() isn't responding properly, let me know how to reproduce? What doesn't check if a template file exists are any functions that return a Page or PageArray. So you can end up with pages that don't have template files from a non-specific $pages->find() call, or $page->children call, for instance. These functions are only bound by access control (defined in the template) and page status (hidden, unpublished, etc.). The intended way to exclude pages from results like this is to use the 'hidden' status that you see on the 'Settings' tab of every page. Once page has a 'hidden' status, it's not going to show up in any find() or children() results unless you add "include=hidden" (or include=all) to your selector string. Soma's suggestion to use specific selectors to include only the things you want (or exclude the things you don't) is also a good way to go.
    1 point
  41. Or Just use template!=testimonials in the nav code or search to exlude them.
    1 point
×
×
  • Create New...