Javascript/PHP Help

Caporegime
Joined
18 Oct 2002
Posts
25,289
Location
Lake District
I'm trying to parse a variable when clicking a checkbox on a page, I'm trying to do it using this code but it isn't working.
Code:
function returns(filename) {
	var x = new Image(1,1);
	x.src='http://database/othering/returns.php?filename='+filename+'&x='+new Date().valueOf();
	return false;
}
Can anyone advise?
 
Caporegime
Joined
18 Oct 2002
Posts
29,491
Location
Back in East London
Not sure if this is the best way to go about this.. it just seems.. wrong.

Have you tried AJAX?

Anyway, try:
Code:
function returns (filename) {
    var x = new Image(1,1);
    var d = new Date();

    x.src = 'http://database/othering/returns.php?filename='+filename+'&x='+d.valueOf();
    return false;
}
 
Back
Top Bottom