HighDots Forums  

CFML and Login Procedures

Macromedia Dreamweaver Macromedia Dreamweaver Discussions (macromedia.dreamweaver)


Discuss CFML and Login Procedures in the Macromedia Dreamweaver forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Bruce Cirrinone
 
Posts: n/a

Default CFML and Login Procedures - 07-21-2004 , 12:58 PM






I would like to require a User ID and Password for entry into the
Development area of my website.

My requirements are simple - each client will receive an ID and a Password -
for their entire organization to share. In addition, I'd like an Admin User
ID and PW that will allow access to all. I don't need an admin screen, as I
can change the data within Access itself.

I'm using DWMX04 on WinXP Pro, and the development language I'm trying to
learn is CFML. I've tried the tutotials I've found on the net, and
everything either seems too complicated or doesn't do what I need it to do.

It seems like it should be an easy project, but I'm stumped! Can someone
point me to a comprehensive tutorial, or some sort of CF extension or
something???

TIA!

--
~ Bruce
http://www.ztechsystems.net




Reply With Quote
  #2  
Old   
~Angela, TMM
 
Posts: n/a

Default Re: CFML and Login Procedures - 07-21-2004 , 01:28 PM






Hi Bruce,

Here's some pretty easy steps for you below. Do let me know if you get stuck
anywhere.

1. Create a new table to hold your access levels.
intAccessID | txtAccessFriendlyName
1 | Admin
2 | User
3 | Guest

2. Create the login page. login.cfm

3. Click the (+) button in the Server behaviors panel and then choose User
Authentication> Login User

4. Complete the dialog (it is pretty straight forward). Be sure to choose
Restrict access based on username, password, and access level. Choose the
intAccessID field for the Get level from list.

5. Next, on any page (other than login.cfm) that you wish to restrict access
to, click the (+) button in the Server behaviors panel and then choose User
Authentication> Restrict Access To Page.

6. You will need to define your access levels. Use 1, 2, and 3 as the access
levels, not their friendly name. Why? A) Less code B)Hard to misspell a
number. C)You can change the friendly name if needed later without breaking
the authentication. You should only need to complete this step the first
time you apply the server behavior to a site.

7. Hold the shift key to select more than one access level. You'll ALWAYS
select 1 since it is your admin, and they need access to everything.

8. Get fancier by taking the code this generates and making an include out
of it. Then any time you need this access level combination, you just add
this include to a page and you won't have to go through applying the Server
behavior again.

Tip: I always create includes for each of the access level combinations I
need and name them according to the lowest level that is allowed. For
example, I would have incLevel1.cfm, incLevel2.cfm and incLevel3.cfm. If I
include incLevel2.cfm it will allow both level 1 and level 2. If I include
incLevel3.cfm it allows levels 1, 2, and 3.

Good luck!
~Angela
--
Angela C. Buraglia, Founder:
~FAQs, Tutorials & Resources~ http://www.DreamweaverFAQ.com
~My Extensions~ http://www.dwfaq.com/go.asp?ID=AngelaX10
DWfaq Support Newsgroup: news://support.dwfaq.com/support

Co-Author with Joseph Lowery, Dreamweaver MX 2004 Killer Tips:
http://www.dwkillertips.com

Extension Developer for Cartweaver 2:
http://www.cartweaver.com/features/extensionsuite/

Remove the CAPS in my E-mail to reply off list.




"Bruce Cirrinone" <mrbrucec (AT) removeme (DOT) hotmail.com> wrote

Quote:
I would like to require a User ID and Password for entry into the
Development area of my website.

My requirements are simple - each client will receive an ID and a
Password -
for their entire organization to share. In addition, I'd like an Admin
User
ID and PW that will allow access to all. I don't need an admin screen, as
I
can change the data within Access itself.

I'm using DWMX04 on WinXP Pro, and the development language I'm trying to
learn is CFML. I've tried the tutotials I've found on the net, and
everything either seems too complicated or doesn't do what I need it to
do.

It seems like it should be an easy project, but I'm stumped! Can someone
point me to a comprehensive tutorial, or some sort of CF extension or
something???

TIA!

--
~ Bruce
http://www.ztechsystems.net






Reply With Quote
  #3  
Old   
Spiky
 
Posts: n/a

Default Re: CFML and Login Procedures - 07-21-2004 , 01:34 PM



If you have DMX2004 you can take advantage of the server behaviors to create
a login with username, password and level of authentication. Failing that,
get your hands on Oreilly's "Programming ColdFusion" or Ben Forta's
"ColdFusion MX Web Application Construction Kit". There are some exercises
on what you're looking for in both books.

bonne chance!



"Bruce Cirrinone" <mrbrucec (AT) removeme (DOT) hotmail.com> wrote

Quote:
I would like to require a User ID and Password for entry into the
Development area of my website.

My requirements are simple - each client will receive an ID and a
Password -
for their entire organization to share. In addition, I'd like an Admin
User
ID and PW that will allow access to all. I don't need an admin screen, as
I
can change the data within Access itself.

I'm using DWMX04 on WinXP Pro, and the development language I'm trying to
learn is CFML. I've tried the tutotials I've found on the net, and
everything either seems too complicated or doesn't do what I need it to
do.

It seems like it should be an easy project, but I'm stumped! Can someone
point me to a comprehensive tutorial, or some sort of CF extension or
something???

TIA!

--
~ Bruce
http://www.ztechsystems.net






Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.