|
OK, got it sorted but it was a bit more involved than first thought, so for the benefit of others, here's the gig:
1. Create new field in CB - Make sure that what every you want the field to be you finish the name with 'name', for example, if you wanted to be followed on google, rather than putting google into the field name box you need to put in googlename as the stalker.php looks for fields ending with name, forget this and it doesn't work.
You'll note that Community Builder has already added cb_ infront of this, this is where the main problem lies as i found
2. Edit the stalker.php and stalker.xml files, there are 3 edits you'll need to make.
Within the php file you'll need to duplicate a block of text that looks like this:
array ("youtube", "YouTube", "http://youtube.com/#id#", "youtube.png"),
And then edit the various bits to represent your new icon parameters.
Within the xml file you'll need to duplicate the following and apply edits as required:
Your icon name and location.
<filename>images/youtube.png</filename>
The code for said icon in CB (please note point 3 below):
<field name="st_youtubename" type="text" default='' title="YouTube Username" description="Enter your YouTube username" registration="0" readonly="0" profile="0" />
3. IGNORE the name you were given by CB for the field, by default it will have become cb_googlename, that won't work as the stalker.php file looks for st_ prefixed fields! So, where in the above code you'd expect to replace st_youtubename with cb_googlename use st_googlename instead.
4. FTP the files and the new icon to your server.
5. Open PHPmyadmin and find your newly created field, open them and edit the cb_ prefix to st_ and make sure that they are indicated as being part of the stalker plugin by editing the plugin number.
6. Go to the CB field manager and open the fields, they will show that they have been changed to an st_ prefix, but unless you open them and then save them in the CB backend they don't seem to work properly on the front end.
It may look complicated but it really isn't and you should have your new icon working in about 5 - 10 minutes
Hope that helps someone along the way |