Jump to content

Jonathan Lahijani

Members
  • Posts

    633
  • Joined

  • Last visited

  • Days Won

    24

Everything posted by Jonathan Lahijani

  1. The page exporter/importer sounds very exciting. I think it would be pretty slick if you can choose access the export/import action from within the page tree itself (next to the new, edit, view etc. page action buttons). I'm also curious to know how merging would occur and the options around it. Can't wait!
  2. Let's say you're doing a redirect like this in your template: $session->redirect( $pages->get("/some-page/")->url ); Would halting be good practice after redirecting or does it not make a difference? return $this->halt(); It wasn't clear in the blog post that introduced halting: https://processwire.com/blog/posts/processwire-2.6.8-brings-new-version-of-reno-admin-theme-and-more/#new-this-gt-halt-method-for-use-in-template-files
  3. @adrianmak I would strongly consider you don't put divs in CKeditor fields as this is a very fragile and error-prone approach. My solution to this is either (a) use HannaCodes to represent opening and closing of divs or (b) use RepeaterMatrix.
  4. Shouldn't return $this->halt(); be used instead of exit(); ?
  5. Unrelated to what you're experiencing, but when I upgrade PW on my WAMP setup AND if I have a project open in Sublime Text containing that PW instance, the upgrade will "fail" at the last step whereby it renames the directories. Not a bug, but something to be careful for. It's easy to fix however if that occurs... just rename the 'wire-3.x.xx' directory to 'wire'.
  6. Hi Andreas, You'd have to ask Mike Johnston (@cmscritic) of CMS Critic that question. J
  7. Given that the ProcessWire Upgrade module has been updated as well, shouldn't it be able to upgrade an installation that's on 3.0.33 (for example) to 3.0.35? It seems to not detecting the latest version.
  8. Regarding the video tutorials, what I have completed so far is just a 50-video series of straight-up comparing WP to PW feature-by-feature, so I don't think you'd personally benefit from that since you're already a ProcessWire guru. I will release them however there's some further editing I need to do as well as making it part of an overall content marketing strategy. I haven't had time for that yet, but at least the really hard part of recording the videos is done. In regards to something like a full training series, the idea is still in my head (on paper too), however I don't have any plans yet to go full force on that as I'm focused on other ventures.
  9. Somewhere between 60-80 hours, which includes the general consulting, coding, communication and other issues that came up. I didn't track time like I normally do so this is an estimate. Superusers have full access as usual. General users, authors and vendors have access to the pages they are creators of (posts, products). In Ryan's case study from a few years ago, he implemented a hook that prevents users from accessing other user's data in the admin. That part is key. Some CSS is also being used to hide what's not necessary for non superusers to see (along with permissions enforcement). It's easy to load a custom CSS file in the admin based on whatever condition you want it to meet. For example, the following in /site/templates/admin.php if($user->hasRole("author")) { $config->styles->append($config->urls->templates."author.css"); } Thanks for catching that typo. I also updated the chart to link to the various PW modules.
  10. A note about speed... we switched the hosting from ServInt to KnownHost a couple days ago and now the site is fast... like scary fast. (note: the WordPress site was neither on ServInt or KnownHost, but rather a WP managed hosting provider which one would expect to have decent speed)
  11. Although you were experiencing this issue before enabling xdebug, xdebug itself really slows down PW. But that doesn't seem to be the issue in your case. Some things to try: try running the site on a production server and see if it's slow. if it's not, there's some issue with your local server. if you're using an old version of wamp-server (like v 2.4), try upgrading to a newer version. i hit an issue a couple years ago on an older version that was plaguing me. perhaps you're doing some crazy stuff with your code that you may not realize. keep trying to selectively remove various parts of your code and refreshing your site to see if you get a moment where everything clears up. then analyze the problematic code. Let us know how it works out.
  12. NIce work Francesco! I just left a comment on the article singing praises to generate even more excitement.
  13. Sometime after 3.0.21, PW had modifications that has messed up how PW's "Markup" field renders descriptions with HTML in them, which also affects MenuBuilder. I've created an issue on the PW Github: https://github.com/ryancramerdesign/ProcessWire/issues/1932
  14. When editing a template, you can add fields to it using the Fields dropdown. However, it can be tedious to perfectly scroll to the needed fields everytime you add one, especially if your site has a lot of fields. Is it currently possible, or would it be possible, to enable auto-complete on the fields dropdown?
  15. I developed modernrealestatesf.com which utilizes MLS listings. The approach I took was to have my client sign up with simplyrets.com which provides a clean and straight-forward way of accessing the needed listings. I then wrote a script which processes the data to our needs. The script runs a couple times a day. I'm not storing any images in ProcessWire since the images that are in the feed are already stored on Amazon which makes things convenient.
  16. Another way is to insert it via JavaScript. Note, this example is tested for the default admin theme, not Reno. First place the following in your admin.php file above the require controller line, inside your templates dir: $config->scripts->append($config->urls->templates."admin.js"); Then place the following in a file called admin.js in your templates dir: $(document).ready(function(){ $('#topnav').append('<li><a href="https://example.com/" target="_blank">Example</a></li>'); }); I'm sure the jQuery could be more elegant, but the point is it can be done via JS as well, which I ended up doing for a recent project for reasons I can't remember. In my specific example, I linked it to a Google Doc which contained help documentation for a site.
  17. Coming from a Rails background years ago, I think it's best to stick with web application frameworks for any web applications that will have heavy iterations and multiple team members. With a webapp framework, you get a testing suite, migrations, ORM, REST, MVC, specific deployment tools and many other necessities. You would have to re-do all those with ProcessWire. Furthermore, using pages to act as a router doesn't feel right. "Use the best tool for the job" and all that.
  18. $config->urls->templates will give you the relative URL, not the absolute URL containing "http://mysite.com/" part. Is there are slick way to get the absolute URL? If not, what's the next best approach?
  19. You could do this in admin.php (above the line that brings in controller.php): $wire->addHookAfter('AdminTheme::getExtraMarkup', function($event) { $extras = $event->return; $extras['head'] .= '<link rel="shortcut icon" href="'.wire('config')->urls->templates.'favicon.png">'; $event->return = $extras; });
  20. Fantastic. Been waiting very long for something that takes me back to the days of Rails migrations! I will be doing a screencast on this in my WP vs. PW series. Just in time!
  21. For those interested in migrations similar to Rails and other web application frameworks, see LostKobrakai's Migrations module: https://processwire.com/talk/topic/13045-migrations/
  22. I've got that covered for ProcessWire vs WordPress. Coming soon. It's very in depth.
  23. Better late than never. I'm almost done with my WordPress vs. ProcessWire series. I have about ~8 videos left to make. I will be uploading all the videos to YouTube in a playlist. Need a couple more weeks to finish them off and add a little polish. Here are the videos in the series (not yet in the final order): Installation Pages Page Templates Custom Fields Custom Post Types Blog Documentation API Updates Client Help Plugins Forms Shortcodes Page Order Images Videos Themes Widgets Menus Global Settings and Options Page Caching Search Engine Optimization XML Sitemaps JSON Data Search Users and Roles Config File Multi-Language Data Migration Ecommerce Community Comments Revisions Admin Themes Command Line Interface Hosting Multisite Admin Section Performance Visual / WYSIWYG Editor Bootstrapping Admin Bar Composer Debugging Front-end Editing Page Builders Each video is about 3-10 minutes long and compares a feature in WordPress with the same or analogous feature ProcessWire quickly and concisely. For example, Shortcodes vs. HannaCode, Gravity Forms vs. FormBuilder, WP-CLI vs. Wireshell, WP Rocket vs. ProCache, WP's Menu Builder vs. Menu Builder, etc. Some are a little more in-depth than others. I do give WordPress a fair shake, try to remain objective and let ProcessWire's superior approach to features speak for itself. I will most likely be adding an intro video that explains the series as well with some background as to why I use ProcessWire instead of WordPress and the philosophical differences between the two. The goal is to get people, particularly advanced developers and web firms who know how to code and who are on the fence about switching to a new CMS, to quickly see all the analogous features that they are used to in WordPress done in ProcessWire. Hopefully they will get the warm and fuzzy feeling and explore our community further. If there are any topics you feel that I have missed, please let me know. Make sure the topic is specific enough to warrant a video of its own, as this series is a feature-to-feature comparison. Thanks
  24. I read this article from WordFence recently. It gives you an idea as to how these attacks are done in detail. Worth a read/watch: https://www.wordfence.com/blog/2016/02/wordpress-security-attack-platform/
  25. To extend upon what LostKobrakai said, by basic understanding of PHP, I would say: how to set variables how to use the if control structure how to loop through an array (foreach) how to output something (echo) Those basic concepts apply for any programming language and will be heavily used in your templates. Master those with PW's easy API and you'll be like 80% of the way there.
×
×
  • Create New...