MyBB Hacks

Full Version: how do i bring the Xthread field into the portal?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
how do i bring the Xthread field into the portal? with the standard portal announcement?

Quote:{$GLOBALS['threadfields']['post_image']}
With the standard portal announcement, should be the same as in forumdisplay_thread, showthread and postbit/_classic
i am sorry can you be more specific?

{$GLOBALS['threadfields']['post_image']}

the standard calls dont work, portals are using

{$announcement['subject']}
Assuming the post_image is an image custom thread field, there is an explanation under the Input Field Type setting when you create or edit the custom field.

The basic usage is by using {$GLOBALS['threadfields']['key']['item']} variable. Replace the key to your Key (in your case is post_image and the item with one of the list in the explanation.
So, for example, if you want to get the image url, you can use {$GLOBALS['threadfields']['post_image']['url']} or if you want to get the Display Format of the field, you can use {$GLOBALS['threadfields']['post_image']['value']}

But if the field accept multiple images, the format is slightly different (you can also find the explanation about it under the Input Field Type setting).
i am using it in forumdisplay

{$GLOBALS['threadfields']['post_image']}

and it give me the url without my having to add the ['url']

i tried it in the portal and nothing come up....please add more info thanks
What is the type of the field?
just a basic text field

i render the image in the templates

Code:
<img src="{$GLOBALS['threadfields']['post_image']}" alt="" title="Click to enlarge" width="100px" height="50px" />

For temporary solution, try to select any forum(s) in Forums to pull announcements from setting (choose Select forums, then select any forum(s) there) instead of choosing All Forums.
Ohh i am also using force to portal plugin to force just some posts into the portal if that helps
If the plugin uses its own templates or query, then you rely to the plugin.
Pages: 1 2
Reference URL's