Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,150,718 members, 7,809,724 topics. Date: Friday, 26 April 2024 at 01:57 PM

Website Which Directs Different Users To Different Webpages When Theg Login. - Webmasters - Nairaland

Nairaland Forum / Science/Technology / Webmasters / Website Which Directs Different Users To Different Webpages When Theg Login. (1529 Views)

Facebook Now Allow Users To Chose Stories That Will Appear In Their News Feed / Adding Favicon On Your Webpages. / Webmaters: Show Your Webpages Screenshots (2) (3) (4)

(1) (Reply) (Go Down)

Website Which Directs Different Users To Different Webpages When Theg Login. by bigmo1(m): 6:45am On Nov 28, 2009
Pls, how do i design a website which directs different users to different webpages when they log in with a username and password (something like a member area). For example, when USER A logs in, he is taken to a webpage which only him can see, and when USER B logs in, he is taken to a page which only him can see.
Re: Website Which Directs Different Users To Different Webpages When Theg Login. by DualCore1: 8:14am On Nov 28, 2009
Use access levels and tie an access level to every user in your database. On login, a user is taken to a paged based on the access level defined for that user.
Re: Website Which Directs Different Users To Different Webpages When Theg Login. by bigmo1(m): 2:46pm On Nov 28, 2009
Tanx, i guess i shoul try that now
Re: Website Which Directs Different Users To Different Webpages When Theg Login. by Nobody: 6:03pm On Nov 28, 2009
Let us know the results
Re: Website Which Directs Different Users To Different Webpages When Theg Login. by bigmo1(m): 6:48am On Nov 29, 2009
*dhtml:

Let us know the results
Dual Core:

Use access levels and tie an access level to every user in your database. On login, a user is taken to a paged based on the access level defined for that user.

Not exacltly what i wanted. when creating the login page (Using access levels and tieing an access level to every user in my database) Dreamweaver only allows me to chose a page, which d user A would be directed to. What i want is a login page that directs specific users to specific pages when they log in thier username and password
Re: Website Which Directs Different Users To Different Webpages When Theg Login. by yawatide(f): 12:07pm On Nov 29, 2009
hmm, this reliance on dreamweaver thing, na wa wa o! 

Here is the logic of how I would go about it.  If you take the time to code it by hand, I guarantee you will get it done in half the time it will take you to learn the hoops via dreamweaver:

1) Create a login form

2) Have at least 3 tables:
a) table A contains user information (primary key, name, date of birth, etc)
b) table B contains a primary key, key from table A (as secondary key) and access level ID (another secondary key)
c) table C contains access level ID (as primary key) and access level description

3) when you process input from #1 above (I do this in what I call a "processor" page), you test the input against what was entered.  Assuming everything checks out (via mysql SELECT statement), one of the columns you would select results from would be access level ID from #2b above.  Of course, you would also perform front end validation and back end validation, to further, hopefully, sanitize your input.

Assuming 2 levels (administrator and employee):

4) You can use the php header() function to redirect user A to one page and user B to another.  Having said that:

5) It doesn't make sense to redirect people to different pages.  What if you have 1 million users? Are you going to create 1 million pages?   what if you need to make an update as simple as changing font color on say, 500 of those pages?  You see where I am going?  Maintenance for one would be a nightmare.  What I would do? I am glad you asked:

6) You have what I like to call a "landing page", a page with all options for user A and user B.  Then depending on access level, you turn "on" or "off" certain features.  I think this is more efficient.

Make sense?  Either way, learn hand-coding (In your case code via dreamweaver's code view ONLY).  Trust me, you will be the better person for it.

good luck!
Re: Website Which Directs Different Users To Different Webpages When Theg Login. by Nobody: 7:12pm On Nov 29, 2009
i somehow doubt if this poster can do direct coding
Re: Website Which Directs Different Users To Different Webpages When Theg Login. by bigmo1(m): 10:38pm On Dec 03, 2009
@ Yawa-ti-de: Tanx 4 d info. u got exac tly what i was talking about, and to some extent, i am making a headway. But i am still a little confused, pls can u drop ur no so i can call and 4 more explanation.
Re: Website Which Directs Different Users To Different Webpages When Theg Login. by yawatide(f): 10:42pm On Dec 03, 2009
Sure. you can email yawatide at yahoo dot com or yim yawatide.

look forward to yarning with you soon cool
Re: Website Which Directs Different Users To Different Webpages When Theg Login. by sayhi2ay(m): 10:45pm On Dec 03, 2009
yawa-ti-de:

Sure. you can email yawatide at yahoo dot com or yim yawatide.

look forward to yarning with you soon cool

lol, maybe the guy wan redesign facebook.
the first step in designing a web application is critically thinking if your architecture makes sense, that way, you make life easy for yourself.
Re: Website Which Directs Different Users To Different Webpages When Theg Login. by bigmo1(m): 12:29am On Dec 04, 2009
sayhi2ay:

lol, maybe the guy wan redesign facebook.
the first step in designing a web application is critically thinking if your architecture makes sense, that way, you make life easy for yourself.


Yeah! i ve tot about d achi, i know what i want, jst don't how to perfectly go about it. i am jst a newcomer to php/mysql server tech, and everyy thing i do is self development, so i need every help i could get
Re: Website Which Directs Different Users To Different Webpages When Theg Login. by sayhi2ay(m): 2:50pm On Dec 04, 2009
big mo:

Yeah! i ve tot about d achi, i know what i want, jst don't how to perfectly go about it. i am jst a newcomer to php/mysql server tech, and everyy thing i do is self development, so i need every help i could get

If you are new to php, are you also new to other programming languages? you should realize that your proposed data structure is shaky.
try lynda.com for some php videos.

(1) (Reply)

Bulk SMS Portal Hacked? / The SEO Wars --- Are Nigerian Bloggers Getting It All Wrong? / c medics is a scammer

(Go Up)

Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health
religion celebs tv-movies music-radio literature webmasters programming techmarket

Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10)

Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 33
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.