Hi, On Jun 17, 11:48 am, glimmung <phil.kil...@gmail.com> wrote: > My specific concern is maintainability - I'd like to be able to > approach this in a way that enables me to drop in a new ThemeRoller > theme, or update web2py, with the minimum of fuss. Has anyone any > recommendations as to best practice, or better yet can anyone point us > at or share their experience so far? >
I've been tinkering with this, and would be interested in any feedback on my appraoch - I'm an RDBMS guy, so I'm quite happy to be told that my approach to CSS/JS is off the mark! First of all, I looked at the static demo page that is bundled in the ThemeRoller download. My objective was to get that page to work in a web2py view. There is JS and CSS in the header of that page, so I set about creating a static file called "web2py_jqueryui.html", modelled after web2py_ajax.html. Stuff is a little scattered now, but my objective is to have all my modifications in that file, other than the approach to base.css described below. Then, as a "playground" to test with I created a "dumb" controller that returns an empty dict, and a view to render it. In the body of the view, I pasted the body content of my sample page. I now have a working demo with all the JQuery-UI goodies working as expected. This has exposed what I was wary of, but wasn't able to articulate in my first post: as expected, the web2py menu is not styled in any way by the theme, because it uses web2py-specific CSS classes. Looking at the menu, and digging into where these classes are set, I see that they originate in /gluon/html.py - which is part of the distribution, and which I don't want to modify. They are defined in base.css. I'm now about to set to to create a replacement version of base.css which provides the classes not native to the jQueryUI theme - it seems that the tidiest approach is to use my own base.css, such that that is the only file /changed/, other than adding the call to include web2py_jqueryui.html in layout.html. Does this approach make sense? Have I overlooked anything? FWIW, my intention is to create a w2p application file to use as a start point for jQuery-UI apps. -- Cheers, PhilK --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "web2py Web Framework" group. To post to this group, send email to web2py@googlegroups.com To unsubscribe from this group, send email to web2py+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/web2py?hl=en -~----------~----~----~----~------~----~------~--~---