The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
||||
|
||||
Using str_replace() to modify query, is it possible?
In newattachment.php i want to modify the following query:
[SQL] SELECT dateline, filename, filesize, attachmentid, IF(thumbnail_filesize > 0, 1, 0) AS hasthumbnail FROM " . TABLE_PREFIX . "attachment WHERE postid = $postid ORDER BY attachmentid [/SQL] so it becomes this: [SQL] SELECT dateline, filename, filesize, attachmentid, IF(thumbnail_filesize > 0, 1, 0) AS hasthumbnail FROM " . TABLE_PREFIX . "attachment WHERE scst_usedin = 'fbid' AND scst_itemid = '" . $feedback['fbid'] . "' ORDER BY attachmentid [/SQL] The problem is that there's no hook in newattachment.php which allows me to alter the query, so I'm thinking it's possible to place a plugin at hook: GLOBAL_START like this: PHP Code:
thanks! |
#2
|
||||
|
||||
bump, anyone please?
|
#3
|
|||
|
|||
I would not know of a way to do that.
(other then acutally editing the php-file.) |
#4
|
||||
|
||||
damn, it looks like that's the way I might have to go. I was really hoping to avoid that though. If anyone does know of a way, still, please let me know.
|
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|