FamilyGuy Posted May 11, 2006 Share Posted May 11, 2006 (edited) I have created a XML file, <?xml version="1.0"?><CW><Problem><Row id="1"><Letter>M</letter></Row><Row id="2"><Letter>M</letter></Row><Row id="3"><Letter>M</letter></Row><Row id="4"><Letter>M</letter></Row></Problem><Solution><Row id="1"><Letter>M</letter></Row><Row id="2"><Letter>M</letter></Row><Row id="3"><Letter>M</letter></Row><Row id="4"><Letter>M</letter></Row></Solution></CW> but when i create the DTD file will i have to define Letter and Row twice as they appear both in the Problem and in the Solution?Also i i have display the data on 2 different pages a problem and a solution page in a table can anybody give me any guidence on how to each letter into a different cel of a table?Any Advice would be greatly appreciated Edited May 11, 2006 by aspnetguy Link to comment Share on other sites More sharing options...
dooberry Posted May 11, 2006 Share Posted May 11, 2006 You might want to look at the posts about the Sudoku puzzle that is being worked on (search on Little Goat's posts). This should allow you to plan the crossword better because you will be able to plot a grid using the SML:Grid namespace. Link to comment Share on other sites More sharing options...
FamilyGuy Posted May 11, 2006 Author Share Posted May 11, 2006 Would you or anybody be able to give any guidence of how to do this I have had a look at the sudoku problem but I do not understand how to create a seperae number in each cell Link to comment Share on other sites More sharing options...
Little Goat Posted May 15, 2006 Share Posted May 15, 2006 You might want to look at the posts about the Sudoku puzzle that is being worked on (search on Little Goat's posts). <{POST_SNAPBACK}> search for me? anyway, FamilyGuy, as far as I know, (and with DTDs that is not very much) you would have to define them twice.maybe I don't quite understand your problem though.LG Link to comment Share on other sites More sharing options...
dooberry Posted May 17, 2006 Share Posted May 17, 2006 Err, just re-checking your initial post, you could make solution a child element of row: <Row><id>1</id><Problem> <Letter>M</Letter></Problem<Solution> <Letter>M</Letter></Solution></Row>... Then have 2 XSL sheets, one which does this: <table><xsl:for-each select="Row"><td> <xsl:value-of select="Problem/Letter" /></td></xsl:for-each></table> And another which does this: <table><xsl:for-each select="Row"><td> <xsl:value-of select="Solution/Letter" /></td></xsl:for-each></table> that's what I would do because I have absolutely no idea about DTD.There may be other people out there who can help with this a bit more and give you what you need to put this into DTD, but hopefully what I've given you here is a little insight as to how it could be done.Sorry if this was no help at all!! Dooberry. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now