<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><br><div><div>Am 02.07.2008 um 20:56 schrieb [vEX]:</div><blockquote type="cite"><div><font class="Apple-style-span" color="#000000"><br></font></div><div><br></div></blockquote><div><br></div>[...]<br><blockquote type="cite"><div>[...]<br><blockquote type="cite"><br></blockquote><blockquote type="cite">An alternative approach would be to just add a select subset of HTML to <br></blockquote><blockquote type="cite">the DTD, no? Or even import that HTML DTD... BBCode might be easy to <br></blockquote><blockquote type="cite">use, but HTML is so, too....<br></blockquote><br>Well the problem is that the XML parser functions I use are non-validated. That <br>simple XML parser simple doesn't give a damn about DTDs. But that's the only <br>XML-parser provided in vanilla PHP4 to my knowledge. However, in PHP5 there is a <br>SimpleXML parser that would work even better. Even though it's non-validating it <br>shouldn't have any problems since I could ask for all the contents of any tag.</div></blockquote><div><br></div><div>Well, seems we need to stay with PHP4 compatibility, though. Anyway, validation is certainly not required. If you need to distinguish between the NEWS structure XML, and the "content" XHTML, the easiest way is to use XML namespaces. Or just limit the structure of the XML enough. </div><div><br></div><div><br></div></div><div><blockquote type="cite"><div><br><br>It would however also mean that there wouldn't be a complete separation of data <br>and presentation. That's something you should decide on however, perhaps making <br>it completely separated is taking it to an extreme for the ScummVM website?</div></blockquote><div><br></div><div><br></div><div>I think that it's fine to use (X)HTML to format news items -- going to BBCode does not separate data and presentation, it just adds an extra layer. Or why would [b]foo[/b] be more "separated" than <b>foo</b> ? :)</div><div><br></div><div><br></div><div>[...]</div><div><br></div><blockquote type="cite"><div><blockquote type="cite">This has mostly historical reasons, I'd say. This code and the system <br></blockquote><blockquote type="cite">certainly could be improved a lot. Also note: You do not have to be <br></blockquote><blockquote type="cite">pixel-level compatible here. And one could use a 3rd party gallery tool <br></blockquote><blockquote type="cite">for some of this, e.g. SPGM <<a href="http://spgm.sourceforge.net/">http://spgm.sourceforge.net/</a>>, or something <br></blockquote><blockquote type="cite">else.<br></blockquote><br>Oh, I didn't aim for pixel-perfect, I already have some small things different <br>;-). I could write something up that means you only need to dump the images in a <br>directory and it will pick them up. It's just a question about specifiying how <br>and where the related information should be stored (in the filename? in a small <br>text file?).</div></blockquote><div><br></div><div>If we are talking about the screenshots here, then I would recommend using a small text file (XML or CSV), either one containing all images, or one per image. Using filenames is not flexible enough.<span class="Apple-tab-span" style="white-space:pre"> </span></div><div><br></div><div>[...]</div><div><br></div><blockquote type="cite"><div><blockquote type="cite">I am not sure what you mean with "it would pick up all the docbook tags <br></blockquote><blockquote type="cite">as XML-tags" -- we are using DocBook XML, so those "tags" (actually, the <br></blockquote><blockquote type="cite">correct term is "elements", to be nitpicky ;-) *are* XML-elements... So <br></blockquote><blockquote type="cite">again, I don't see the problem?<br></blockquote><br>I was thinking about how I build the "tree" (multidimensionl array) from the XML <br>using the simple XML parser in PHP4 discussed above. It makes it difficult to <br>mix XML/HTML since it doesn't know anything about DTDs. It just sees the start <br>and ending tags and happily perceives it as an XML-element that should be parsed.</div></blockquote><div><br></div><div>Once again, XHTML is just a variant of XML :). But I assume you mean you want to distinguish non-XHTML elements from other elements. Well, that's what XML namespaces are for, right? Or does the PHP4 XML not support these? In that case, we could just as well specify a list of XHTML elements allowed in the NEWS (we'd get such a restriction if we used BBCode, too).</div><div><br></div><div>IMO, it makes no sense to add the extra layer of BBCode, when we already use an XML parser. Why use two parsers for two different but similar formats, if you can do it all with one format, and elegantly, too ?</div><div><br></div>[...]<br><blockquote type="cite"><div><br></div></blockquote><blockquote type="cite"><div>Come to think off it, it would really be nice if I knew what kind of PHP support <br> SF.net has. Not just the PHP version, but also what extensions are enabled and <br>what versions. So a small request from me would be to get that information. <br>Putting "<?php phpinfo(); ?>" in a file ending in .php and running it would do, <br> it could even be run from a console (assuming SSH-access and CLI-support <br>compiled in).<br></div></blockquote></div><br><div>See <<a href="http://www.scummvm.org/test.php">http://www.scummvm.org/test.php</a>>.</div><div><br></div><div>Overall I heard no critical comments about your plans. From my point of view, we could go ahead with this project. Eugene seems to agree as well. He'll mail in a moment, too :)</div><div><br></div><div>Cheers,</div><div>Max</div></body></html>