Leaderboard
Popular Content
Showing content with the highest reputation on 11/10/2013 in all areas
-
3 points
-
When you want to help your clients to use the fields within a template, your descriptions might get quite extensive. I don't like the descriptions to clutter the whole edit page, it's confusing. So this little module adds buttons to all headers of fields that have descriptions, hides them by default and only shows them, if the questionmark is clicked. GitHub: https://github.com/owzim/PWPageEditDescriptionToggle Shots: Collapsed state: http://d.pr/i/EETH Expanded state, questionmark appears: http://d.pr/i/RBxr Expanded description state: http://d.pr/i/4fKw Let me know what you think. Cheers Christian3 points
-
Hi Martin, thanks a lot for adding this option, very nice! Because of the Github trouble, I manually created a patch from your changes and commited it: https://github.com/boundaryfunctions/TextareaCounter/commit/f740d8f8 I recognized that your repository is not actually a fork of mine from a Git point of view, and this is what made it complicated. The normal development model is "Fork and Pull" and should more or less include these steps: Create a fork of the repository you want to work on. Clone your fork to your computer, create a new branch and do all changes on one topic in there. Push that branch to your fork on Github. File a pull request. With kind regards, Marc2 points
-
Good to see you here Joss!! If Teppo keeps this up, we'll just have to add a new docs tab on processwire.com that goes straight to his site.2 points
-
I just switched form CodeKit to Guard. I have more control over how things work, it’s cross platform and more team friendly, and it's free. Might be worth a look for you guys as well: "Guard is a command line tool to easily handle events on file system modifications." https://github.com/guard/guard Here's a nice intro by Jeffrey Way on Nettuts+ http://net.tutsplus.com/tutorials/tools-and-tips/guard-is-your-best-friend/ Cheers1 point
-
Hi all, we lauched this big website for a festival last week, and pout a lot of work and love into this. Check out: boomfestival.org Hope you like it! and it has been received very well so far.. ( 60 000 visits in less then 1 week) It uses processwire as CMS , and I must say awesome decision to replace Wordpress we used the last editions, processwire is highly superior to wordpress as CMS . I even managed to import a lot of content from Wordpress with the Processwire bootstrap API and JSON and the help of this forum Content is loaded all with Ajax , and still backbutton does work and everything can be deeplinked . Ryan ProCache module has helped very much with Site speed and our high traffic server load If I find the time I might do a case study here...as this ajax approach moight be interesting for other developers1 point
-
I'm not sure the date is really recognized as date and that would work with strtotime() but maybe you should put it in as a string: $p->calendar->find("booked=0, checkin_1='16.11.2013'"); This should definately work $date = strtotime("16.11.2013"); $p->calendar->find("booked=0, checkin_1=$date"); Outputformatting has nothing to do with it.1 point
-
Sure, hope I can help! Stunning design, by the way, I really like it! But for your translation: In your navigational menu, you have an item "Add your cottage". This should be "Ferienhaus hinzufügen" in German. Then you have "gesamtes Finnland" in your search options menu, which would be "All of Finland" in English. I would prefer a different expression here, like "All regions" which you have in the English version, so maybe just "Alle Regionen". Also in the search menu, you have "Start" and "Ende". While that is quite alright, we usually have "Anreise" and "Abreise" for this in German. In your further search options, I was wondering what "Nahrungssuche" ("gathering food") in the activities section would mean. I suppose this indicates trips with local scouts showing where to go mushroom hunting etc.? So maybe "Pilzsuche" or "Beerensammeln" would be better. I also did not understand immediately what "employee recreation" In the equipment part of your further search options would be (in German this does not get printed out fully also, but I have a small screen here). Is this "wellness", maybe? That would be "Wellness-Angebote", or "Wellness-Behandlungen" in German. In the "summer 2014" part, the second sentence should be "Traditionell feiert man Mittsommer in guter Gesellschaft in einem Ferienhaus am See. Das nächste Mal findet Mittsommer am 21. Juni 2014 statt." In your footer text, you have in German "Fügen Sie Ihre Unterkunft zum Datenspeicher hinzu". This should rather be "Fügen Sie Ihre Unterkunft zum Verzeichnis hinzu". The following link is called "Register". In German, this should be "Anmelden". Right next to this in the footer the headline for your login reads "Unterkunftsbesitzer". I would change this to "Login für Vermieter". In your listings overview page, I noticed that the uppermost part of each listing's headline is missing. From a usability point, I found the line indicating the number of results ("cottages found") almost unreadable in my browser setting because of low contrast. In the individual listings pages, I would change "Hauptinfo" to "Übersicht", "Preisermittlung" to "Preise", and "text-reservations" to "Belegung" or "Belegungsplan". Did I already mention that I really like your design? Alex1 point
-
1 point
-
1 point
-
Thanks everybody--I'll give it a shot on Monday and see how it goes. I just watched "Cloudy With a Chance of Meatballs" with my kids and now I'm dreading this job a bit--can't recommend watching that film before doing batch operations.1 point
-
That's a good point. Actually what probably would be better here is an argument that lets you specify the max length. 500 is probably inappropriately long for many instances where you would use selectorValue, especially since this function's max length of 100 is referring to number of characters, not number of bytes. I'll go ahead and add that.1 point
-
This is awesome Ryan! I actually used your snippet below and modified it to do what I needed and it worked perfectly, Just took me longer to create the temp field .. foreach($mypages as $p) { $p->of(false); $p->image->description = $p->temp; $p->save(); } Your above snippet is definitely a time saver and has been added to my library. It works perfectly when I tested it. I just had to modify it slightly to meet my needs. I would just like to say your willingness to bend over backwards to assist others in this forum is a true judgement of your character. You and several others go above and beyond to help others learn with examples. One in particular I would like to mention who helped me way beyond my expectations was Nik. Just like you, he took the time to break things down with examples and even explanations. How you both manage to find the time, I do not know. To you, Nik and all the others who help us learn everyday, I thank you sincerely for helping us. I am confident I am speaking for others as well and say that ya'll truly make a difference to those of us following in your paths.1 point
-
Looks good. I'm actually working on a DB for a colleague and I have imported 2000 pages and 35.000 images similar like that. For testing I use breaks in the loop to just test only one import, or use a counter and import 5 or 10 images before breaking. When seeing it works well I comment the breaks. Also I make a SQL-Dump before testing/modifying/importing. And I write logfiles. And I love importer-scripts!1 point
-
It's a little confusing why you search for pages then search repeaters to then return the page the repeater is on to call renderItem($r), so you need to filter them again in renderItem() ? If you want to filter the repeater again with the date, then why don't you do it? $p->calendar->find("booked=0, checkin_1=16.11.2013") Or am I missing something? You could as mentioned earlier search for repeaters directly and then get the page they live on, but I thought you want to render the repeater and not the page. However this could look like $repeaters = $pages->find("template=repeater_calendar, checkin_1=16.11.2013, booked=0, include=all"); foreach ($repeaters as $r) { $repPage = $r->getForPage(); if($repPage->isPublic && $repPage->fireplace) $content .= renderItem($repPage); } But as said the renderItem($repPage) is confusing to me as I would expect you would want to render the repeater item $r.1 point
-
The new "Add New" button is nice feature but I'm not sure it's very useful for all sites (the way it works for now), if I have a site structure that doesn't allow for the right setup needed. Either because the template may used in different branches, and or a multisite setup. I dream of a more configurable thing, and maybe also able to disable it.1 point
-
Great Module ! I just added a setting to truncate the inserted text instead of revert to the old text. I wished to do it the Gig Hub way, but I don't understand how to do that. I've put the changed module on my github account. ( sorry ) If you like it, maybe you can add it to your TextareaCounter module.1 point
-
On a somewhat related note, I was looking into (standalone) browser-based file-managers, and found this gem: http://elfinder.org/ It's got an API, drag-and-drop goodness, archive creation / extraction functions, and instructions how to integrate it in tinyMCE + CKEditor. Gonna play around with it this weekend...1 point
-
if (file.name == "justinbieber.jpg") { done("Naha, you don't."); } The dropzone guy has clearly a sense of humour...1 point
-
Trust me, Ryan, I never pop! Sorry I have not been around. Couple of distracting bits going on earlier in the year and I was away a bit (serious glamping!) and also been working on an album for a publisher. My web activity has dwindled to nothing! I do have one little project for an angling club coming up, however, and of course I will be using Drupal, Wordpress, Joomla ... PROCESSWIRE for it. I suppose I should, as an amateur, stick to those things with thousands of clunky plugins, but for some reason I want the site to work and be more or less maintenance free. Fussy me. Hugs all round.1 point
-
Hi! I'm no php expert but I thought I should share my way of redirecting URLs from my old site setup. I'm going to use Drupal urls in this example, but should work for any url. I can't guarantee this is the best way of doing it, so please feel free to correct me if you have feedback regarding security, speed or similar. Step 1: Make sure that each page in PW has some kind of connection to its previous URL so it can recognize when a redirect needs to be done. I'm going to use the node id:s and taxonomy id:s that my pages had when they were located in Drupal. I've made sure to save them all into each processwire page in a field called "drupal_id". Maybe you could just save the old URL in a field when migrating and use that, as an alternative. Step 2: Open head.inc and add this to the very top: $thisurl = $sanitizer->url("http://$_SERVER[HTTP_HOST]$_SERVER[REQUEST_URI]"); // Check if the URL reminds you of the old url scheme if (preg_match("/com\/\?q=/", $thisurl)){ // if it looks like a node url if (preg_match("/\?q=node\/[0-9]*/", $thisurl, $nodeslug)){ $oldnid = preg_replace("/\?q=node\//", "", $nodeslug[0]); if ($match = $pages->get("drupal_id={$oldnid}")){ $session->redirect($match->httpUrl); } else { $session->redirect($config->urls->root); } // If it's a taxonomy url } elseif (preg_match("/\?q=taxonomy\/term\/[0-9]*/", $thisurl, $taxonomyslug)) { $oldtid = preg_replace("/\?q=taxonomy\/term\//", "", $taxonomyslug[0]); if ($match = $pages->get("drupal_id={$oldtid}")){ $session->redirect($match->httpUrl); } else { $session->redirect($config->urls->root); } } else { $session->redirect($config->urls->root); } } Regex is used to find URL schemes and extract drupal nids and tids from the url. These are then looked up using the api, only to return the new url. Each time the url redirect fails, it might be suitable presenting a warning to the user. I've added something like $session->message("This URL seems to have changed. Please use the search if you didn't find what you were looking for") on the line before redirect (not part of the code example above, for simplicity's sake). Hope this can be useful for someone else, too. And again, feel free to leave feedback! I'm here to learn, too1 point
-
I feel the same way. Many times these features are "required features from cms" when organisations are buying a new site. Then afterwards many of them actually never use these features. It's also countless time I have build many kinds of content aggregators, where "we really need to filter/sensor/schedule content". I say them that I believe you never use these features, are you sure you want to buy custom development here. They always want and after a year when I check the site they have never used these features. I guess it is mostly for "feeling for control". Also these things create a fabulous demo. What comes to other way around: retrieving history, restoring removed pages etc. These are rarely used things too, but they actually make updating feel more secure and when build well - they lighten the support burden.1 point
-
ProcessWire 1 had built-in live drafts and versioning. I was particularly proud of these features, but I was always surprised at how little they were used. It turns out that most end-users don't actually write content in the CMS. They tend to go to the CMS when we are ready to publish something. This doesn't define everybody, but I think it defines most CMS end-users. At least that was my experience, repeatedly. As people building sites and applications, I think we tend to assign more importance to these things than they deserve because we ourselves are much more likely to use the CMS as a composition tool than our clients are. This is why live drafts (drafts of already published pages) have not been high priorities as yet in PW2. But there is that small group of clients that these features are actually quite important. That's why this is something that I think belongs on the roadmap. the strategy I'd planned to take was to clone the live page to a new but unpublished page that would become the live draft. It would have an extra field (behind the scenes) indicating that it's a variation of another page. When the editor wants to publish it to be the live page, it would push the unpublished page's data to the live page's data, and then delete the unpublished page. This is important because the original page ID needs to remain in tact. That pushing of data gets a little tricky when it comes to some fieldtypes (like repeaters and files) but that's where the fun will be. Side note, but protected methods are still hookable. The only methods that aren't hookable are those that aren't preceded by 3 underscores.1 point
-
You can code the redirect yourself instead setting it in the templates access settings: if (!$user->isLoggedIn()) { $session->redirect($pages->get('/login/')->url . '?message=' . (int)$input->get->message); } Or store the message ID in a session variable and read it out on your login page. (Code not tested... )1 point
-
Hi NikNak, You should be able to change the title of the modules by changing the title value of the page. For example for Google Analytics, the page is (default) located under Admin. You can open the page and set another title for german. I think this should work? For translating strings inside the page, you'll have to translate the file "/site/modules/ProcessGoogleAnalytics/ProcessGoogleAnalytics.module", as Manfred suggested. Cheers1 point
-
This is one thing I love about PW. Many heads thinking and suggesting, one head deciding and acting quickly1 point
-
Spex is official now, I've added this to the modules directory =)1 point
-
I only came up with the code, and even forgot that you can do that now But If I even forgot about it, how come you do it 50 times a day??1 point
-
You got the who and what but not the where. Access is defined per template and inherited. So simplest is to edit home template and define access for your new role there.1 point
-
1 point
-
This case study relates to the topic here: http://processwire.c...ndpost__p__8988 about creating an archive of 'stories' about how PW has helped in relevant real life scenarios. Website: http://www.ray-dale.com RayDale Multimedia Ray Dale is a multimedia designer. His portfolio website was 2 years old as of March 2012 and in need of a refresh. He found that the content management for his website was more time consuming than he wanted and the website was generally slow in performance and complex to update. Ray needed: A website that could showcase his latest work with separate portfolio content types The ability to show lots of images and videos in each section Complex interlinking between each portfolio item - where each item would belong to a number of simultaneous categories To be able to publish a number of pages under various sections on the website To have a condensed navigation structure - not over-facing the user with navigation A blogging space that was easy to update To gain complete control over the HTML, CSS & JS markup and therefore the design of the website The ability to take more control over the admin experience - without using a host of plugins - so that the CMS could be used for clients to make their lives easier Speedy performance - even if a shared hosting platform were used Good site security The previous solutions Ray was previously using Drupal as a content management system. Drupal is a great system, it’s incredibly flexible, it can be made faster and using template overrides, almost complete control can be taken of the HTML and CSS output. However, the process to achieve any of this is time consuming and clunky from a web designer / front end developer perspective. Drupal was also going to require a number of plugins to be installed to achieve a lot of the required functionality. Ray tested migrating his website over to WordPress. WordPress is another fantastic blogging system with light CMS functionalities. WordPress is generally easier to use than Drupal and a lot of control over the HTML & CSS markup can be delivered - in a much easier manner than Drupal. However, WordPress is still light on CMS features in the admin system. This means that it is difficult without either using a lot of plugins or custom php development (using the WordPress API) to have custom content types and fields. The decision to use ProcessWire Having searched around for an alternative to Drupal and WordPress - revisiting other CMSs that Ray had also previously used - Ray eventually landed on ProcessWire having read about it on a forum. Right from watching the initial video produced by Ryan Cramer (the creator of ProcessWire) Ray was intrigued by the possibilities that ProcessWire seemed to offer - effectively solving all of the issues currently faced. To summarise ProcessWire offered: Custom content types in the admin Custom field types in the admin Good control over media uploads A simple to use admin system A neat and simple API for custom frontend / backend development A customisable admin experience The ability to have a custom admin url Complete control over HTML markup Good security with flood control A powerful and flexible templating system (that was also simple) Ray was extremely impressed by the features that ProcessWire offered, however, many CMSs look great until you actually start using them - where the unnecessary complexities, weak architecture and terrible, bloated functionality often start to appear. The functionality seemed so promising that a gamble was taken to build the Ray Dale Multimedia website - with very little time now available - to ProcessWire and test how it performed. Building the website Having built the original Ray Dale Multimedia website in Drupal, then converted to WordPress before deciding to gamble on ProcessWire - Ray now had very little time left to build his portfolio website. As a testament to the ease and speed of using ProcessWire - he was able (with a little help from articles in the forum) to rebuild the Ray Dale Multimedia website in two days of effective full time development. This included all of the content creation and learning the new system - with the inevitable (but surprisingly smooth) learning curve. Enabling complete control over output ProcessWire allowed Ray to write HTML and CSS without any of the interference you get from other CMS systems. So, Ray was able to use the following frameworks of his choosing: HTML5 boilerplate jQuery Modernizr Masonry A customised version of the 960 fluid grid system PrettyPhoto for lightbox images Less - to create minified CSS Though it must be said that literally anything can be used as ProcessWire makes no assumptions on the frontend - even on the Javascript framework. Quick and easy API One really pleasant surprise was the jQuery influenced API that ProcessWire offered. For example you can use php queries such as: $pages->find("selector"); $pages->get("selector, path or ID"); to find content in the system - you can even filter your queries by template type, fields attached to that item, etc. You can even use a range of selector operators. The API effectively works as a super powered and infinitely more flexible alternative to the WordPress loop. Cross referencing pages easily Complex cross-linking between portfolio items was needed so that capabilities, technologies and services could be linked to each item. It was easy to create a taxonomy system that worked the exact way required once the fundamental concept of how pages work in ProcessWire was understood. Building navigation that works Unlike a lot of CMSs that work effectively as ‘bucket systems’ - meaning that content is separate from any kind of structure or hierarchy by default in the system - whereas everything in ProcessWire is a page and arranged hierarchically. Whilst this may seem strange and restrictive to some used to the aforementioned ‘bucket systems’ - it works incredibly well and enables you to build navigational structures that are easy to plot a current location in. It is also something easy enough to break away from if you want a more ‘bucket’ type system. For example, in Drupal and WordPress it can be very difficult to highlight the navigation on a website if you are using custom content types. Try using custom post types in WordPress and keeping your navigation tracking which page the user has landed on - it’s extremely difficult without a fair bit of custom development (this is true as of the time of writing - WordPress 3.3.1). Because ProcessWire uses a structure and hierarchy by default - this structure makes building navigation that can track the current page very simple. Easy / flexible admin system The admin system in ProcessWire was easy and fluid to use, logical and stable. The admin system can also be overridden with templates (there are already some great community contributed templates). Modules used Whilst ProcessWire has a number of contributed modules from a thriving and helpful community - absolutely no additional modules were needed. All functionality on the website was achieved from a vanilla version of ProcessWire. Performance Another area of importance was the performance of ProcessWire. Again, Ray found this aspect to be well covered with built in caching capabilities that were thoughtfully included ‘out of the box’. The caching was simple to enable on templates and fields. The memory footprint of the Ray Dale Multimedia website was a third of that of Drupal on the same website without using addon caching plugins. Challenges The only real challenge faced was understanding that ‘pages are everything’ in ProcessWire. You build categories, taxonomy, articles, blog systems with the ‘page’ (and any fields it contains) being the basic building block for all of this. ‘Pages’ in ProcessWire can be attached to templates and injected with fields to enable the creation of literally anything conceivable. However, understanding this concept takes a little work for people used to other CMSs such as Drupal, WordPress and Joomla. However, in context - and compared to other systems - this learning curve is still fairly easy. There are so many other time savers that this learning curve becomes negligible. The other area that Ray had to understand about ProcessWire was that there aren’t any template system paradigms that exist in Drupal and WordPress. Other systems have parent and child templating systems with default parent templates that can be leveraged, however, because ProcessWire makes no assumptions on how you are going to build a project (being a true framework) you currently need to create your own template files. This is made easy by good documentation on the ProcessWire website and a decent set of ‘starter’ template files that come as part of the default install. Conclusion ProcessWire was an absolute dream to work with. Ray found it to be very stable, well thought out and hugely flexible. So much so in fact, that Ray has decided to standardise on using ProcessWire for upcoming web design projects. The flexibility and simplicity of the admin system, combined with power in frontend development that ProcessWire provides is something that Ray found to be liberating and more importantly ‘best in its class’.1 point
-
You can definitely do everything that you can in those other CMSs. But another thing to note is that both Drupal and Wordpress are primarily bucket-based CMSs, whereas ProcessWire is a page hierarchy-based CMS (as are MODx and SilverStripe, as far as I know). In a bucket-based CMS, you have no hierarchy other than an individual bucket. So custom taxonomies/categories/tags become the primary means by which you establish hierarchy (beyond a content type). Whereas in a page-hierarchy based CMS, you already have a hierarchy present which directly relates to URL structure. So additional categorization is less often used than it would be on a bucket-based CMS. I'm not suggesting that one approach is necessarily better than the other for most sites, except that I prefer a page hierarchy-based approach that can be used like a bucket when the need calls for it (which is ProcessWire's approach). I also feel that the page hierarchy approach is demonstrate-ably better at the large scale. I have a feeling we have the same preferences in this area, based on the other CMSs I know you like working with.1 point