Using the Session Variable in PHP to create bookmarks in a website

preview_player
Показать описание
Bookmarks or a shopping basket can be create in a number of ways, but in this tutorial I want to show how to use the PHP session variable to allow the user to add items of any sort for the duration of a website visit.

Here we create an array called the bookmarks array that is then inserted into the session array - creating an array within an array!

The user can then add items into this inner array at will over the duration of their session.

At a time of their choosing, they can go back and show the array items and do any processing that is necessary.
Рекомендации по теме
Комментарии
Автор

Awesome video, can I use backend to save the bookmarks instead? Or use cookies or something similar? When they go back to the website their saved "stuff..ect" it automatically loaded back into the website? Or can you give me some help with what to search to get my answer? Thanks again

krims
Автор

Thanks for this tutorial. How did you automatically get back to the previous page after bookmarking a member? I can't do this in my code. Please reply.

mahnazrafiaislam
Автор

hello can you provide me a link where i can download your bookmark project

nepalcodechallenge
Автор

I am developing a project where i need to bookmarks some member, but when I logout from my project the bookmarks member are automatically removed. They are not visible in the show-bookmarks.php page. How can I store them after logging out? How to store the session variables.

moniruzzamannayon
Автор

Where can I download the full code? google drive?

giorgiaadams