Closed Thread Icon

Topic awaiting preservation: Parameters from javascript gotten incorrectly (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=30331" title="Pages that link to Topic awaiting preservation: Parameters from javascript gotten incorrectly (Page 1 of 1)" rel="nofollow" >Topic awaiting preservation: Parameters from javascript gotten incorrectly <span class="small">(Page 1 of 1)</span>\

 
ruffy
Obsessive-Compulsive (I) Inmate

From:
Insane since: Jun 2008

posted posted 06-15-2008 23:37

I want to pass from javascript to a new php page some parameters.
A viable solution seems to be:
location.href="stats.php?totsales=results[0]&totinvoices=resultsnt";

Only my stats.php file,
which uses
$value1 = $_GET["totsales"];
etc.
is not receiving the values correctly.

Would appreciate your diagnosis.

poi
Paranoid (IV) Inmate

From: Norway
Insane since: Jun 2002

posted posted 06-15-2008 23:42

Certainly, what you want is something like : location.href="stats.php?totsales="+encodeURI(results[0])+"&totinvoices=results";

« BackwardsOnwards »

Show Forum Drop Down Menu