This is a discussion on "web diary" within the PHP Forum section. This forum, and the thread "web diary are both part of the Program Your Website category.
|
|
|
|
|
![]() |
||
web diary
|
||
| Notices |
![]() |
|
|
LinkBack | Thread Tools |
|
|||
|
web diary
Hi forumz
I've got a friend who wants me to make him a diary that only him can access and maybe some other friends. Anyone with such a script would be very helpful Cheers Jon |
|
|
|
||||
|
Re: web diary
Since there's only a few person viewing it, you'd only need one or two usernames so mysql would be pointless i guess.
This might work, haven't tested it. login form:
That should work Sorry if you know how to do this already.
Last Blog Entry: 3D Chess in your browser! (Mar 14th, 2008)
|
|
|||
|
Re: web diary
Quote:
Says there is an error on this line
|
|
||||
|
Re: web diary
sorry it should be:
Last Blog Entry: 3D Chess in your browser! (Mar 14th, 2008)
|
|
|||
|
Re: web diary
wow that was cool. And can you put a logout buttons? what code do u put to it?
|
|
||||
|
Re: web diary
I use this method:
then just link to it normally like: <a href="logout.php">Click here to logout</a>
Last Blog Entry: 3D Chess in your browser! (Mar 14th, 2008)
|
|
|||
|
Re: web diary
I have put the code in the logout.php file and this is what I get
|
|
||||
|
Re: web diary
oh sorry
i think it should be:
Last Blog Entry: 3D Chess in your browser! (Mar 14th, 2008)
|
|
|||
|
Re: web diary
that works but if you click back it still displays the details that are supposed to be secure. Even when you put a wrong password it still dispays the information but still gives you the "wrong password"
Checkout here. Is it neccessary to display everything that I have put here? |
|
||||
|
Re: web diary
What's the link to the page that the content is actually on?
and what username/password are you using?
Last Blog Entry: 3D Chess in your browser! (Mar 14th, 2008)
|
|
|||
|
Re: web diary
http://john.habari.co.tz/loginphp/
Username: admin Password: 123 After login try to click on NOT link says "you aren't logged in" |
|
||||
|
Re: web diary
okay i don't understand what the "not.php" page is for.
but put this on your content protected page after session_start();
Last Blog Entry: 3D Chess in your browser! (Mar 14th, 2008)
|
|
|||
|
Re: web diary
When I login I get this
|
|
|||
|
Re: web diary
Ok. Let me just put the whole thing here:
index.php
login.php
|
|
||||
|
Re: web diary
Okay for starters you don't need to link to the not page, as it's already in the login code.
What is the exact problem you are having?
Last Blog Entry: 3D Chess in your browser! (Mar 14th, 2008)
|
|
||||
|
Re: web diary
Oh and my fault, change:
$_SESSION['loggedin'] == $username; to $_SESSION['loggedin'] = $username;
Last Blog Entry: 3D Chess in your browser! (Mar 14th, 2008)
|
![]() |
| Tags |
| diary |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Diary/archive help, trying to use CSS to display DIVs dynamically... | thintin | Web Page Design | 1 | May 1st, 2008 20:54 |