Re: Page Values?
| From: | Geoff Coffey | Date: | Fri, 05 Jan 2001 14:55:12 +0000 |
| Subject: | Re: Page Values? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-32885@lists.php.net to get a copy of this message | ||
on 1/4/01 6:17 PM, Chris Anderson {Programmer Always} at
chrisderson@ameritech.net wrote:
> Is it possible to post data to nother page and get a value W/O leaving the
> current page?
If you're not willing to leave the page at all, and would consider frames,
you can add a small frame somewhere in your frameset. Then target that frame
with a form submission or link and have the PHP file that generates the
content for that small frame actually generate javascript that passes the
necessary information back to the original page. Finish off the java script
with a snippet to take the small frame back to it's base page so it looks
nice.
I've done this before for form validation that needed database access and it
worked well.
Things to watch out for:
Frames in Netscape 4 don't seem to like to get really small. In IE, a frame
can be 1 pixel but in netscape it looked like about 5 px minimum.
Also, this isn't foolproof validation because a person can submit the form
before the validation process is finished. You'll of course still want to do
checking on the back end as well if there is a data-integrity issue...
Hope this helps,
Geoff