Gossamer Forum
Home : Products : DBMan : Customization :

Bypass Login

Quote Reply
Bypass Login
Hi,
I've been reading through this forum trying to work out how to bypass the login process on multiple databases sharing the same password file.
Once loged into the main database how can I access the other databases without having to login on each one.
I tried this the following in my link-
$db_script_url?db=database2&uid=$db_uid&add_form=1
but I still get the login screen for database2.
How do I jump the login screen?
I also noticed that there is no value showing up for the $db_uid.
Any ideas??
Thanks
Simon.

Quote Reply
Re: Bypass Login In reply to
$db_script_url?db=database2&uid=$db_uid&add_form=1

is correct.

In Reply To:
I also noticed that there is no value showing up for the $db_uid.
That's why you're getting the login screen. Where do you have this link?

JPD
http://www.jpdeni.com/dbman/
Quote Reply
Re: Bypass Login In reply to
Hi JPDeni,
I have the link in the html_footer.
The standard Add link in the footer works ok and the $db_uid value is as it should be.
The additional link that calls database2 doesn't pick up the value for $db_uid.
What do I need to add and are there any special settings to be aware of in the config file?
Thanks
Simon.

Quote Reply
Re: Bypass Login In reply to
I don't know. The $db_uid variable is a global variable that is set near the beginning of the db.cgi script. It should be available to you. I can't imagine why it wouldn't be there.

JPD
http://www.jpdeni.com/dbman/
Quote Reply
Re: Bypass Login In reply to
Hi again,
I have just noticed that the link is ok on most of the html pages but not the main menu page (html_home).
On the other pages, the $db_uid value is correct but I get a
invalid/expired user session error message when I try to access database2.
Any more ideas??
Thanks
Simon.



Quote Reply
Re: Bypass Login In reply to
Have you made any changes to sub html_home or how the user first logs in?

JPD
http://www.jpdeni.com/dbman/
Quote Reply
Re: Bypass Login In reply to
JPDeni,
I haven't made any changes to the login or the sub html_home.
The invalid login error message is not a problem anymore (the files in question weren't sharing the same auth file) but the missing $db_uid is still a problem.
On the first screen that apears after log in (main menu) I can't get the links to display the $db_uid value but on all the other pages it is ok. If I click on the home link and go to what apears to be the same main menu page then the links are ok. Why doesn't it work the first time around??
I have solved the problem by using the following but am concerned if it's a suitable solution.
$db_script_url?db=database2&uid=$session_id&add_form=1
Is there a problem using the $session_id??
Thanks for your help.
Simon.

Quote Reply
Re: Bypass Login In reply to
Are you using DBMan-SQL? That's the only place that I've found a variable called $session_id.

I don't know if it will cause problems or not. I haven't had a good look at DBMan-SQL.

JPD
http://www.jpdeni.com/dbman/
Quote Reply
Re: Bypass Login In reply to
Hi,
Yes, I am using DBMan SQL.
And now that I think about it, $session_id is probably the same as $db_uid.
I'll post something in the DBMan SQL forum.
Thanks for your help.
Simon.