Hacer referencia a una determinada sección de un guión

I am sending out a request to a site, which needs a returning URL. Once that returning URL is put in, I'd like to run this particular section of my code.

¿Cómo hago esto?

I have tried the return URL as :



if($_GET['auth'] == 'true') {
 Do Something

But the previous page appears to load.

¿Hay alguna otra forma de hacerlo?

preguntado el 08 de noviembre de 11 a las 14:11

"No joy with it" isn't an error. What happens when you request the page that piece of code is on? Oh and don't do this, every user who can read an address bar can set the auth flag to true. -

Does it always execute the code inside the if clause, or does it never execute it? Not sure, but try replacing the == por una ===. -

@CodeCaster how would you propose I pass the params? -

I don't know what you're doing with $_GET['auth'], so I can't tell. -

1 Respuestas

You've got syntax error on the first line

Debería ser

if($_GET['auth'] == 'true') {

but yes, this is correct way to do it

respondido 08 nov., 11:18

No es la respuesta que estás buscando? Examinar otras preguntas etiquetadas or haz tu propia pregunta.