The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#41
|
||||
|
||||
So do I need to create a separate layout for these pages to basically have a static page widget in there?
|
#42
|
||||
|
||||
Back from the dead, I found this code in an old post on vb.com, but it doesn't seem to work. It should add the author's avatar to the templater and allow me to use it on the article and preview templates, however it is only showing my avatar, not the avatar of the article author. Note: this is only on previews. When I view an article itself, the correct avatar shows.
(Figured I'd use this thread since it is still relevant). PHP Code:
And another question, I see that I can choose sections to display on a page, but there isn't an option to only show articles from a certain category within that section. Is this intended or am I using the wrong widget in the layout? And one last question, the CMS preview tries to pull an image for the "preview" of the article, and then disables any images in the post from showing in it. Can I turn this off and allow the previews to show the images? |
#43
|
||||
|
||||
Friendly bump. The most pertinent question is the code I provided for the avatar. ^^ Everything else can be worked around I suppose. ^^
|
#44
|
||||
|
||||
What hook are you using?
|
#45
|
||||
|
||||
vbcms_article_populate_end
I read somewhere this was the appropriate hook. |
#46
|
||||
|
||||
It seems to work correctly on my test install. Maybe another plugin is interfering?
|
#47
|
||||
|
||||
On the previews it shows other people's avatars? It works for me, however only my avatar appears, even if I am not the author of the article.
|
#48
|
||||
|
||||
Two authors:
string 'image.php?u=2&dateline=1420404720&type=th umb' (length=52) string 'image.php?u=1&dateline=1420403212&type=th umb' (length=52) string 'image.php?u=1&dateline=1420403212&type=th umb' (length=52) string 'image.php?u=1&dateline=1420403212&type=th umb' (length=52) string 'image.php?u=1&dateline=1420403212&type=th umb' (length=52) string 'image.php?u=1&dateline=1420403212&type=th umb' (length=52) string 'image.php?u=1&dateline=1420403212&type=th umb' (length=52) --------------- Added [DATE]1420421196[/DATE] at [TIME]1420421196[/TIME] --------------- I lied. Somehow it got changed going into the template. --------------- Added [DATE]1420421442[/DATE] at [TIME]1420421442[/TIME] --------------- This worked for me: PHP Code:
|
#49
|
||||
|
||||
Will try.
Edit: it works, thanks. Could you explain why your change worked so I can know for future reference? My guess is that pre-registering only did the value of one thing and once that value was registered any change afterward will affect the variable? Any help on the additional questions would be appreciated (from anyone). Thanks for the help! |
#50
|
||||
|
||||
Quote:
I didn't track your code back to see why the values were being changed, so I don't know why it wasn't working correctly. |
Благодарность от: | ||
KGodel |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|