I don't understand sessions and cookies.
Posted: Fri Jan 14, 2011 11:04 am
Hello everyone,
I'm a newbie PHP programmer (I have a background in C++, but that's really it - aside from HTML and JavaScript, of course). I'm picking up the language rather easily, and the MySQL integration is... it makes me shudder sometimes how flexible and easy the whole system is, but one thing I'm really just not... understanding is Sessions and cookies.
I want to create some sort of blog/forum system myself (I understand PHPBB is good, but I just want this for myself - a good establishment of what I can do). The blog I'm not having too many issues with... I understand the updating of the MySQL database enough to be able to sort by latest id #, add, delete, edit, and search... But really the issue is the login system.
I have no idea where to even start, how sessions and cookies work, etc. Can anyone help explain, I would really, really appreciate it. :/ Thank you so so much.
Just a tutorial really that explains how they work and how to check where the code should go on different pages... so they can stay logged in on many different pages. Also, I'd like to learn how to be able to update the cookie so if they are active, they won't just randomly be logged out. I also am interested in the hashing of the password and all other security measures so as to make sure the person's login is secure, and that nobody can do a MySQL injection.
I am eager to learn, but I'll be honest - I definitely need help. The goal is to be able to make truly complex and wonderful systems, and I see what PHP can do - but I just know the basics. Now I need to move from that and leap up to an even higher spot.
I'm a newbie PHP programmer (I have a background in C++, but that's really it - aside from HTML and JavaScript, of course). I'm picking up the language rather easily, and the MySQL integration is... it makes me shudder sometimes how flexible and easy the whole system is, but one thing I'm really just not... understanding is Sessions and cookies.
I want to create some sort of blog/forum system myself (I understand PHPBB is good, but I just want this for myself - a good establishment of what I can do). The blog I'm not having too many issues with... I understand the updating of the MySQL database enough to be able to sort by latest id #, add, delete, edit, and search... But really the issue is the login system.
I have no idea where to even start, how sessions and cookies work, etc. Can anyone help explain, I would really, really appreciate it. :/ Thank you so so much.
I am eager to learn, but I'll be honest - I definitely need help. The goal is to be able to make truly complex and wonderful systems, and I see what PHP can do - but I just know the basics. Now I need to move from that and leap up to an even higher spot.