Stone Gossard
-
Posts
5 -
Joined
-
Last visited
Never
Posts posted by Stone Gossard
-
-
[!--quoteo(post=351075:date=Mar 2 2006, 02:54 PM:name=willpower)--][div class=\'quotetop\']QUOTE(willpower @ Mar 2 2006, 02:54 PM) [snapback]351075[/snapback][/div][div class=\'quotemain\'][!--quotec--]
I'd suggest that you have added a whitespace to the end of the url before closing the quotation marks
will
[/quote]
Will,
I had an extra inverted comma, thanks.
Stone -
Thanks for that code and i've tried it ok, and it does redirect to the users homepage based on their access level but it keeps adding
code:
reg_user_page.php%22
Why does it add "%22" to the end of the URL? That's what causing it not to find the page.
Stone -
[!--quoteo(post=346767:date=Feb 17 2006, 10:34 AM:name=wildteen88)--][div class=\'quotetop\']QUOTE(wildteen88 @ Feb 17 2006, 10:34 AM) [snapback]346767[/snapback][/div][div class=\'quotemain\'][!--quotec--]
Something like the following:
[code]<?php
session_start();
$link = "<a href=";
if($_SESSION['access_lvl'] == "Admin")
{
$link .= "admin_homepage.php";
}
elseif($_SESSION['access_lvl'] == "User")
{
$link .= "reg_user_homepage.php";
}
$link .= "\">Home</a>";
echo $link;
?>[/code]
[/quote]
Top Class.
Thanks a Mill.
Stone
-
I want to be able to have a hyperlink at the end of a page which can be accessed from a number of pages. This hyperlink should bring the user back to a specified homepage based on their access level, e.g. administrator is brought back to admin_homepage.php and registered user is brought back to reg_user_homepage.php.
I have sessions working on my site and i know this isn't too difficult but just now sure how to do the hyperlink thing.
Appreciate it.
Stone
Websites for Differing Screen Sizes
in PHP Coding Help
Posted
Maybe this is for a HTML forum but I'm kinda hoping that I can do this in php. I am designing a website for a company on my 17" screen and it's fine.But i just got a call from my employer to say that they use 15" screens and that they need to scroll to see the front page in full.
Is there any php solution to this?Is there some code that will make the webserver serve the page to suit all screen sizes?
Stone