Welcome Guest, Not a member yet? Register   Sign In
Problem with sending form data by Query string
#1

[eluser]Unknown[/eluser]
Hi,

I have form which is having one text field, named by CompanyName. when I submit the form it submitting as query string (form method is GET )as i want. The following is sample URL for that : http://localhost/index.php/Companysearch...me=Darwish

I'm trying to get CompanyName within my result function as follows:

Code:
function result(){
  if(isset($_GET['CompanyName'])){
    $comName = $_GET['CompanyName'];
  }
  echo $comName;
}

My problem is that, it says $comName is undefined variable. Is there any wrong in my code?.
or can't we use like above?

Please guide me how to sort out this

Nisal


Messages In This Thread
Problem with sending form data by Query string - by El Forum - 10-23-2007, 02:32 AM
Problem with sending form data by Query string - by El Forum - 10-23-2007, 04:08 AM
Problem with sending form data by Query string - by El Forum - 10-23-2007, 04:34 AM
Problem with sending form data by Query string - by El Forum - 10-23-2007, 06:32 AM



Theme © iAndrew 2016 - Forum software by © MyBB