X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=catagits%2FCatalyst-Manual.git;a=blobdiff_plain;f=lib%2FCatalyst%2FManual%2FTutorial%2F05_Authentication.pod;h=87ab43522ef13139d54ce424847c2c140618cfac;hp=1b6078f9c65a01068b9c152fef709fb5743e62e7;hb=02bb2b5a140dc22d7d002fcdce868656d704676a;hpb=388f66e0214312ffa77b48128d2fa2e1932b4669 diff --git a/lib/Catalyst/Manual/Tutorial/05_Authentication.pod b/lib/Catalyst/Manual/Tutorial/05_Authentication.pod index 1b6078f..87ab435 100644 --- a/lib/Catalyst/Manual/Tutorial/05_Authentication.pod +++ b/lib/Catalyst/Manual/Tutorial/05_Authentication.pod @@ -85,22 +85,22 @@ opening F in your editor and insert: -- PRAGMA foreign_keys = ON; CREATE TABLE users ( - id INTEGER PRIMARY KEY, - username TEXT, - password TEXT, - email_address TEXT, - first_name TEXT, - last_name TEXT, - active INTEGER + id INTEGER PRIMARY KEY, + username TEXT, + password TEXT, + email_address TEXT, + first_name TEXT, + last_name TEXT, + active INTEGER ); CREATE TABLE role ( - id INTEGER PRIMARY KEY, - role TEXT + id INTEGER PRIMARY KEY, + role TEXT ); CREATE TABLE user_role ( - user_id INTEGER REFERENCES users(id) ON DELETE CASCADE ON UPDATE CASCADE, - role_id INTEGER REFERENCES role(id) ON DELETE CASCADE ON UPDATE CASCADE, - PRIMARY KEY (user_id, role_id) + user_id INTEGER REFERENCES users(id) ON DELETE CASCADE ON UPDATE CASCADE, + role_id INTEGER REFERENCES role(id) ON DELETE CASCADE ON UPDATE CASCADE, + PRIMARY KEY (user_id, role_id) ); -- -- Load up some initial test data @@ -433,19 +433,19 @@ Create a login form by opening F and inserting:
- - - - - - - - - - - - -
Username:
Password:
+ + + + + + + + + + + + +
Username:
Password:
@@ -515,8 +515,8 @@ lines to the bottom of the file: ...

[% - # This code illustrates how certain parts of the TT - # template will only be shown to users who have logged in + # This code illustrates how certain parts of the TT + # template will only be shown to users who have logged in %] [% IF c.user_exists %] Please Note: You are already logged in as '[% c.user.username %]'. @@ -525,11 +525,11 @@ lines to the bottom of the file: You need to log in to use this application. [% END %] [%# - Note that this whole block is a comment because the "#" appears - immediate after the "[%" (with no spaces in between). Although it - can be a handy way to temporarily "comment out" a whole block of - TT code, it's probably a little too subtle for use in "normal" - comments. + Note that this whole block is a comment because the "#" appears + immediate after the "[%" (with no spaces in between). Although it + can be a handy way to temporarily "comment out" a whole block of + TT code, it's probably a little too subtle for use in "normal" + comments. %]

@@ -575,8 +575,8 @@ bottom (below the closing tag): ...

- Login - Create + Login + Create

Reload your browser and you should now see a "Login" and "Create" links