UGH Sorry .. lets try that again...
Whats happening is the function mssql_bind is looking for a literal
VARIABLE, not the VALUE of the variable.  So simply REMOVING the
quotes or single ticks in the mssql_bind statements should produce
desired results.

<?php

require 'credentials.php';

$location_id=$_POST['location_id'];
$description=$_POST['description'];
$wh_id=$_POST['wh_id'];


// Connect to MSSQL
mssql_connect("$dbserver");
mssql_select_db("$database");

// Create a new stored prodecure
$stmt = mssql_init('SP_stored_procedure');

// Bind the field names
mssql_bind($stmt, '@location_id',  $location_id,        VARCHAR,
false,  false,  13);
mssql_bind($stmt, '@description',      $description,        VARCHAR,
false,  false,  50);
mssql_bind($stmt, '@wh_id',       $wh_id,             VARCHAR,
false,  false,   10);

// Execute
mssql_execute($stmt);

// Free statement
mssql_free_statement($stmt);
?>


-- 
-- 
-- Matthew Frederico

_______________________________________________

UPHPU mailing list
[email protected]
http://uphpu.org/mailman/listinfo/uphpu
IRC: #uphpu on irc.freenode.net

Reply via email to