Quote:
Originally Posted by 007
What is wrong with this code I'm using?
Code:
$this->validfields['customfield'] = array(TYPE_STR, REQ_NO);
I am having issues with text that contains an apostrophe. This is being used in a few locations including threaddata_start and threadfpdata_start.
I've also put the following code under edit_post_update_start
Code:
$vbulletin->input->clean_gpc('p', 'customfield', TYPE_STR);
$edit['customfield'] =& $vbulletin->GPC['customfield'];
Still, I get database errors when submitting text with apostrophes in this custom field.
Thoughts?
|
There is not enough code here to see what you are doing. The array "$edit" is not saved to the database directly, it is processed through the datamanager. $edit['customfield'] will not be stored by the datamanager without additional code so the datamanager can process it. At least, I believe this to be so. I will check it out when I get a chance.