This is how I write to the database:
$stmt = $mysqli->prepare("INSERT INTO horoscope(oven, telec, blizneci, rak, lev, deva, vesi, scorpion, strelec, kozerog, vodoley) VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?);"); $stmt->bind_param('sssssssssss',$oventodaytext, $telectodaytext, $bliznetcitodaytext, $raktodaytext, $levtodaytext, $devatodaytext, $vesitodaytext, $scorpiontodaytext, $strelectodaytext, $kozerogtodaytext, $vodoleytodaytext); $stmt->execute(); $mysqli->close(); But nothing is recorded ... I checked through echo, everything is fine, but the database is empty) Maybe there is a problem with hosting (using 000webhost)? If you transfer 10 values in one line, then everything works:
$stmt = $mysqli->prepare("INSERT INTO horoscope(oven, telec, blizneci, rak, lev, deva, vesi, scorpion, strelec, kozerog) VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?, ?);"); $stmt->bind_param('ssssssssss',$oventodaytext, $telectodaytext, $bliznetcitodaytext, $raktodaytext, $levtodaytext, $devatodaytext, $vesitodaytext, $scorpiontodaytext, $strelectodaytext, $kozerogtodaytext); $stmt->execute(); $mysqli->close();, $ oventodaytext, $ telectodaytext, $ bliznetcitodaytext, $ raktodaytext, $ levtodaytext, $ devatodaytext, $ vesitodaytext, $ scorpiontodaytext, $ strelectodaytext, $ kozerogtodaytext);$stmt = $mysqli->prepare("INSERT INTO horoscope(oven, telec, blizneci, rak, lev, deva, vesi, scorpion, strelec, kozerog) VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?, ?);"); $stmt->bind_param('ssssssssss',$oventodaytext, $telectodaytext, $bliznetcitodaytext, $raktodaytext, $levtodaytext, $devatodaytext, $vesitodaytext, $scorpiontodaytext, $strelectodaytext, $kozerogtodaytext); $stmt->execute(); $mysqli->close();
It is necessary to write down only the eleventh parameter - nothing is recorded already ...
Made a check for errors using the proposed code, that's what got out:
execute() failed: Row size too large (> 8126). Changing some columns to TEXT or BLOB or using ROW_FORMAT=DYNAMIC or ROW_FORMAT=COMPRESSED may help. In current row format, BLOB prefix of 768 bytes is stored inline. This is how the table was created:
