Hi Rob
Code to display a link/Skype button and more, as we talk about...
Go to Admin/Builders/Fields Builder and Join Form:
Add NEW BLOCK, click on it and write as bellow
Name: Contact Information
Caption: Contact Information
Description:
Join Page: 0
SAVE
===============================
Add NEW ITEM and drop it bellow your NEW BLOCK(Contact Information), click on it and write as bellow
General area,
Name: SkypeStatus
Caption: Skype Status
Description: Your Skype ID
Type: Text
Advanced area,
Maximum value: 15
SAVE
===============================
Add NEW ITEM and drop it bellow your new Item 'SkypeStatus', click on it and write as bellow
General area,
Name: YahooStatus
Caption: Yahoo Status
Description: Your Yahoo username
Type: Text
Advanced area,
Maximum value: 40
SAVE
===============================
Add NEW ITEM and drop it bellow your new Item 'YahooStatus', click on it and write as bellow
General area,
Name: ICQStatus
Caption: ICQ Status
Description: Your ICQ username
Type: Text
Advanced area,
Maximum value: 40
SAVE
===============================
Add NEW ITEM and drop it bellow your new Item 'ICQStatus', click on it and write as bellow
Name: Website
Caption: Website
Description: Your website name, WITHOUT http://
Type: Text
SAVE
===============================
Click on Edit Profile
---------------------
- Move new BLOCK Contact Information to active area
- Move new item SkypeStatus to active area and drop it bellow your new block 'Contact Information',
do the same with item YahooStatus, ICQStatus and Website.
(Do this for Owner and Admin)
=============================================
DON'T USE THIS Block or Items ON View Profile
=============================================
Go to Pages Builder, click on Profile and move your new block Contact Information and drop it bellow General Info
===============================
Go to phpMyAdmin and click on table PageCompose, find your new block (_FieldCaption_Contact Information_View) and click edit,
Edit Desc from 'Profile Fields Block' to Contact Information
Edit Func from 'PFBlock' to PHP
Edit Content: (delet the number you have there, '60' or something) and past code bellow to this area:
DON'T forget to change: DATABASE_USER, DATABASE_PASSWORD and DATABASE_NAME
==========================================================================
$profileID = getID( $_REQUEST['ID'] );
$my_dbHost="localhost";
$my_dbLogin="DATABASE_USER";
$my_dbPass="DATABASE_PASSWORD";
$my_db="DATABASE_NAME";
$connection=mysql_connect("$my_dbHost","$my_dbLogin","$my_dbPass") or die("Couldn't connect to the server.");
$db=mysql_select_db("$my_db", $connection) or die("Couldn't select a database.");
$sql="SELECT * FROM Profiles WHERE ID='$profileID'";
$sql_result=mysql_query($sql,$connection) or die("Couldn't execute query!");
$res=mysql_fetch_array($sql_result);
$SkypeStatus=$res["SkypeStatus"];
$YahooStatus=$res["YahooStatus"];
$ICQStatus=$res["ICQStatus"];
$Website=$res["Website"];
echo "<div class=\"boxContent\">";
echo "<table class=\"profile_info_block\" cellspacing=0 cellpadding=1>";
if( strlen($SkypeStatus) > 0 )
{
echo "<tr>
<td class=\"profile_info_label\">Skype Status:</td>
<td class=\"profile_info_value\" >
<script type=\"text/javascript\" src=\"http://download.skype.com/share/skypebuttons/js/skypeCheck.js\"></script>
<a href=\"skype:$SkypeStatus?chat\">
<img src=\"http://mystatus.skype.com/smallicon/$SkypeStatus\" style=\"border: none;\" width=16 height=16 alt=\"My status\"></a></td></tr>";
}
if( strlen($YahooStatus) > 0 )
{
echo "<tr><td class=\"profile_info_label\">Yahoo Status:</td>
<td class=\"profile_info_value\">
<a href=\"ymsgr:sendIM?$YahooStatus\" target=\"_blank\">
<img border=0 src=\"http://opi.yahoo.com/online?u=$YahooStatus&m=g&t=0\"></a>
</td></tr>";
}
if( strlen($ICQStatus) > 0 )
{
echo "<tr><td class=\"profile_info_label\">ICQ Status:</td>
<td class=\"profile_info_value\" >
<a href=\"http://people.icq.com/people/about_me.php?uin=$ICQStatus\" target=\"_blank\"><img src=\"http://status.icq.com/online.gif?web=$ICQStatus&img=21\" width=57 height=15></a></td></tr>";
}
if( strlen($Website) > 0 )
{
echo "<tr><td class=\"profile_info_label\"><br />My website:</td>
<td class=\"profile_info_value\" ><br />
<a href=\"http://$Website\" target=\"_blank\"><b>$Website</b></a>
</td></tr>";
}
if( strlen($SkypeStatus) < 1 AND strlen($YahooStatus) < 1 AND strlen($ICQStatus) < 1 AND strlen($Website) < 1)
{
echo "<tr><td class=\"profile_info_label\"></td><td class=\"profile_info_value\" ><b>No contact information available</b></td></tr>";
}
echo "</table>";
echo "</div>";
mysql_close($connection);
====
SAVE it
===============================
Go to Admin/Builders/Pages Builder and move block 'Contact Information'
IMPORTEN: After edit/save table 'Content' inside DB,
you ALWAYS have to move block in Pages Builder some before it will show last edit you do.
===============================
Go to Settings/Languages settings and add nessesarry languages strengs on Join, Edit and View Profile pages..
===============================
Log in as a user and edit your profile data on Skype/Yahoo/ICQ Status and My website,
view your profile and you will now see a new block with you information inside.
Cheers,
Ottar