Hi, again...

Can someone help me with the following code:

(LINE 74:) $get_addresses_sql = "SELECT address, city, state, zipcode, type FROM address WHERE master_id ='".$_POST['sel_id']."'";

(LINE 75:) $get_addresses_res = mysqli_fetch_array($mysqli, $get_addresses_sql) or die(mysqli_error($mysqli));

it brings up this error:

Notice: Undefined index: sel_id in /hermes/bosweb/web185/b1859/sl.mavedog21/public_html/address_book/selEntry.php on line 74

Warning: mysqli_fetch_array() expects parameter 1 to be mysqli_result, object given in /hermes/bosweb/web185/b1859/sl.mavedog21/public_html/address_book/selEntry.php on line 75

thanks again,
NLC

Recommended Answers

All 3 Replies

LINE 75 was resolved:

$get_addresses_res = mysqli_query()
NOT
$get_addresses_res = mysqli_fetch_array()

Now:
LINE 74: has to do with .$_POST["sel_id"]."'";

$sel_id = $_POST['sel_id'];

$get_addresses_sql = "SELECT address, city, state, zipcode, type FROM address WHERE master_id ='$sel_id' ";
echo $_POST['sel_id'];exit;

see what it prints...

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.