PDA

View Full Version : Adding fieldX wrapped within usergroup markup


harmor19
05-10-2009, 02:01 AM
I'm trying to place $post[fieldx] inside the tags from the usergroup markup.

I've tred...

$post[opentag] Field $post[closetag]

$postinfo[opentag] Field $postinfo[closetag]

but they won't work.

Lynne
05-10-2009, 02:18 AM
I don't understand where you are trying to put that - where are the "tags from the usergroup markup"?

harmor19
05-10-2009, 03:52 AM
When you go into the ACP and manage usergroups you can set what markup you want for an usergroup.

--------------- Added 1241959326 at 1241959326 ---------------

I had to write a plugin. I'll post the XML code.

<?xml version="1.0" encoding="ISO-8859-1"?>

<plugins>
<plugin active="1" executionorder="5" product="vbulletin">
<title>Colored Clan Tags</title>
<hookname>postbit_display_start</hookname>
<phpcode><![CDATA[global $db;

$clantag = $db->query_first("SELECT opentag,closetag FROM " . TABLE_PREFIX . "usergroup WHERE usergroupid = '".$post['usergroupid']."' ");

$opentag = $clantag['opentag'];
$closetag = $clantag['closetag'];]]></phpcode>
</plugin>
</plugins>