RSS Forums RSS
Please support our HTML and CSS advertiser: Lunarpages Web Hosting

Showing results of a form in new window

Join Date: Feb 2002
Location: Long Island, NY
Posts: 1,134
Reputation: samaru is just really nice samaru is just really nice samaru is just really nice samaru is just really nice 
Rep Power: 12
Solved Threads: 4
Colleague
samaru's Avatar
samaru samaru is offline Offline
a.k.a inscissor

Re: Showing results of a form in new window

  #3  
Jan 7th, 2004
Welcome to TTF!

The easiest way is to submit the form to target="_blank" - here's some sample code in HTML/PHP. The PHP code is just so the form doesn't get displayed:

[PHP]<?
if(isset($_POST['something'])) {
echo $_POST['something'];
}
else {
echo '
<form action="'.$_POST['SCRIPT_NAME'].'" method="post" target="_blank" >
Input Something: <input type="text" name="something">
<input type="submit" value="Submit">
</form>';
}
?> [/PHP]

Any questions, just ask.
_.:: my websites ::._
blog @ www.samaru.net * engi No Jutsu @ www.narutorp.net * portfolio @ shinylight.com
deviantART: inscissor
Reply With Quote  
Forums | Blogs | Tutorials | Code Snippets | Whitepapers | RSS Feeds | Advertising
All times are GMT -4. The time now is 10:31 am.
Newsletter Archive - Sitemap - Privacy Statement - Acceptable Use Policy - Contact Us
Forum system based on vBulletin Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
©2003 - 2008 DaniWeb® LLC