Linera Posted November 26, 2006 Share Posted November 26, 2006 I saw on http://forums.worldofwarcraft.com that the forums are built in html and not in php.How do you build a forums like this?please help me out.Thank you. Link to comment Share on other sites More sharing options...
smiles Posted November 27, 2006 Share Posted November 27, 2006 that because you cant see php code in view source , it had been done by server , a compute center far away from you , what you see is done by browser , just HTML or Script ... Link to comment Share on other sites More sharing options...
Linera Posted November 27, 2006 Author Share Posted November 27, 2006 its not using php though.or you would see in the address bar http://forums.worldofwarcraft.com/forum.php or http://forums.worldofwarcraft.com/board.phporhttp://forums.worldofwarcraft.com/topic.php Link to comment Share on other sites More sharing options...
Jonas Posted November 27, 2006 Share Posted November 27, 2006 Most likely it's using PHP, but it can also be another serverside technology. It's possible to configure your server you see, so it for example parses .html files for php, which is likely to be what they have done. Link to comment Share on other sites More sharing options...
Linera Posted November 27, 2006 Author Share Posted November 27, 2006 I notice it has javascript files in the coding. Link to comment Share on other sites More sharing options...
boen_robot Posted November 27, 2006 Share Posted November 27, 2006 I notice it has javascript files in the coding.So? A server side scripting language is still the thing to work with the database (please oh please, just don't ask what's a database). Link to comment Share on other sites More sharing options...
real_illusions Posted November 27, 2006 Share Posted November 27, 2006 So? A server side scripting language is still the thing to work with the database (please oh please, just don't ask what's a database).whats a database??only joking Link to comment Share on other sites More sharing options...
jlhaslip Posted November 27, 2006 Share Posted November 27, 2006 I saw that one coming from a mile away Link to comment Share on other sites More sharing options...
Linera Posted November 27, 2006 Author Share Posted November 27, 2006 So how can I do this style forums on my site? Link to comment Share on other sites More sharing options...
justsomeguy Posted November 27, 2006 Share Posted November 27, 2006 Set up your server to send HTML files to the PHP engine. Link to comment Share on other sites More sharing options...
Jonas Posted November 27, 2006 Share Posted November 27, 2006 Find the .htaccess file, and add this in there:AddType application/x-httpd-php .html Link to comment Share on other sites More sharing options...
Linera Posted November 28, 2006 Author Share Posted November 28, 2006 which means i'll be able to use php coding in html files? Link to comment Share on other sites More sharing options...
Jonas Posted November 28, 2006 Share Posted November 28, 2006 Yup, that should work. Granted php is installed on your server of course. Link to comment Share on other sites More sharing options...
Linera Posted November 28, 2006 Author Share Posted November 28, 2006 i know its installed as i have a php forums installedI was looking into making a better forumsthanks for your help. Link to comment Share on other sites More sharing options...
reportingsjr Posted November 28, 2006 Share Posted November 28, 2006 I have a question regarding .htaccess, I tried to edit mine so php could be parsed through .html. But instead it just forced a download. What did I do wrong! I had it like you posted Jonas but with more such as .php and .htm. It would be nice to figure it out. Link to comment Share on other sites More sharing options...
Jonas Posted November 28, 2006 Share Posted November 28, 2006 http://www.wsabstract.com/howto/htaccess9.shtmlWhat if your server wasn't set up to deliver certain file types properly? A common occurrence with MP3 or even SWF files. Simple enough to fix: AddType application/x-shockwave-flash swfAddType application/x-shockwave-flash swf tells the server to send files with swf extension with the MIME type application/x-shockwave-flash. Similarly, writing AddType application/x-httpd-php .html should tell the server to send files with html extension as PHP files, and so be sent to the PHP parser. It's possible though that it should be x-httpd-php html without the . (dot) infront of html. When I first googled (yes, it's that simple) for ".htaccess" and "parsing html files for php", I found an example with the dot in front of html: http://www.bigbold.com/snippets/posts/show/459Apologies. Link to comment Share on other sites More sharing options...
Linera Posted November 28, 2006 Author Share Posted November 28, 2006 It works greathttp://www.souimappers.post2hostit.com/phptest/make sure you copy the line below and place it at the end of the document below the last line.AddType application/x-httpd-php .html Link to comment Share on other sites More sharing options...
Linera Posted December 5, 2006 Author Share Posted December 5, 2006 How would I parse xml in a html file? Link to comment Share on other sites More sharing options...
justsomeguy Posted December 5, 2006 Share Posted December 5, 2006 If you are talking about code inside of an HTML file to parse XML, HTML can't do anything dynamic. It is purely a formatting language. You could probably do it in Javascript, or else you would need to use a server-side language with some more power. Link to comment Share on other sites More sharing options...
Linera Posted December 5, 2006 Author Share Posted December 5, 2006 look in previous posts. i was shown how to get html to parse php Link to comment Share on other sites More sharing options...
justsomeguy Posted December 5, 2006 Share Posted December 5, 2006 OK, then you're talking about a PHP document, not an HTML document. Regardless of the file extension, if it gets sent to the PHP engine then it is a PHP document.Here is the XML reference on php.net:http://www.php.net/manual/en/ref.xml.phpOr if you have PHP 5.1, then you can use this instead:http://www.php.net/manual/en/ref.xmlreader.php Link to comment Share on other sites More sharing options...
boen_robot Posted December 6, 2006 Share Posted December 6, 2006 I would advise more for the DOM functions. Some of them have already done wonders for me and I haven't explored and mastered them all yet.Another way you may use to... parse... XML documents is XSLT. You may execute XSLT transformation with PHP by the use of PHP's XSL(T) functions and by doing so, the user agent will get the result code of the transformation.btw as justsomeguy already mentioned, what determines the type of a document is how it is parsed, not what it's file extension is (just wanted to paraprase him). Link to comment Share on other sites More sharing options...
Linera Posted December 7, 2006 Author Share Posted December 7, 2006 listen, i was shown how to have a html file get sent through the php parser.Now I want to know how to get html file to get sent through the xml parser. Link to comment Share on other sites More sharing options...
justsomeguy Posted December 7, 2006 Share Posted December 7, 2006 Through which XML parser? To my knowledge, there is not a server-side XML parser unless you build one programmatically, such as with PHP. If you want the browser to parse the file as an XML file, which IE cannot do, then you will need to have the server send the mime type of the file as either application/xml or application/xhtml+xml.What XML are you trying to parse, what is the goal of using an XML parser? Link to comment Share on other sites More sharing options...
Linera Posted December 7, 2006 Author Share Posted December 7, 2006 I want to put xml coding into a html file just like i can put php coding into a html file 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