Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?
- // The DB connections data
- $hostname = 'localhost';
- $dbusername = 'xxxxxx';
- $dbpass = 'xxxxxxx';
- $dbname = 'xxxxxxx';
- ?>
- <? $weightid=$_REQUEST['cantidad'];
- $link = mysql_connect($hostname, $dbusername, $dbpass); //changet the configuration in required
- if (!$link) {
- die('Could not connect: ' . mysql_error());
- }
- mysql_select_db($dbname, $link);
- $query="SELECT title, price FROM shop_shipping where weightfrom=$weightid";
- $result=mysql_query($query);
- ?>
- <select name="provincia">
- <option>Selecciona provincia</option>
- <? while($row=mysql_fetch_array($result)) { ?>
- <option value=<?=$row['price']?>><?=$row['title']?></option>
- <? } ?>
- </select>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement