dosdoctor Posted July 9, 2007 Share Posted July 9, 2007 Hi. I am a newbie to php and am working on an online form. The form is named contactForm.php I was told that the filename has to have the .php extension to work. Problem is, when I link to the file from an .html page, the browser wants to download the file. I thought I found a solution, but it only works in Firefox. This solution is one I found in a php forum. The solution was instead of linking to the .php file, to link to a file named contactForm.html which had this content: <html> <!--Redirect form to .php form processing--> <body> <meta http-equiv='refresh' content='0;url=contactForm.php /> </body> </html> I'm not sure why it works, but in Firefox it works beautifully. The form opened, re-posted to itself, validated, and processed. But NOW...I tried it in Internet Explorer and all I get is a text message: <meta http-equiv='refresh' content='0;url=contactForm.php /> Can anyone tell me how to make this .php file open/run in both browsers? Any help is greatly appreciated. Thank you. Quote Link to comment Share on other sites More sharing options...
ToonMariner Posted July 9, 2007 Share Posted July 9, 2007 if your file is named.php and the server is configured correctly this should not be happening. test your server by placing a file up with just <?php phpinfo(); ?> in it and put the pages address in the address bar. If the server has php enabled for your site then it spit out the installation details - if not then get your server dudes to sort it... Quote Link to comment Share on other sites More sharing options...
dosdoctor Posted July 9, 2007 Author Share Posted July 9, 2007 Thank you. I'll try that. But I did find the answer... I had to add the following tag in the <head> section: <link rel="alternate" type="text/css" href="contactForm.php" /> Now I can link the the contactForm.php as usual. Thanks for your help. 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.