Jump to content

Martijn Geerts

PW-Moderators
  • Posts

    2,769
  • Joined

  • Last visited

  • Days Won

    31

Everything posted by Martijn Geerts

  1. I think the issue is that the image is by default an inline element. Inline elements do not respond the same as block elements. Verticaly you can't set paddings to 0 You could float the image to make it a inline-block automagicly or you could make it a block element. img { display:block; margin: 0; } // center image with class .center img.center { display:block; margin: 0 auto; } img.left { float: left; } img.right { float: right; }
  2. Looks like protected,hmmm. You could play it Dirty if you don't mind and go for AdminCustomFiles and change it with Javascript. (Don't tell anyone) But I do like to know how to change this the 'right' way.
  3. could you try this: $this->addHookAfter("ProcessPageEdit::buildForm", $this, "tryThis"); public function tryThis(HookEvent $event) { $form = $event->return; $content = $form->find("id=ProcessPageEditContent")->first(); $content->label = 'steve'; } sitting on the livin' room giving the baby milk, so no time to test what I wrote.
  4. Javascript performance is very good when you keep one thing in mind. Don't trigger repaints when you can avoids those. I can imagine all the needed data you send to the browser is in JSON. Then build the whole needed HTML structure with Javascript before attaching it to the DOM. After inserting the HTML structure fire the plug-in. When you change the viewport size (with orientation change for example) You now can Destroy what you've build with Javascript, and use the original JSON data to build the other structure. The JSON data can easily hold the data for multiple sizes of images or what ever you wish.
  5. Problem with different output (generated by PHP ) is that the default ProcessWire cache solutions (template cache & ProCache ) can't cache 2 versions for the same URL. When you want to support caching you need to create a workaround for this. (Could be done with AJAX and enabling urlsegments) Or you go for the other cache solutions ProcessWire has. For example MarkupCache. Keep in mind generating different output with PHP can be done easily without the need of caching, what is perfectly fine for smaller websites. If you need to build for a high traffic site then you need to make a good cache strategy. When you want to deliver different output purely in the browser, Javascript can easily detect the state and respond to this. Then there's no need for different source code. For example: Javascript could destroy a slider when moving from iPad to iphone, and rebuild the slider when moving back.
  6. Maintenance Update @jlahijani, the bug is fixed. Issue was exact as you described ! Added the template name to the JSON object ( for ProcessPageEdit process) Made the 'Include theme based files' conditional (PW >= 2.5.0) Fixed the empty Theme based files field notes (config settings) Fixed a view typos
  7. Thanks detailed explanation jlahijani. At first I thought it's about the checkbox value not saving, but what you say here makes sense. I'll gonna dive into this, thanks for trying to track this one down.
  8. Thats a good follow up on the Mozilla Closures article. Thanks felix!
  9. yep all kind of things. Best bet, you enable Theme based files, and use this for colors etc. (p.s. I don't like it that you remove the logo, be proud to use ProcessWire instead )
  10. What a awesome decision you made there Diogo! Wish you all what needed to make this a success. Great web BTW. About the 'menu issue': This week i've done the the 'same' menu. I inserted an extra element, the only thing that element does is opening/closing the menu. Now when the menu has the class 'closed' trigger a click on the extra element, the extra element opens the menu, after that the menu click returns false.
  11. There are more parents with the same template?
  12. I love what you've done. I could imagine you can add an extra data cleaner for the importer with the help of json_encode. Forget this, to much much my own module in my mind.
  13. @Marvin, is there a configurable maximum amount of bookmarks and tags per person ? Can imagine a 'bot' continues tagging for an x amount of time.
  14. Take a look at $config->pagefileExtendedPaths, if you want to enable this, put that one to your /site/config.php and set it to true.
  15. it's just data, best place it above all scripts, so scripts can access it. then there's no need for the $(function(){}). when the dom reached the scripts your data is already loaded. No need to wait
  16. It's kinda weird you wrap the json data in a document ready function and put it in as last script.
  17. I have sneaked around this feature many times with dirty solutions. Thanks for making this Steve.
  18. @dupalski, please follow the link/tutorial provided by Joss, there's a good explanation how to do.
  19. ->eq(0) = the first image ->eq(1) = the second ->eq(2) = the third ... and so on
  20. You could go for BundleFilesMinify if you don't need the HTML compression. (HTML compression will never be build into that module, because all my markup is always build compressed)
  21. It's a little bit off and dirty, but you could add some Javascript logic and using Admin Custom Files to thick the checkbox when an other required field is empty.
  22. Not sure in this case, ryan or soma. Think soma will pick this up, if not you could send him a pm. Or you can file the issue here: https://github.com/somatonic/Captain-Hook. Thanks, Martijn
  23. You'e browsed https as scheme, but the script's & styles are appended with http:// that's the reason it failed to include.
  24. Looks great, thanks for building this blad.
  25. Haven't experienced any problems with bxslider so maybe there's an other root of the evil. When I have troubles with HTML soup I prefer to check the syntax with the validator of W3C. Lot's of time it's just an non closed element or such.
×
×
  • Create New...