Page 1 of 1

Creating a menu link - can you have it pass a PHP command?

Posted: 20 Aug 2009, 08:44
by Verovi
Hi,

I am using imaguevuex2 for a design portfolio / cv site as such I have put a custom password protection on the index.php page - this is all working fine, however i would like to give my viewers a chance to log out.

When you create a folder / mod it to be a link it gives HTML options only.
Is there a way to wrap a php call?

i.e.

<A HREF="<? echo $PHP_SELF ?>?action=logout">Log out</A>

Thanks!

Posted: 20 Aug 2009, 09:07
by Nick
Mmm... sorry I didn't quite catch what you're trying to say.. You want users to logout of Imagevue Admin from flash frontend? Or you want then to go to your own logout script?

In any case you could just have direct link to logout script.

Posted: 20 Aug 2009, 10:17
by Verovi
Hi Pain,
Sorry if that wasn't clear.

I have my own script in place. It is a script i have inclused in the index.php file.

It checks the auth session and refers the user to a login.php page, where they enter user/pass and it the directs them back to the index.php page.

This works fine and does what it should.

There is a command to logout, where it would de-auth the session and the user would be taken to a thankyou.php page.

The command to kill the log in script is:

<A HREF="<? echo $PHP_SELF ?>?action=logout">Log out</A>

I am trying to place the link in the gallery menu.
I get to sepecify a title, description and URL.

When i try to use that as the link it adds it on to the URL like so:

www.mysite.com/content/<A HREF="<? echo $PHP_SELF ?>?action=logout">Log out</A>

I was wondering is there are any special paramaters or tags i need to use to run a php function from inside the flash movie.

I have had a look on the web and have found various php calls from flash etc, but nothing usable in this instance.

Any ideas?

I realize it's not a garden variety question so no worries if its a no go.
Thanks for your time anyway.

Posted: 20 Aug 2009, 11:51
by Nick
Why not just add a direct link to yoursite.com/index.php?action=logout ? without php_self and stuff

Posted: 21 Aug 2009, 03:01
by Verovi
Thanks for your assistance.
That worked perfectly.