Author
|
Message
|
Paul Forsyth
|
Friday 16 April 2004 1:28:18 pm
Template code can be tricky to get right when coding. It would be nice to have a way to evaluate simple template code in a sandbox environment. It would be nice to have a page on ez.no where a textarea box would take template code, execute it (subject to sanity checks...), and display the results. Documentation on the ez.no site could then take advantage of the feature and be able to offer links to send template code to the evaluator to show particular pieces of code in action. paul
-- http://www.visionwt.com
|
Jan Borsodi
|
Tuesday 11 May 2004 12:43:53 am
A nice idea, but I guess the major problem is the input variables.
A lot of the template code relies on having content objects, nodes etc. to work, without this you would only be able to check simple code snippets. If a smart way is found to handle the variable issue then it could be quite powerful, it could even be linked to the template listing i the admin interface (A validation of template code when you stor it would be nice too). This and other types of sandbox enviroments, for instance email generation (I think this has been suggested earlier also), can be quite useful.
--
Amos
Documentation: http://ez.no/ez_publish/documentation
FAQ: http://ez.no/ez_publish/documentation/faq
|
Paul Forsyth
|
Tuesday 11 May 2004 1:35:56 am
Yes, input variables would be difficult in a proper sandbox environment. A simple version may only allow operators that dont need information from the db, but this wouldn't be of much use i think. In the next level a suite of pre-constructed arrays could be available for use. Again, this could be too limiting. The best solution would for access to a demo site and its db. Your demo sites may be ideal as the dbs are restored regularly. A read only db could be used for ez.no examples. Another benefit would be that the template eval module could be used locally, because of its dependancy on a sole db. paul
-- http://www.visionwt.com
|
Alex Jones
|
Wednesday 12 May 2004 6:29:05 am
Also, another tool that I think may prove handy would be something that allows us to see all of the un-rendered template code used to display a page. Some of my pages pull quite a few templates, causing me to wonder if I may have missed a closing <i>let</i> or <i>section</i> tag. So, it would be nice to have an alternate view that shows me all of the eZ code, including templates that are called via include tags without making any of the db calls. This will also help those of us who are rather picky about our HTML output as we could easily figure out where to put our indents, line breaks etc. Just a thought, Alex
Alex
[ bald_technologist on the IRC channel (irc.freenode.net): #eZpublish ]
<i>When in doubt, clear the cache.</i>
|
Paul Forsyth
|
Thursday 13 May 2004 12:33:59 am
Alex, THe ez debug output displays some of this right now, albeit its often not what the error is referring to. Are you speaking about inline errors, errors that display with the html? That would be useful. paul
-- http://www.visionwt.com
|
Alex Jones
|
Thursday 13 May 2004 5:52:14 am
Actually, I'm not speaking about errors at all. ;) What I would like is the equivalent of viewing the source of a Web page - but for eZ code. Ultimately, this view would display every line of code that eZ publish would convert before sending the results to the browser. My goal is to see which tags (eZ & HTML) are opened and closed, and for that matter where they are opened and closed. Right now, to get this perspective I would have to open many different template files and piece them together mentally. This isn't a big deal, but I think it would prove helpful. Does this make sense? Alex
Alex
[ bald_technologist on the IRC channel (irc.freenode.net): #eZpublish ]
<i>When in doubt, clear the cache.</i>
|
Paul Forsyth
|
Friday 14 May 2004 12:41:02 am
That could be easy to do. All we really need is another log file, which could be entered to if a setting is active, and displayed on screen if another setting is active. I think PHP can capture output quite easily. Though we really need to colour the resulting code according to some syntax checker to help with problem areas. paul
-- http://www.visionwt.com
|
Alex Jones
|
Friday 14 May 2004 6:21:46 am
Color-coding would be a great addition. I still need to find a way to do that in DreamWeaver. Alex
Alex
[ bald_technologist on the IRC channel (irc.freenode.net): #eZpublish ]
<i>When in doubt, clear the cache.</i>
|