December 27, 2011 at 10:12 pm #167064
I am submitting to a pod page the following1234567891011121314151617<?php$nomcomplet = $_POST['nomcomplet'];$message = $_POST['txtzone'];$slug = $_POST['slug'];$decede= $_POST['decede'];$api = new PodAPI();// all of the values to save and options to use$params = array('datatype' => 'condoleances','columns' => array('name' => '$nomcomplet','description' => '$message','avisid' => '$decede'));$params = pods_sanitize($params);// create the item$condoleances_id = $api->save_pod_item($params)?>
What am I doing wrong ?
I would like the user redirected to the previous page once the information is submitted, that is why i post the $slug.
The pod I am saving to have the following structure:
name (txt) *
avisid (pick avis)
Thanks !December 28, 2011 at 1:32 pm #167067
You edited your code, but did your SQL error change?December 28, 2011 at 2:46 pm #167065
sc0ttkclarkKeymasterPost count: 781
He fixed it, it was a pod page conflict somewhere that was running code elsewhere. There was a findRecords running somewhere that wasn’t populating avisid.id which threw the MySQL error above.December 29, 2011 at 2:10 am #167066
Thanks Chris and Scott. I am in love with PODS now ! It is truly a magnificent piece of work !
You must be logged in to reply to this topic.