How to pass a variable from php to a modal?

PHP session variable pass?

  • Hi. i have several pages. 1. page login. in login page i am taking his/her id. And in 2. page, i am checking if id is true. If id is true i am showing his/her name and other personal informations. The problem is, i have 2 buttons next and back. When he click next button, he will go 3. pages. It works fine, but when i want to back to first page, if does not work fine. <form action="test.php" method="post"> <table> <tr> <td cols=2> <input size="3" maxlength="3" name="kod"></td> <tr><td><input value="<< Back " name="giris" type="submit"> </td> <td><input value="next >>" name="giris" type="submit"> </td></tr> </table> </form> The form is wrong i know but i donno how to make true. How can i search on google to solve this problem? How can i find a php example ?

  • Answer:

    you need to add the session_start() on the login page and make sure that you pass the login details / variables to the $_SESSION

guych at Yahoo! Answers Visit the source

Was this solution helpful to you?

Other answers

Can you explain in more detail what you mean? They press back from page 2 and are taken back to page 1. What is your intended result? That they login again, or that page 1 checks for a valid session variable?

geekfound

Related Q & A:

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.