2
Contributors
1
Reply
2
Views
6 Years
Discussion Span
Last Post by Shanti C
0

you can show the page content based on your query string like:
lets say if page url is like: mypage.php?show=form then:

if($_GET['page']=="form")
{
// showing form
}

if page url is like: mypage.php?show=edit then:

if($_GET['page']=="form")
{
// showing form data
}
else if($_GET['page']=="edit")
{
// showing edit data
}
else
{
// something else
}

if you want to pass two variables at a time,then
url would be : mypage.php?show=edit&editid=9 then you can do like this:

if($_GET['page']=="form")
{
// showing form data
}
else if($_GET['page']=="edit")
{
  $id=$_GET['editid'];
you can use $id to retrieve query or something

}
else
{
// something else
}

and also check this link:
http://www.phpknowhow.com/get-and-post/understanding-get-and-post/

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.