Jump to content

window.open ??


chiprivers

Recommended Posts

Im having trouble with a little bit of javascript if anybody could help, I don't really use it that often so I am probably making a really simple mistake!

 

This is my script:

 

<?php
echo "<script language =\"JavaScript\">\n";
echo "document.body.style.backgroundColor=\"yellow\";\n";
$target = "data_grabber.php?sentDate=".date("Y-m-d",$date_plus_one);
$window = date("Y-m-d",$date_plus_one);
echo "window.open('".$target."','".$window."');\n";
echo "</script>";
?>

 

This is at the very end of my script and it is supposed to turn the page yellow (which it does) and then open up a new window, but it doesnt open the new window!

Link to comment
https://forums.phpfreaks.com/topic/44041-windowopen/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.