Seeking thoughts of HTML users

stormbind

Retenta personam!
Joined
Feb 1, 2003
Messages
14,081
Location
London
Hello everyone! :)

I am thinking of doing some more work on Guestaphics. A very buggy demo of the proof of concept is in my signature.

Developers

This uses PERL which I know upsets people but I have a reason: The skill sets of server-side programmers and client-side programmers (which applies to maintenance programers aswell) are completely different and to prevent them stepping on each other's toes, their respective sourcecode would ideally be completely seperate from each other.

In it's very concept, PHP merges the all the code. PHP works very well for small projects but increases the danger of spaghetti-code in large projects. It also presents difficulty for webmasters.

Guestaphics is a small project, but I would like to treat it like a large project so I can practice SDLC :p


HTML users & developers

I would like your input on how to construct an ideal template: the sort of thing you might edit to intergrate a product into your website.

This is a poor example. Please give feedback and post suggestions for how your ideal template solution. My idea is based on the concept of SSI, where the server parses the template and replaces <!--#SSI --> commands with data generated by the server-side script.

HTML:
<!DOCTYPE>
<HTML>
<HEAD>
	<TITLE><!--# $title --></TITLE>
	<SCRIPT LANGUAGE="javascript" src="gui.js"></SCRIPT>
	<SCRIPT LANGUAGE="javascript" src="zoom.js"></SCRIPT>
	<SCRIPT LANGUAGE="javascript" src="wysiwyg.js"></SCRIPT>
</HEAD>

<BODY>
	<DIV ID="header">
		<IMG ID="banner" SRC="" />
		<!--# $timestamp -->
	</DIV>

	<DIV ID="guestbook">
		<!--# $tab_data -->
	</DIV>

	<DIV ID="form">
		<FORM NAME="new_entry">
			<INPUT TYPE="text">
			<INPUT TYPE="submit">
		</FORM>
	</DIV>

	<DIV ID="footer" ALIGN="CENTER"><!--# $copyright --></DIV>

</BODY>
</HTML>
 
I'd show you the script I'm writing to turn XML into a DHTML page of my liking, but it is pure spaghetti. I'd rather spare your life ;)

Have to say I know too little about server-side scripting to give you any hints there. If anything, I'd have to say that a template like that would not be scaleable enough. I'd recomend having two processes involved: 1) A script to look at the data and generate a template that the data will fit in, then 2) fill in the <!--# $foo --> with that data.
 
Not 100% sure I follow. The idea is that HTML users can edit the layout & design (or even be selective about what they include) without touching the server-side script.

If the server generates the template, then how do HTML users edit that template? Maybe I misunderstood though - it would not be the first time ;)

Or maybe this is what you meant: Webmasters might want to change the order that tabular data is displayed in, and they might want to be selective about which columns are displayed.

This requires an ability to instruct the perl script with a loop (which I want to avoid), by providing it with an example of the desired layout (such as the SSI config idea).

HTML:
<!--#config each_row="<tr><td> $flag </td><td> $name </td><td> $post </td></tr>" -->

<!--
other options might be $date, $dob, $email, &c.
-->

<table>
  <!--# $tab_data -->
</table>
 
Back
Top Bottom