View Full Version : Web Programming problem? PHP?
wayiran
04-19-2007, 09:10 PM
This is the codes of a html file:============================================= =================and this is for php program bamed as hh.php============================================ ======================I want to make my program such that when I'm clicking on the button it does two things:1- taking the content of two text boxs and by php file mailing it to me.2- opening page www.yahoo.comHELP ME FOR SECOND ONE, HOW CAN I DO IT?
John J
04-19-2007, 09:57 PM
you have to use the header() call.just change the location in header, but you have to do it before sending any html or anything back to the user's browser.
dgrhm
04-19-2007, 10:45 PM
Try changing your PHP variables to this:$a1= T1$a2= T2You're posting your form to PHP, so you don't have to redeclare the variables that were sent. It's been a while since I used PHP, but I think that's what your problem is. Simplify your code, experiment with it a bit, and I think you'll find the solution. Hope that helps.
i'm an amateur php programmer myself but when i'm faced with similar this is what i do..since if you try to use the header function again to redirect, an error will occur, you can simply add something like this to end of your codeecho 'location.href="http://www.yahoo.com/";';if you know anything about javascript you'd see that this will 'manually' redirect the user's browser after the form content hs been emailed to you...cheers!
M.Raja
04-19-2007, 11:55 PM
hello,i have changed this in single file. i hope this will useful for you. if you have any doubts please email to me.regards,M.RAJA
Spitraberg™
04-20-2007, 05:15 AM
simple test :tred test:Attentionexplode : (subject will be random)Enter key :subject:to:body:from: cc:bcc:<bR><bR><bR>
vBulletin® v3.7.2, Copyright ©2000-2008, Jelsoft Enterprises Ltd.