I have to be able to retreive the data from my Database so that the customers are sorted into two seperate fields of ?40 and ?60.
PHP CODING
[php]
View Customers by category <?php #get the Customer Price Category i.e. Acat variable $Cat = $_GET['Acat']; #-------------------------------------------------------- echo(""); echo("Customer Price Category Results for :$CAT
"); $VariableName = $_GET['VariablePassed']; #-------------------------------------------------------- # connect to MySQL $conn = @mysql_connect("localhost","ajdref","ref2") or die ("sorry - could not wont connect to MySQL"); # select the specified database $rs = @mysql_select_db("ajdref", $conn) or die ("sorry - could not connect to the ajdref"); #create the query - sets $sql to contain the required query $sql = 'SELECT * FROM `Booking Database` ORDER BY `Booking Database` . `Price Cat` ASC LIMIT 0, 30 '; #execute the query - uses the mysql_query() function to issue the $sql query to the $conn connection #$rs contains the result set in the form of an array $rs = mysql_query($sql,$conn); ?> [/php]
HTML CODING
[code]
Search by category Search by Price Category
Please choose price category from this list. A - ?40 B - ?60
Now click 'Send'.
[/code][/b]
**Mod Edit - Added PHP Tags for better readability.