Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Passing Variables through login page

Guest
Jan 25, 2007 Jan 25, 2007
Hi all,

I have a site www.hrhotlineinc.net that has a public and a member side. On the public side is a list of articles. Some are free and some are member only.

When you click on the article that is members only it goes from article.php to members/articledetails.php. The URL passes the variable articleID.

If the user is not logged on the user goes to articlelogin when clicking the article and they login. Again, using the Dreamweaver User Authenitcation behaviour. On success the user goes to articledetails.php in the members section.

The issue is I have never worked with session variables before. I tried to set one and echo that after the success url in the login but the page errors out.

How can I set that and still pass the articleID so it is readable in the url by the article detail page?

Thanks in advance.
TOPICS
Server side applications
290
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jan 25, 2007 Jan 25, 2007
LATEST
On Thu, 25 Jan 2007 22:17:51 +0000 (UTC), "chieffan"
<webforumsuser@macromedia.com> wrote:

> The issue is I have never worked with session variables before. I tried to
>set one and echo that after the success url in the login but the page errors
>out.
>
> How can I set that and still pass the articleID so it is readable in the url
>by the article detail page?

So, if someone clicks on an URL for a member-only article
(article.php?art_id=10, for example) they are redirected to the member
login page, right?

Then if login is successful you need to send them to the detail page
using:

header ("Location:
http://www.mysite.com/member/articledetail.php?art_id=".$_GET['art_id'

obviously substituting the URL for your actual site in the above line.

Is that what you want?
--
Steve
steve at flyingtigerwebdesign dot com
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines