Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 23

Thread: Secure Log-in

  1. #11
    Join Date
    Aug 2006
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Thank you for your replies guys, much appreciated. I've been reading through the MySQL I think it's more complicated than doing the php bit.

    Hi Blm126

    1) There should be nothing but twey's script in a file called security.inc.php. Apology for sounding dah but I don't know what you mean should be nothing.
    I've pasted the whole scripts in one of my webpage right at the top of the source code (the page is a normal webpage it has images, text colours etc) or should I paste the script in an empty page then save it as ie: firstpage.secure.php?


    2)Yes,it goes at the top(before the <html> tag). The code is the following
    PHP Code:
    <?php require('security.inc.php'); ?>
    Please note that any page you are using to protect with this needs to have an extension of PHP or have your server configured to treat them as PHP.


    Ok for example I have this web page called abc.htm, I then insert <?php require ('firstpage.secure.php'); ?> right at the top of the source code before the bit where it says <!DOCTYPE HTML PUBLIC " and save it as abc.php, is that correct?

    3) see above note Sorry can you elaborate on this, which file am I going to use for log-in page?

    4)Follow number two above I'll check this one

    5)Through your preferred database tool.Something like PhpMyAdmin. I'm so sorry but I don't know where I could find this and how to use it?

    I'm new on this as you could tell but I'm determine to learn no matter how long it takes as hopefully one day when the questions arises again maybe I'll be able to help others a little at least.

    Thank you so much.

  2. #12
    Join Date
    Jun 2005
    Location
    英国
    Posts
    11,876
    Thanks
    1
    Thanked 180 Times in 172 Posts
    Blog Entries
    2

    Default

    I've been reading through the MySQL I think it's more complicated than doing the php bit.
    But you have a MySQL database set up, yes?
    I've pasted the whole scripts in one of my webpage right at the top of the source code (the page is a normal webpage it has images, text colours etc) or should I paste the script in an empty page then save it as ie: firstpage.secure.php?
    It should be in a separate file.
    Ok for example I have this web page called abc.htm, I then insert <?php require ('firstpage.secure.php'); ?> right at the top of the source code before the bit where it says <!DOCTYPE HTML PUBLIC " and save it as abc.php, is that correct?
    Yes, if you've called the file firstpage.secure.php.
    which file am I going to use for log-in page?
    All the protected pages will generate a login form if the user isn't logged in; there's no need to create a separate page.
    I'm so sorry but I don't know where I could find [phpMyAdmin] and how to use it?
    http://www.google.com/search?q=phpmyadmin&btnI=true
    Twey | I understand English | 日本語が分かります | mi jimpe fi le jbobau | mi esperanton komprenas | je comprends français | entiendo español | tôi ít hiểu tiếng Việt | ich verstehe ein bisschen Deutsch | beware XHTML | common coding mistakes | tutorials | various stuff | argh PHP!

  3. #13
    Join Date
    Aug 2006
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default secure log-in

    Hi,

    No, I have not a clue about MySQL I've mentioned it as I was reading up about it but I'd rather use this php thing as it seems quicker to set up, I hope.

    Thank you for that. I think I'm getting the understanding of it, a little. Ok I've done all that now, I've pasted the script and save it then put all the php code on each of the file I want protecting then save it as filename.php instead of htm.

    When I fist tried it out, yes it prompted me to log-in so I just put whatever name and password then it got me in (worrying) but then when Itried to log-in again it says this message Access denied for user: 'apache@localhost' (Using password: NO)

    I've checked out that Phpmyadmin link you sent, there are three version to download, do I download one? Which version then what happens after I've downloaded it?

    Many thanks.

  4. #14
    Join Date
    Jun 2005
    Location
    英国
    Posts
    11,876
    Thanks
    1
    Thanked 180 Times in 172 Posts
    Blog Entries
    2

    Default

    No, I have not a clue about MySQL I've mentioned it as I was reading up about it but I'd rather use this php thing as it seems quicker to set up, I hope.
    My script, as with most PHP scripts of this type, uses MySQL as a backend. You will need a working database to use it. You seem to be under the impression that PHP and MySQL are alternatives. This is not so. MySQL is only a database system. It has a limited Structured Query Language that can perform some operations, but these are mostly limited to result selection. To manipulate the data retrieved, a language like PHP is required.
    Twey | I understand English | 日本語が分かります | mi jimpe fi le jbobau | mi esperanton komprenas | je comprends français | entiendo español | tôi ít hiểu tiếng Việt | ich verstehe ein bisschen Deutsch | beware XHTML | common coding mistakes | tutorials | various stuff | argh PHP!

  5. #15
    Join Date
    Aug 2006
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Secure log-in

    Hi,

    I did think it was kind of an option which one to use, oh dear I thought I've got it going then

    So now I've also got to learn MsQL and download that phpmyadmin as well, which I've no clue of using?

    So I can't just use the scripts that you gave me then I also have to create MySQL database, hmmmmmm how do I do start? and where do I start? I've seen within my hosting account that there is MySQL, it says either you could create or upload it? How do you create it? Is it like a webpage or what?

    I'm so disappointed with my silly self now because I thought yes I've cracked it despite others have been telling me not to bother but I was determine to learn and that.

  6. #16
    Join Date
    Sep 2005
    Posts
    882
    Thanks
    0
    Thanked 3 Times in 3 Posts

    Default

    *sigh* you don't need MySQL. It is entirely possible to create a flat file(just PHP) alternative. However, before I go on. Is the password/user list updated often?Don't get discouraged, this is going to be a great learning experience for you! Also, what is your host? They may provide PhpMyAdmin.

  7. #17
    Join Date
    Aug 2006
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Secure php log-in

    Hi,

    Thank you, it certainly is a learning curve for me, but when I do crack the code hey presto I'll celebrate and I have you all guys to thank for, you've all been very very patience and helpful.

    I'm off to find out about phpMyAdmin. Hope I get it all working before I'm old and grey

  8. #18
    Join Date
    Aug 2006
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Log-in

    Hi,

    I have checked with my host they say I need to see MySQL then the phpmyadmin can be accessed there something like that, please can anyone help to get onto the next process as I think it will hopefully work just the password & username that I don't know how to do

  9. #19
    Join Date
    Sep 2005
    Posts
    882
    Thanks
    0
    Thanked 3 Times in 3 Posts

    Default

    Does your host use Cpanel?

  10. #20
    Join Date
    Aug 2006
    Posts
    11
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Secure Log-in

    Hi,

    Thank you for your reply. Yes I think it is on Linux server and using Cpanel.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •