newLISP wiki: format-line

Started by rickyboy, June 20, 2007, 05:48:02 PM

Previous topic - Next topic

rickyboy

I think this is a Lutz question: why does index.cgi in newLISP-wiki expand the template line by line?  In this way, it can't handle tags which are written over multiple lines (but browsers can):

<img src="Really-long-image-resource-name-that-goes-on-and-on"
     height="100" width="150" border="1"/>

I know there must be a reason, e.g. to handle very large line-delimited text.  Curious if we should change the template expansion processing or not.  Thanks!  --Rick
(λx. x x) (λx. x x)

Lutz

#1
I was trying to keep things safe and simpler to debug for the one who is using the tags for formatting. The line limitation effectively restarts the regex process everytime, limiting formatting problems/bugs to a smaller space and easier to deal with.



But I agree that the tagging area could benefit from an overhaul. I just don't have the time and the way it works currently is sufficient for me to run newlisp.org.



Lutz

rickyboy

#2
I'd love to take a shot at some changes.  If you are game, how do you want to proceed?  As a suggestion I could take off with a bunch of changes in a fork off the current wiki then show it, or I could give you incremental changes, one at a time, for your approval/submittal.  If you are not game, I could just fool with my own version and not bother you.  Either case is OK with me.  Thanks!  --Rick



P.S. -- We could easily change the template processing to do BOTH line-by-line and whole-template expansion.  We could then add a switch to have it do one or the other -- the default could be line-by-line, and folks like me can turn on whole-templates.
(λx. x x) (λx. x x)

Lutz

#3
Just fork it, make changes to your taste and make the new version available, so others can benefit from it too. Of course it would be great if the new script can still read and present old pages. Then people just drop in a new index.cgi and are ready to go. Almost everybody changes template.html to their needs already.



Lutz