- This topic is empty.
August 16, 2013 at 4:45 am #147050AnonymousInactive
When following a tutorial on building a basic PHP management system, everything worked out great. Then, when I tried adding 2 more variables to pass onto the table, I came across a problem.
The function doesn’t seem to find the $_POST[‘id’] to be valid.
View the tutorial I followed
//WillAugust 16, 2013 at 9:02 am #147098AnonymousInactive
Thanks! I fixes the bind_param() to match the amount of data passed. I did not understand the bind_param function before, but now I do, ty :)
But I still get the same error.
On the page that submits the form there is no input with id, but that shouldn’t matter since the row gets an id in the table.
I have now tried:
– Recreating the database + table
– setting bind_param(“ssi”…. to “ssssi” aswell as “ss” to “ssss”.August 17, 2013 at 4:11 am #147168AnonymousInactive
Yes I did! :)
Don’t know if anyone has the time to try this themselves, but if anyone is willing they can download my EasyPHP folder with everything set up (windows) or just download the corresponding files.
The database structure looks like this: (connect located in connect.php AND process.php)
Database name: customcms
Table name: post
Cols: id INT AUTO_INCREMENT, title VARCHAR(50), date VARCHAR(50), author VARCHAR(50), content LONGTEXTAugust 18, 2013 at 10:48 am #147271AnonymousInactive
idint(11) NOT NULL AUTO_INCREMENT,
titlevarchar(50) NOT NULL,
datevarchar(50) NOT NULL,
authorvarchar(50) NOT NULL,
contentlongtext NOT NULL,
PRIMARY KEY (
) ENGINE=InnoDB AUTO_INCREMENT=3 DEFAULT CHARSET=latin1August 18, 2013 at 5:34 pm #147300AnonymousInactive
Thank you SO much for helping me! Not only did you solve my problem, but you also helped me solve future problems by learning me a bit more of troubleshooting!! Thanks!
A quick question though;
date doesn’t seem to get stored, does that have anything to do with php already using date for something else? :)
PS: I had NO idea that LONGTEXT was meant for SUPERMEGALONGTEXTs… 4gb is ALOT of text, hahah!
Once again, thank you so much!August 19, 2013 at 2:09 am #147324AnonymousInactive
Ok, got it working now, thanks! :)
Datetime it is!
Once again, thank you!August 23, 2013 at 11:41 am #147963AnonymousInactive
I had used a single = instead of two in a conditional tag.. :P
- The forum ‘Back End’ is closed to new topics and replies.