B
build
G'day All,
I hope you folk are tolerant of newbies who don't express themselves
well, cause I'm one of those. If not please excuse this and move on.
I'm designing a small web site and while I thought I'd done a good job
of planning the project and learning the required skills I've now
discovered a hole in my plan.
I'm using a template like php script to the build pages.
I'm also using php sessions to authenticate access to members and
guests.
The content component is in xhtml.
Now I'm at the testing stage, I've started to prepare a few of the
xhtml files and realised a lot of the content is an amalgum of 'guest'
and 'member' stuff. I don't really want to have a separate page for
each class of user, with largly identical content.
I've read all the W3C tutorials on XML, XSLT, etc. I'm quite excited
about the possible uses of XML applied to my current problem and a
myriad of other applications (such a simple idea, but so bloody
useful). However my mind is currently a potpourri of half baked ideas.
I'm failing to get a proper grasp on exactly how to utilise xml.
I'm wondering if I could modify the xhtml files to xml and use tags to
decide what to display?
i.e. the stuff enclosed by the <member> tag should only be written to a
member session.
<h1>My Page</h1>
<p><em>16/03/2005</em><br />
Sorry, we were offline for a few hours this morning, someone tripped
over the extension lead.
</p>
<member>
<p>
<strong><em>03/03/2005</em>
<br />
Barton Mawer WINS at the Australian Grand Prix (<a
href="lindsay/bartonmawer.htm" target="main">more</a>).</strong>
</p>
</member>
My questions are:
1) Am I on the right track? Is XML the answer to my problem?
2) Is there an easy way of separating the content without having to
parse all the xhtml tags as well as the xml tags???
3) If so, I need to get a better understanding of XML, what is your
suggested next step after reading the W3C tutorial?
If this is an inappropriate place for this post could some kind soul
please point me in the right direction?
apologies in advance as I realise I have not phrased the question well
(cringe), your tolerance would be greatly appreciated.
Thanking you in anticipation,
build
I hope you folk are tolerant of newbies who don't express themselves
well, cause I'm one of those. If not please excuse this and move on.
I'm designing a small web site and while I thought I'd done a good job
of planning the project and learning the required skills I've now
discovered a hole in my plan.
I'm using a template like php script to the build pages.
I'm also using php sessions to authenticate access to members and
guests.
The content component is in xhtml.
Now I'm at the testing stage, I've started to prepare a few of the
xhtml files and realised a lot of the content is an amalgum of 'guest'
and 'member' stuff. I don't really want to have a separate page for
each class of user, with largly identical content.
I've read all the W3C tutorials on XML, XSLT, etc. I'm quite excited
about the possible uses of XML applied to my current problem and a
myriad of other applications (such a simple idea, but so bloody
useful). However my mind is currently a potpourri of half baked ideas.
I'm failing to get a proper grasp on exactly how to utilise xml.
I'm wondering if I could modify the xhtml files to xml and use tags to
decide what to display?
i.e. the stuff enclosed by the <member> tag should only be written to a
member session.
<h1>My Page</h1>
<p><em>16/03/2005</em><br />
Sorry, we were offline for a few hours this morning, someone tripped
over the extension lead.
</p>
<member>
<p>
<strong><em>03/03/2005</em>
<br />
Barton Mawer WINS at the Australian Grand Prix (<a
href="lindsay/bartonmawer.htm" target="main">more</a>).</strong>
</p>
</member>
My questions are:
1) Am I on the right track? Is XML the answer to my problem?
2) Is there an easy way of separating the content without having to
parse all the xhtml tags as well as the xml tags???
3) If so, I need to get a better understanding of XML, what is your
suggested next step after reading the W3C tutorial?
If this is an inappropriate place for this post could some kind soul
please point me in the right direction?
apologies in advance as I realise I have not phrased the question well
(cringe), your tolerance would be greatly appreciated.
Thanking you in anticipation,
build