PDA

View Full Version : How do I add another table to Index page?


mattmcc
07-31-2009, 04:20 PM
I'm new to vBulletin so this may be easy.

I'm trying to make a Product and as part of this product want to add another table on the forum's index page below all the forums. This wouldn't be a forum but would have the same style as the other tables with a link to another page with the Product functionality.

I figured I would need to create a plugin for this but I'm having trouble figuring out how I can insert code into the FORUMHOME template below the forums list. Is there a way to do this?

Edit: Ok, I found $ad_location[ad_forumhome_afterforums] which seems to be what I'm looking for. If I ad a plugin at the hook "forumhome_complete" with the code of
$ad_location[ad_forumhome_afterforums] = "<table...my table code ...</table>' . $ad_location[ad_forumhome_afterforums];

is that considered a bad way to do it? Or is there a better way?

Lynne
08-01-2009, 12:53 AM
The template hooks are there for adding code through plugins, so that is fine to do it that way. If you are releasing the mod, you may want to include instructions on how to add the template hook manually in case their version of vbulletin doesn't have them.

mattmcc
08-06-2009, 03:40 PM
Thanks Lynee. That is a good idea.