Ich benutze eine vorbereitete Anweisung Ich habe genau die gleiche Menge an Variablen in bind_param übergeben, wie ich es erwarte, aber immer noch hat ginving mir einen Fehler von variablen Zählung nicht match.here ist der Codemysqli_stmt :: bind_result(): Die Anzahl der Bindevariablen entspricht nicht der Anzahl der Felder in der vorbereiteten Anweisung in
$query="select `shipping_name`,`shipping_address1`,`shipping_address12`,`shipping_city`,`shipping_state`,`shipping_postalcode`,`billing_name`,`billing_address2`,`billing_address22`,`billing_city`,`billing_state`,`billing_postalcode` from puppy_shipping where unique_id=?";
$stmt = $db->prepare($query);
$bind='ssssssssssss';
if($stmt){
$stmt->bind_param('s',$id);
$stmt->execute();
$stmt->bind_result($bind,$shipping_name,$shipping_address1,$shipping_address12,$shipping_city,$shipping_state,$shipping_postalcode,$billing_name,$billing_address2,$billing_address22,$billing_city,$billing_state,$billing_postalcode);
while ($stmt->fetch())
{
}
$stmt->close();
}
'bind_result()' nicht über die Bindung von Typen machen (wie 'bind_param()' tut), so lösche die '$ bind'-Variable. – Qirel
fertig! Jetzt habe ich diesen Fehler! Kann Parameter 1 nicht als Referenz in – uneeb
übergeben und es sieht jetzt so aus! $ stmt-> bind_result ('ssssssssssss', $ Versandname, $ Versandadresse1, $ Versandadresse12, $ Versandstadt, $ Versandsteuerstatus, $ Versandpostleitzahl, $ Rechnungsstellenname, $ Rechnungsadresse2, $ Rechnungsadresse22, $ Rechnungsstellungsstadt, $ Rechnungsstellungsstatus, $ Rechnungszahl); – uneeb