Quote:
Originally Posted by thesatman
thanks for your help it was because the database as 2 tables caleed extension so i had to use-
WHERE attachment.extension = 'mid'
1 more small problem i need to use the following in the above-
$credit_filetypes = explode(',', $vbulletin->options['creditsys_filetypes']);
with-
WHERE attachment.extension = $credit_filetypes
But when i test it, i just get-
WHERE attachment.extension = array
so its not displaying what its taken from the explode ?? how would i do this ?
Thanks
Chris.
|
Explode turns a delimited string into an array. If $vbulletin->options['creditsys_filetypes'] is already a delimited string then you don't need to do anything but stick it in the query with an IN clause.
$sqlwhere = "WHERE attachment.extension IN(" . $vbulletin->options['creditsys_filetypes'] . ")";