problem with adding url variable with javascript

Posted by Richard on Stack Overflow See other posts from Stack Overflow or by Richard
Published on 2010-03-12T03:36:08Z Indexed on 2010/03/12 3:37 UTC
Read the original article Hit count: 406

Filed under:
|
|
|
|

Hello, Can someone help me with this

I am trying to set and catch the url variable

It begins with a form wich has the standard action set to "/autorisation/logout" Then a button with an inline javascript function

function tbPayout()
{
parent.location = "/autorisation/logout?rcgo=payout";
return true;

} 
<input src="/images/go02.gif" type=image border=0 name="go1" onClick="return tbPayout();">

In the autorisation controller I try to catch it

if ( isset($_GET['rcgo']) ) {

but it doesn't work and I can't see the variable in the url and therefore the default forms action is performed?

I also have another redirect page with

content="3; url=http://www.domain.nl/index/index?rcgo=logout" />

and that works fine

How can I get the javascript to work because I have three submit buttons that need to be set to different get variables.

Thanks, Richard

© Stack Overflow or respective owner

Related posts about JavaScript

Related posts about php