PDA

View Full Version : Opening new window on form submit


ToastyCheesy
08-10-2008, 10:59 AM
I may not be able to get this out right... it's getting pretty late.

I am setting up a php script that allows me to add polls to a site. when this poll "submits a vote" it refreshes the whole page. Now, for one reason or another, I cannot have this page refreshing just by a poll vote. I'm trying to figure out where, when I click the submit button, it would pop open the results in a new window, that can then be easily closed after viewing. I'll share some code below:




Well, I'm certain tomorrow morning or in the next few days, I'll remember it was something simple, and then we can all laugh on it in the end.


EDIT: If you read the post before I edited it, I decided to change my idea. I'm now having the poll on a seperate popout page, but i still can't figure out what code I am suppose to use. Thanks.

Shadow
08-11-2008, 01:21 AM
hm.. I don't see the problem. If it is within a popup then you can decide there if the popup should be reloaded with the results or if they should be shown on the main page.

As a hint: you can inject the updated code for the results per javascript into a <DIV> Tag on the mainpage.

ToastyCheesy
08-12-2008, 06:45 AM
I have it figured out now. I wasn't including the function with my javascript code:
<SCRIPT LANGUAGE="JavaScript">
<!-- Begin
function WindowPop(URL) {
day = new Date();
id = day.getTime();
eval("page" + id + " = window.open(URL, '" + id + "', 'toolbar=0,scrollbars=0,location=0,statusbar=0,men ubar=0,resizable=1,width=200,height=400');");
}
// End -->
</script>
and then for the window link:
<A HREF="javascript:WindowPop('./poll.php')">

It all works well, my original thoughts were to add this somewhere:
target="_blank"

However that didn't work, which left me confused, and mostly just tired.

Shadow
08-12-2008, 05:43 PM
Congratulations! :) I was a little bit confused, but in fact it seems to be just a simple thing.

firewolf20
08-15-2008, 08:39 AM
Next up in shemale-land… Big breasted latina Tabatta Cardoso walked into the studio wearing this insanely skimpy, extra whorish stripper outfit, some real short daisey dukes and a grin that told the crew, the fucking begins now.The moment our 18 Year Old Trannies laid eyes on the anal toys, large dildos and stuff we had for her little tgirl ass, she was on point. This little Shemale Gulpers proceeded to get naked, and start inserting and trying every dildo, sex toy and dong she could get her ass on. In fact, our horny tranny wouldn’t stop inserting the props, not that we minded, I mean Pee on Shemales, we LOVE to see horny tgirls doing hardcore shit, sticking things in their Pee on Shemales asses. Ah, the good things in life.Make your life more complete by watching transexual Tabatta and all her fucking naughty Shemale Jobs friends engaged in bizarre insertions and all kids of extreme hardcore shemale action at Ass Toyed Shemales.

Mod's note: haha.... oh wow

(USER WAS BANNED FOR THIS POST)