paul Posted June 26, 2003 Report Share Posted June 26, 2003 I'm working on a xml/xsl/dtd/css site which so far works and renders perfectly with mozilla 1.1+/IE 5.5+ what I want is for it to work with opera and other browsers as well. the only way I can think of is to preprocess the resulting code (which seems like a waste .. since xml/xsl is designed to remove the server side pre processing) What I thought is that I could do something like this <javascript> if(is_opera()) location.href('preprocess?thispage.xml) </javascript> I believe this is called an xml transformation engine ??? does that sound right? so has anybody seen anything that does this? Quote Link to comment Share on other sites More sharing options...
aru Posted June 26, 2003 Report Share Posted June 26, 2003 apropos is your friend ;) ~$ apropos xml | egrep "preprocess|parse|html" libxml (4) - library used to parse XML files xmllint (1) - parse XML files and print the result of parsing ~$ If you look at the xmllint man page you'll see an option to output the result in html (--htmlout). I'm not sure that that is what you are looking for because I'm not sure if it will work the way you want (I've never played with xmllint) Quote Link to comment Share on other sites More sharing options...
paul Posted June 29, 2003 Author Report Share Posted June 29, 2003 8) got it !!!! ... the problem with Opera .. is it doesn't render xsl at all so after 3 days of searching ... it was right infront of me :roll: [paul@morpheus xml_trial]$ rpm -qa | grep xsl php-xslt-4.2.3-1mdk libxslt-proc-1.0.19-4mdk libxslt1-1.0.19-4mdk [paul@morpheus xml_trial]$ so now I have to do some thing like this <?php if(!$_GET ) { $page = "index.xml"; } if(eregi("opera",$_SERVER['HTTP_USER_AGENT'])) { system("xsltproc xml/layout.xsl ./".$page); } else { header("Location: ./$page"); } ?> Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.