Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 05/04/2013 in all areas

  1. Check it out this page with useful jquery plugins. Might help you!
    4 points
  2. It does even offer an SCSS file and a Grunt build script. In my book, that's pretty much perfect. It is also very accessible (e.g. using button for elements which actually are buttons), it seems to offer a fallback to display the content differently on very small screens (where a lightbox really doesn't make any sense) … boy, I wish more jQuery plugins other would be thought-thru that well.
    2 points
  3. You could achieve pretty interesting results by taking this idea a bit further: Define areas on front-end where new elements (widgets, nodes, blocks, whatever) can be dropped and create new page fields for each of them, set up a collection of pre-defined blocks (templates, including proper template files for this purpose) you want users to be able to drop in, create a clean way to add new pages / edit existing ones via front-end (edit/add button, something like Fredi), store newly created pages somewhere and attach them to page field on current page automatically. Preferably you would also let the client re-arrange these blocks by dragging on the front-end side, to make it all function properly. Perhaps even drag blocks from one area / column (page field) to another? That's all very much doable, though I would imagine that it could take quite some time to work all the details out (such as where to store those pages to keep things smooth and stuff like that.) I'm definitely not advocating anything like this, based on similar reasons others have stated above (such as the fact that pages created this way usually end up unbelievably messy in the long run and no longer serve any real purpose, other than perhaps making some content editor very proud of herself) -- just saying that ProcessWire can be used for it if it's what makes you happy. If you're into it, why don't you give it a try yourself? See where it takes you and ask if you need any advice Been there, seen both of those happen more than I'd like to remember. For a very long time I believed this to be "the best way" (partly because it worked for us and made our clients very happy), but after listening and seeing all those problems it caused for our clients at the same time, I've come to one conclusion: this model is in reality one of the worst enemies of properly structured, usable and logical web content. It requires serious mental fortitude to keep things in order when you've got all the tools you could ever ask for right within your grasp. This is true especially in the long run.. and especially when there are multitude of editors to deal with. Ever been asked to re-organize a ten year old site for a client, one that's seen hordes of editors, various shifts in content strategy etc.? Not a trivial task and each and every page having a very different structure doesn't really help. It's rare for there to be someone who could keep it all under control either -- that kind of thing is too often limited to huge organizations only and even then resources tend to be scarce. From my point of view the most obvious (even if still only partial) solution for this is a clearly defined structure that editors must stick with, even if it doesn't please them at all times -- which is exactly what ProcessWire provides tools for. Clients may not "get it" at first, but that's why we as designers, developers and professionals should explain and teach them why this is a good thing. I rest my case.
    2 points
  4. Why do "the clients/editors would like to combine them as they wish"? In my experience this is mostly a type of "I need to control" things. There are some exceptions but usually this doesn't benefit the reality (or goal) of a page. Offcourse, regular content like bodytext or images need to be controlled, but in my opinion every type of page has a goal. A designer (UI, UX or visual) determines (offcourse in cooperation with the client) what that goal is. Most of those goals I can be held accountable for since I'm designing or proposing a design to a client. When you give an editor options to create pages as they wish I've seen two scenarios happen: 1. They hardly ever use it (The client is not to blame since they are focussed on other things like running their business) 2. They overuse it (The client is not to blame since they want it "all" and we need to decide what is really important - the goal) It's both a maintance (from client perspective) and a user (the visitor of the site) issue. I always try to make this as clear as I can. That said I realize some content blocks can come in handy but I hardly ever see a proper use of using content blocks/widgets (like WordPress). As always you should test this in reallife scenarios/use cases, but from my experience I've learned that this is hardly ever really needed. I think you should talk about using content dynamically — where ProcessWire is really awesome.
    2 points
  5. Hi Folks, today we will learn how to set up a simple jquery plugin called calendario and fill events trough our admin backend. || ATTENTION || Modern Browser needed First of all, we need the jquery plugin. Grab your copy here: http://tympanus.net/...alendar-plugin/ Now create a new template file, lets call the file calendar.php In the next step we have to include all the needed files from the .zip package. You need the following .css files: calendar.css custom_2.css demo.css Just include them in the <head> </head> of your template file. Feel free to merge them together, so you could save some http connects. Now we need to include the needed javascript. Make sure you have included the latest jQuery library. Include the jquery.calendario.js and the modernizr.custom.63321.js right into the bottom of your template file. Save the calendar.php Now we will set up Processwire where the magic wil happen. We just need one new template. Create a new template called calendar. Assign the field headline to our template. Allow children to just use this template. Hit the save button. Now create a new Page as child of home and call it Calendar. Assign our calendar template to this page. Almost ready. Now we have to do some little scripting in our template file calendar.php Add this html markup to our calendar.php <div class="custom-calendar-wrap"> <div id="custom-inner" class="custom-inner"> <div class="custom-header clearfix"> <nav> <span id="custom-prev" class="custom-prev"></span> <span id="custom-next" class="custom-next"></span> </nav> <h2 id="custom-month" class="custom-month"></h2> <h3 id="custom-year" class="custom-year"></h3> </div> <div id="calendar" class="fc-calendar-container"></div> </div> </div> Now we have to call the javascript function, to get the calendar running. Just put this snippet right under the included jquery.calendario.js <script type="text/javascript" $(function() { var transEndEventNames = { 'WebkitTransition' : 'webkitTransitionend', 'MozTransition' : 'transitionend', 'OTransition' : 'oTransitionend', 'msTransition' : 'MSTransitionend', 'transition' : 'transitionend' }, transEndEventName = transEndEventNames[ Modernizr.prefixed( 'transition' ) ], $wrapper = $( '#custom-inner' ), $calendar = $( '#calendar' ), cal = $calendar.calendario( { onDayClick : function( $el, $contentEl, dateProperties ) { if( $contentEl.length > 0 ) { showEvents( $contentEl, dateProperties ); } }, caldata : { <?= getEvents(); ?> // this is our function to grab our events }, displayWeekAbbr : false } ), $month = $( '#custom-month' ).html( cal.getMonthName() ), $year = $( '#custom-year' ).html( cal.getYear() ); $( '#custom-next' ).on( 'click', function() { cal.gotoNextMonth( updateMonthYear ); } ); $( '#custom-today' ).on( 'click', function() { cal.gotoNow( updateMonthYear ); } ); $( '#custom-prev' ).on( 'click', function() { cal.gotoPreviousMonth( updateMonthYear ); } ); function updateMonthYear() { $month.html( cal.getMonthName() ); $year.html( cal.getYear() ); } // just an example.. function showEvents( $contentEl, dateProperties ) { hideEvents(); var $events = $( '<div id="custom-content-reveal" class="custom-content-reveal"><h4>Termine am ' + dateProperties.day + '. ' + dateProperties.monthname + ' ' + dateProperties.year + '</h4></div>' ), $close = $( '<span class="custom-content-close"></span>' ).on( 'click', hideEvents ); $events.append( $contentEl.html() , $close ).insertAfter( $wrapper ); setTimeout( function() { $events.css( 'top', '0%' ); }, 25 ); } function hideEvents() { var $events = $( '#custom-content-reveal' ); if( $events.length > 0 ) { $events.css( 'top', '100%' ); Modernizr.csstransitions ? $events.on( transEndEventName, function() { $( this ).remove(); } ) : $events.remove(); } } }); </script> We are almost finished, but we are missing some very essential, have a look to our javascript. We are calling a function named getEvents() This function will grab our events and fire it right to our calendar. So here is the code: function getEvents() { $events = wire('pages')->get("/calendar/")->children(); foreach ($events as $event) { echo "'$event->title' : '<span>$event->headline</span> ',"; } } Put this snippet above the javascript includes. We will now create our first entry. Go back to the PW admin backend and create a Child of Calendar. Title and name need the Date on which the event has to be displayed. You have to form a date in this format: mm-dd-yyyy e.g. 12-27-2012. The headline field is our Event description. Hit the save button, go to your site and enjoy your event calendar. With a little coding you could extend the calendar to let it look like mine attached as screenshot. Hope this was useful to somebody. Cheerio.
    1 point
  6. Must see video - f*ck you pay me http://vimeo.com/22053820
    1 point
  7. Ok, there is no need to change the core for this. I created a small module that allows it for those that really want to do it. https://github.com/ocorreiododiogo/ProcessHomeAdmin
    1 point
  8. Horst, for you https://chrome.google.com/webstore/detail/grooveshark-germany-unloc/docdgimmdejoiemdafcgeodchlbllgac?hl=de or https://addons.mozilla.org/En-us/firefox/addon/scilors-grooveshark-unlocker/
    1 point
  9. You can generate name, value and validate CSRF in PW like this $csrf_name = $session->CSRF->getTokenName(); $csrf_value = $session->CSRF->getTokenValue(); echo "<input type='hidden' name='$csrf_name' value='$csrf_value'/>"; And validate it with if($session->CSRF->validate()){ // valid }
    1 point
  10. The result of the find is an array, so you can't get the children of it. If there's only one page with that template you can do: $results = $pages->get("template=news-month-archive")->children("sort=-news_date, limit=10");
    1 point
  11. Something like this? $allPages = $pages->find('template=template-X'); $selectedPages = $page->pagesWithTemplateX; foreach ($allPages as $p) { $selected = ($selectedPages->has($p)) ? 'selected' : 'not selected'; echo $p->title . " is {$selected}"; }
    1 point
  12. ... Beer Pee videos and films ... get it?
    1 point
  13. One simple approach could be to code up some Shortcodes for them to use inside a textarea. This way the developer can control the functionality and the client can insert and position stuff with relative ease. The developer should write some clear instructions to go along. Of course, this has it's limitations but if done correctly this can be pretty powerful. <fieldbodytext> <p>some text> [myGallery] // it could use pics attached to a page image field <p>some more text</p> // embed a video using mods.pw/D <p>some more text</p> [myLatestNewsListing] <p>etc.</p> </fieldbodytext>
    1 point
  14. It isn't too hard. Make sure you add a limit selector and output the $completeListOfItems->renderPager() function somewhere in your template.
    1 point
  15. to make the first page in the admin the one that appears by default. I was working on custom admin pages module, and occurred to me that PW could be flexible on this also. Although personally I really like the tree as the default view, I thinks it should be the responsibility of each one to decide about something like this.
    1 point
  16. I've run into a similar issue on one of my sites that has a lot of accounts to manage. I'm hoping to improve the core modules (ProcessPageType and/or ProcessUser) in this regard whenever there is bandwidth to pursue it.
    1 point
  17. I wonder why this is the case? Sounds like bug to me, I will have to try and duplicate. Has anyone else run into this? I'm unclear about why the homepage should be hidden and unpublished? From an SEO standpoint, I think it's a little better to let your homepage (root, no language segment) serve as the homepage for your default language. The thinking here is that people often link to your domain rather than a specific page in the domain. It's technically stronger to have those links resolve to an actual page rather than to a redirect. Here's another good example of a language switcher that uses the multi-language page names module: http://processwire.com/talk/topic/2979-multi-language-page-names-urls/?p=33537
    1 point
  18. Just found another really interesting lightbox. Magnific Popup is a free responsive jQuery lightbox plugin that is focused on performance and providing best experience for user with any device. It's build for speed and seems highly customizable through css (and not javascript like most).
    1 point
  19. ..and now I can let go of trying to come up with a less questionable name for a planned module listing active hooks! Working title was Hook*r.
    1 point
  20. I've got this feeling that hooks debug section is going to be my new best friend. That information could have prevented couple of very nasty situations already. Glad to have it here now, awesome stuff Ryan!
    1 point
  21. Enhanced debug mode The dev branch also includes an enhanced debug mode in the admin. It's all been cleaned up to look better and provide more info. It also includes a new section that outlines all of the runtime attached hooks currently active in the system:
    1 point
  22. I often listen to this kind of music while my fingers are dancing on the keyboard..
    1 point
  23. Just stumbled upon Fresco. It features a responsive (even my mother is responsive these days) lightbox, fullscreen zoom, retina-ready skins (sweet), Youtube and Vimeo integration for HTML5 video and a powerful Javascript API (seems cool). Haven't used it, but looks really nice.
    1 point
×
×
  • Create New...