Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 11/24/2018 in all areas

  1. This week is the Thanksgiving holidays here in the US and it’s one of those weeks where there’s no school for the kids, so it’s a little hard to get work done. I don’t have any major core updates to report this week, so I’m not going to bump the version number up today. However, look for a new dev branch version next week. We will also release a new master version before the end of the year… sometime within the next month. Before releasing the new master version, I’m primarily interested in resolving any issues present in the current dev branch that are not present on the current master branch. Meaning, issues that have arisen due to some recent change only on the dev branch (if there are any). So if you are aware of any issues experienced on the dev version that are not on the master, please let me know. Thanks for your help in testing. Even though it’s been a vacation week, I’ve been waking up early every morning to work on the new PW website. Lots of continuing progress, and I should have another update on that next week along with a new dev branch version of the core. Thanks for all the feedback from last week’s post. Among other things, I caught that folks don’t like the skyscrapers anymore (as a visual element), so I’ve taken them out and agree it’s better without them. I’ll have some updated screenshots next week. Off topic, but was so excited I had to tell someone. I got a computer upgrade this week after 4 or so years of working off the same laptop. A few keys on my laptop keyboard recently stopped working (letters in the word “ProcessWire” — I wore them out), so I’ve been using an external keyboard plugged in. That’s been working alright, but made it hard to see the screen since I can’t sit as close with an external keyboard in front of the laptop. It was getting a little tiresome to work on, the keyboard wasn't repairable without rebuilding the whole laptop (costly), and it was basically time for an upgrade, but computers are expensive and I was resigned to waiting another year. Over these Thanksgiving holidays I found out a family member had bought an iMac a year or so ago and didn’t like it, so they were going back to a PC. I said, “hey why don’t you sell that iMac to me?” We came to an agreement. Now I've got it here and am moving my development environment over to this newer computer, and have been working off it for a couple of days and loving every minute of it. It's going to help out a lot with developing ProcessWire.
    6 points
  2. New kid on the block: https://squoosh.app/ Found in this otherwise recommended article: https://www.i-programmer.info/news/146-uiux/12318-news-from-chrome-summit.html with other gems like: https://chrome.google.com/webstore/detail/visbug/cdockenadnadldjbbgcallicgledbeoc/rela and https://web.dev/measure
    4 points
  3. @lenoir - I think all those old themes should be removed from the modules directory - hopefully with the imminent site rebuild they will be. I think the problem with PW's admin theming approach is that new functionality doesn't make it into 3rd party themes. I have always said that we need a skinning approach, rather than (or perhaps in addition to) theming. That said, the approach that AdminThemeBoss takes is in effect a skin, rather than a separate theme and I think this is great and is perhaps a model for others to follow.
    4 points
  4. @Roych Repeater items are also pages, but they are hidden under admin page, so they don't have URLs, but you can use URL segments for that. You should allow URL segments on you 'about' page template. Then you can construct URL based on team repeater item id or other fields inside repeater: <?php $summary = truncateText($team->body); echo "$summary ...";?> <a href="<?php echo $page->url($team->id); ?>">Read more</a> Then on you about page template: if ($input->urlSegment1) { $pagename = $input->urlSegment1; $match = $pages->get($sanitizer->int($pagename)); if (!$match->id) throw new Wire404Exception(); echo $match->render(); return $this->halt(); } ---------- By the way you can use $sanitizer->truncate() to truncate your summery text https://processwire.com/blog/posts/processwire-3.0.101-core-updates/
    3 points
  5. Good solution, but a couple of things: 1. It would be sensible to add a few restrictions about what page can be retrieved by the $pages->get(). The page ID is user input so potentially any page ID could be inserted into the URL allowing a user to see pages that they should not have access to: unpublished repeater pages, or indeed any page including admin pages could be rendered (although PW has extra checks here that would probably prevent anything sensitive from being disclosed). Something like this would be safer: $id = $sanitizer->int($input->urlSegment1); $match = $pages->get("id=$id, template=repeater_your_repeater, status!=unpublished"); 2. Calling $match->render() will only produce output if a template file exists for the repeater, which is normally not the case. It's possible to add a repeater template file but it might be easier to echo individual field values from $match.
    2 points
  6. Why? It is possible using url segments, but I think it would be better to create pages. You have all the benefits that pages bring with them, like security (see RobinS post below!!), proper url handling, maybe page path history if enabled etc...
    2 points
  7. Activate debug mode in config.php, and also check your server's error log files. With something like the web development browser extension you could at least see if the server returns HTTP 200 or 500 - that would be a start for further debugging. You could also copy everything to another server, and try if you can login there (of course, do a mySQL dump, adjust config.php file etc.)
    2 points
  8. I would copy it to a dev server first (locally) and switch to PHP 7.x and test it out completely (backend and frontend) with debug mode on.
    2 points
  9. @PWaddict - it should now work in the latest version. @simonsays - I think all your repeater issues should also now be fixed - sorry again for the huge delay on this.
    2 points
  10. @dragan Yes, didn't help. Still @bernhard I have opened an issue https://github.com/processwire/processwire-issues/issues/743 @BitPoet Thanks, yes I see, there is no way to prevent conversion to int if(is_int($value) || ctype_digit($value)) { $value = (int) $value; if($_sanitize == 'selectorValue') $_sanitize = ''; // no need to sanitize integer to string } Also, if you consider this as a bug, please, leave a comment on GitHub.
    2 points
  11. New links from the Debug Mode panel's "Cache" section to edit it in Adminer: Adminer DB icon links to where you can easily review the cache content, edit, change the expires datetime, or delete it. Also note that Adminer now has @bernhard's request for a PW icon link back to the site's PW admin backend. Let me know if you guys have any suggestions for other direct links to Adminer - I am finding these very handy.
    2 points
  12. It is quite common to use one or two characters for "translate functions", since they are typed and used a lot. Some examples: https://codex.wordpress.org/I18n_for_WordPress_Developers https://api.drupal.org/api/drupal/includes!bootstrap.inc/function/t/7.x https://docs.joomla.org/Making_templates_translatable Underscore appears to be a popular one.
    2 points
  13. emplate Field Widths Adds a "Field widths" field to Edit Template that allows you to quickly set the widths of inputfields in the template. Since v0.2.0 the module also adds a similar field to the settings of Edit Field for Repeater, FieldsetPage and Repeater Matrix allowing you to quickly set the widths of inputfields within the Repeater/FieldsetPage field, or within each Repeater Matrix type. Note: widths are only saved if the edit form is submitted with the "Field widths" field in an open (non-collapsed) state. Edit template Edit Field: Repeater Edit Field: Repeater Matrix Why? When setting up a new template/repeater or trying out different field layouts I find it a bit slow and tedious to have to open each field individually in a modal just to set the width. This module speeds up the process. Config options You can set the default presentation of the "Field widths" field to collapsed or open. Widths entered into the "Field widths" field are only applied if the edit form is submitted with the field in an open (non-collapsed) state. "Collapsed" is the recommended setting if you think you might also use core inputs for setting field widths in a template context. You can choose Name or Label as the primary identifier shown for the field. The unchosen alternative will become the title attribute shown on hover. You can choose to show the original field width next to the template context field width. https://github.com/Toutouwai/TemplateFieldWidths https://modules.processwire.com/modules/template-field-widths/
    1 point
  14. Hello, Currently I'm hunting for IT deals, so I thought I'd share what I find interesting. If you happen to find more IT and webdev related offers, please share it. VPN: Cheapest VPN with P2P, streaming (Netflix, BBC, etc...) support, multi device (routers too), 5 simultaneous device connections, 5 year deal: https://www.purevpn.com/ I did purchase it. MAMP Pro, I've been waiting for this ? new licence and/or upgrade: 25% by using a coupon https://www.mamp.info/en/store/black-friday/
    1 point
  15. I'm looking forward to client-side image resizing in PW. I have clients who will upload massive 24-megapixel 10MB images without a second thought. I use the "Max width for uploaded images" option but it's not working reliably because the oversized images still get through somehow (perhaps out-of-memory issues). Anyway, I was looking for a foolproof way for non-tech-savvy clients to resize images and found this: https://bulkresizephotos.com/ Images are resized client-side so it's much faster than many of the other online tools. You can resize multiple images at once and get a ZIP file back with the results. And the best feature is that you can set the tool up how you want and then generate an embeddable drag-and-drop widget, so it's super-easy for clients to use and there are no options for them to mess up. I created a Hanna Code for the widget and added it to the online documentation I supply to clients so it's right there when they need it. Could even potentially be embedded directly in the admin theme. Until client-side resizing comes to PW this is a useful stopgap.
    1 point
  16. That's a good point, thanks. Have changed to left alignment in v0.1.5. Not sure I want to make this change as if the show original field width config option is enabled it makes the label a bit disconnected from the input, and for longer field names in narrower columns (esp. on narrower screens) it increases the likelihood of the field name not fitting within the column width. Having the field label break to underneath the input wouldn't be great. So I'm thinking the costs aren't worth the benefit of slightly more efficient use of vertical space. But if others would prefer everything on a single line I'm willing to reconsider. Yeah, not sure I'm up for tackling that, but if you're tinkering around some time and find a solution that would be cool. ?
    1 point
  17. Great idea and implementation, even though I could live with a mouse dragging - I know it would be a tough task, so it's NOT a feature request ? I played with it and left-aligning the inputs would disable the "jump" when the width value is changed via mouse (after each click on the number input spinner you have to move the mouse a bit). Also note that the inputs and names are in one line that makes the "editor" more compact. Unfortunately the module is not compatible with aos_column_break, but I don't expect the module to support it as it would be really hard. For example, the corresponding page looks like this with the above template: In theory it would be not that hard to support the "main" tab but additional aos columns can set inside tabs which would be a nightmare to deal with ?
    1 point
  18. When we submit the login form of your admin page, the response is a 404 error code. Also your attempt to visit the reset.php failed, you might have an issue with the .htaccess file. You could try the following : backup everything create a file - disable-procache.php - on the root web dir (along the index.php file) with this code: <?php namespace ProcessWire; require_once('./index.php'); // get the module $pc = $modules->get('ProCache'); // turn off procache $pc->cacheOn = false; visit the page at http://yourwebsite.com/disable-procache.php replace the .htaccess file with this https://github.com/processwire/processwire/blob/master/htaccess.txt (do not forget to rename it to .htaccess) try to login - result ?
    1 point
  19. Thanks, fixed in the latest version.
    1 point
  20. Alternative to PS and much more interesting illustrator...for those who hate montly rates...;) https://affinity.serif.com real 30% off - for beginners the workbooks are great!
    1 point
  21. Same problem here! Removing the content of the /site/assets/cache/ProcessWireUpgrade folder wasn't enough. Needed to remove this folder completely.
    1 point
  22. I have to agree with you @diogo, we probably lost this one. But there are many more of them out there coming in here. So putting a smile on, checking if API reference tab is open and back to the keyboard to complete our mission))
    1 point
  23. Good point. I am attaching a new version here for you to test. I don't have much time this morning to test it properly, but hopefully this will also handle that. @simonsays - could also please test this version? ProcessCustomUploadNames.zip
    1 point
  24. Thanks @Robin S - I see that adding the tabbed interface was a significant amount of work - I think it's awesome though so thank you ? One small thing - it needs a fallback to tab_name if there is no label set. This should be an unlikely scenario, but without it, you can't get to the other tabs. $markup .= "<li class='tfw-tab{$active}' data-tab='tfw-{$tab_name}'>" . ($tab_data['label'] ?: $tab_name) . "</li>";
    1 point
  25. Yeh - so I see. Now I've dug a bit more. I'd not encountered it before. I'm still horrified but as I'm not going to write my own CMS I'll just shut up now ?
    1 point
  26. v0.1.3 adds a tabbed interface for fieldset tabs, and there is a new config option to show the original field width alongside the template context field width.
    1 point
  27. Yep although adding image links on a textarea field that belongs to another page it doesn't update them.
    1 point
  28. Oh sorry, I missed that distinction. I'll see what I can do about supporting that situation.
    1 point
  29. If I understand correctly you've updated the part of the module that searches img tags inside textarea. The problem I'm having has nothing to do with img tags cause I do NOT add the images inside textarea. I only add their LINKS via "Insert Link" and then "Select File".
    1 point
  30. Hi Robin, I originally envisioned PW Gems as casting a wider net than it currently does, with search methods for additional PW sources including Google, github gists, code snippets embedded here in forum posts, as well as public gitlab and bitbucket repos. I only got around to doing the PW repo, github and packagist searches in the end and, of these, only the PW Repo search extracts version information. There's no reason these searches couldn't dive deeper and look for versions from well known files, but I've not done it. Of course, not all the projects turned up are modules. Many of the repos are people's PW site boilerplates for example, though they may have a published tag or release that contains a version number.
    1 point
  31. @adrian Checking "Rename on Save" and inserting the image link inside textarea field via "Insert Link" and then "Select File" and finally saving the page it doesn't update the link. It always lead to the previous filename. Can you please fix it?
    1 point
  32. @ryan - this issue still exists on 3.0.119 - any chance of a fix please?
    1 point
  33. The item you want to give special treatment to is the last item in the WireArray, so you could use pop() to get that item and remove it from the WireArray: Alternatively here is a more flexible approach that you can use for any item in the WireArray:
    1 point
  34. @bernhard you are being very r...tst-donk-prrrrrrrr @Ivan Gretsky thanks for your...kkkkkkkkkakkakakakakakk....tststst...krrrrk I'm very interested in ProcessWordpessssssjoooooomla....krrrk...drupaodXpo3-lockherupcli-mate-change-oax...krrrrrrrrrrrrrrrrrkrrrrrrrrrrr....pf-nhec Sorry @Nvim, had to do it ?
    0 points
×
×
  • Create New...