Skype, MSN, Yahoo

Hi all .. other than a widget, is there a way to get skype, yahoo and MSN status into a users profile ?, please could someone help here, tis fairly critical

Quote · 7 Oct 2008

This was posted in another thread - I have tried it out on my site ConnectionSquare.net and it works - feel free to test it out on my site before using Ottar's wonderful code.

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

Quote · 7 Oct 2008

Quote · 7 Oct 2008

Are your DB on localhost?

 

and use romancee_DATABASE_USER and romancee_DATABASE_NAME

 

$my_dbHost="localhost";
$my_dbLogin="DATABASE_USER";
$my_dbPass="DATABASE_PASSWORD";
$my_db="DATABASE_NAME";

 

 

and if you have changed something, you can't use " without \ before, you will then have a database error!!

 

Ottar.

 

Quote · 7 Oct 2008

Rather obvious but did you verify that you have the correct user name? By the way, I saw a similar procedure used on another site and they also allowed Gtalk - through Jabber - does anyone know how this code could be modified to allow for Gtalk?

-

Rob

Quote · 7 Oct 2008

Ok, so if for example     database is    romancee_dolphin     username is richard_dolphin   and pass is whatever

would I then edit field to look like this?

<p>

$my_dbHost="localhost";
$my_dbLogin="romancee_dolphin_richard";
$my_dbPass="whatever";
$my_db="romancee_dolphin_romancee";

</P>

Regards

Richard

Quote · 7 Oct 2008

edited, you are getting better help than I could give

Quote · 7 Oct 2008

Are your DB on localhost?

and use romancee_DATABASE_USER and romancee_DATABASE_NAME

$my_dbHost="localhost";
$my_dbLogin="DATABASE_USER";
$my_dbPass="DATABASE_PASSWORD";
$my_db="DATABASE_NAME";

and if you have changed something, you can't use " without \ before, you will then have a database error!!

Ottar.

Okweb, thanks for the help so far, ok, could you please just expain the   /   issue to me  ?

Thank

Quote · 7 Oct 2008

Also .. does it matter what version of Dolphin i run as to whether this code will run?

I'm using 6.1.4

Thank

Quote · 7 Oct 2008

 

 

 

Okweb, thanks for the help so far, ok, could you please just expain the   /   issue to me  ?

 

if you add code,

 

Wrong: <td class="profile_info_label">Skype Status:</td>

Correct: <td class=\"profile_info_label\">Skype Status:</td>

 

Dol.6.1.2 and 6.1.4, work in both.

 

(What I have installed now)

---------

 

Ok, so if for example     database is    romancee_dolphin     username is richard_dolphin   and pass is whatever

 

would I then edit field to look like this?

 

<p>

$my_dbHost="localhost";
$my_dbLogin="romancee_dolphin_richard"; <- WRONG
$my_dbPass="whatever";
$my_db="romancee_dolphin";

 

I think this is correct!!

 

Ottar.

 

UPDATE:

$my_dbLogin="romancee_richard_dolphin"; <- CORRECT

Sorry!!

Ottar

@justinlutzfl

Thanks

Quote · 7 Oct 2008
You said your username was richard_dolphin not romancee_dolphin_richard that is $my_dbLogin="your database user name here";
Quote · 7 Oct 2008

Okweb, thanks for the help so far, ok, could you please just expain the   /   issue to me  ?

if you add code,

Wrong: <td class="profile_info_label">Skype Status:</td>

Correct: <td class=\"profile_info_label\">Skype Status:</td>

Dol.6.1.2 and 6.1.4, work in both.

(What I have installed now)

---------

Ok, so if for example     database is    romancee_dolphin username is richard_dolphin and pass is whatever

would I then edit field to look like this?

<p>

$my_dbHost="localhost";
$my_dbLogin="romancee_dolphin_richard";
$my_dbPass="whatever";
$my_db="romancee_dolphin";

I think this is correct!!

Ottar.

Grrrrrr, Still not working Ottar, I've sent you a privat email ... thanks bro!

Quote · 7 Oct 2008

if your username is richard_dolphin

it should look like this:


.

$my_dbHost="localhost";
$my_dbLogin="richard_dolphin";
$my_dbPass="whatever";
$my_db="romancee_dolphin";

Quote · 7 Oct 2008

 

if your username is richard_dolphin

 

it should look like this:


.

$my_dbHost="localhost";
$my_dbLogin="richard_dolphin";
$my_dbPass="whatever";
$my_db="romancee_dolphin";

 @justinlutzfl

Yes, that's it, sent he PM a couple minutes ago, thanks to your help.

Ottar.

 

Quote · 7 Oct 2008

Thank you Ottar for posting such a great mod

I am fixing to put up my first mod and I hope that you see it, as I think you could improve on it way further than what I have already done.

I will name the thread "Adding Social Bookmarks to Your Users Blogs"

Quote · 7 Oct 2008

Hi guys

Ok, did as stated, to the letter ...   however, it still aint working... this is driving me nuts!!

Please put me outta my pain!    lol

Thanks

error


Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'richard_dolphin'@'localhost' (using password: YES) in /home/romancee/public_html/inc/classes/BxDolPageView.php(281) : eval()'d code on line 8
Couldn't connect to the server.

Quote · 7 Oct 2008

It would make sense that the database name is now wrong as the error appears on line 8 instead of line 6, ensure that you have the correct name. To verify it go to phpmyadmin and look at the name

Quote · 7 Oct 2008


Regards and thanks for help thus far guys! you are great


Richard
Quote · 7 Oct 2008

I hope you don't have to forgot this:

 

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.

Ottar


and if you have do it, then

 

YOUR USERNAME IS WRONG

(Testet it, error like yours)

Quote · 7 Oct 2008

yep I had to do that as well -

Go to Admin/Builders/Pages Builder and move the block that you created this under, then move it back

Go back out of admin and refresh the page

Quote · 7 Oct 2008

I hope you don't have to forgot this:

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.

Ottar


and if you have do it, then

YOUR USERNAME IS WRONG

(Testet it, error like yours)

yes I did do it ....

Nadda!

Quote · 7 Oct 2008

I hope you don't have to forgot this:

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.

Ottar


and if you have do it, then

YOUR USERNAME IS WRONG

(Testet it, error like yours)

yes I did do it ....

Nadda!

Is there something I may be missing here ??

IMPORTEN: After edit/save table 'Content' inside DB,

is there a specific save table button ??

Sorry to be so dim!

Richard

Quote · 7 Oct 2008

Hi again

No, I think you have do it correct, but your username is wrong.

Sometimes you need to use both your username at your host and your username to DB.

So if your host username is romancee and your username to DB is richard_dolphin

you can use romancee_richard_dolphin as your dbLogin

When you have savet it in phpMyAdmin,

go to Admin/Builders/Pages Builder -> Profile and move the block down a bit and drop it, and then move it back where you will have it.

Then refresh your website. (or go to another site and back again)

 

Ottar.

Quote · 7 Oct 2008

BRILLAINT!!  Ok, I deleted everything I did and started all over again .. thanks to your genius brains .. I got it going !!   WELL DONE and THANKS

Regards and best wishes

Sleep tight .. tis 2am here !!

Richard

Quote · 8 Oct 2008

 

BRILLAINT!!  Ok, I deleted everything I did and started all over again .. thanks to your genius brains .. I got it going !!   WELL DONE and THANKS

 

Regards and best wishes

 

Sleep tight .. tis 2am here !!

 

Richard

 

Great, it's 02.10 here..

 

Cheers,

Ottar.

Quote · 8 Oct 2008

Just wanted to say a big thanks to you guys that helped me here, I'm more awake now and am chuffed to have got this working ..

Regards

Richard

Quote · 8 Oct 2008

Here we go again!! Who ever posted the link to there cpanel login might think about removing it. Not only is it annoying you are pretty much asking for trouble but that is up to you.

DialMe.com - Your One and Only Source For Boonex Dolphin Tutorials and Resources
Quote · 8 Oct 2008

Here we go again!! Who ever posted the link to there cpanel login might think about removing it. Not only is it annoying you are pretty much asking for trouble but that is up to you.

it's probably my fault to be fair .. how do I delete ?

Thanks

Quote · 8 Oct 2008

It is the cpanel for your site Rich

it looks like it's in the 3rd overall post of this thread, your first reply to me.

Click edit on that post and remove your error code

Quote · 8 Oct 2008

It is the cpanel for your site Rich

it looks like it's in the 3rd overall post of this thread, your first reply to me.

Click edit on that post and remove your error code

Thanks Bro !

Richard

Quote · 8 Oct 2008

Delete everything above in this thread, your pic is url linked to your cpanel

 

 

Copied from MyPHP header

It's a wierd one indeed!

Hope we can get this working!

Regards and thanks for help thus far guys! you are great


Richard
--------------------
Ottar
Quote · 8 Oct 2008

ok, looks like that worked!

Thanks Ottar

Quote · 8 Oct 2008

Still don't know if Google Talk can be added to this code through jabber, but in doing a little research I found this cool little applet and thought I would share it here.  It is called a "Google talk chatback badge" and lets you put a chat box on your webpage that allows your visitors to chat with you even if they don't use Google Talk.  http://www.google.com/support/talkgadget/bin/answer.py?hl=en&answer=86171

-

Rob

Quote · 9 Oct 2008

I tried doing this and got lost at the adding language strings - anyone kind enough to explain that in a bit more detail for a novice like me


Thank

Quote · 10 Oct 2008

I also get this error when I update in the database

UPDATE `"mydatabase name here"`.`PageCompose` SET `Caption` = '_Contact Information' WHERE `PageCompose`.`ID` =91 LIMIT 1 ;

Quote · 10 Oct 2008

Do you really do what I write here:

 

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

 

 

 

and wich Dol. Version do you use!!

Ottar

Quote · 10 Oct 2008

HI Ottar - I have version 6.1.4 - I followed instructions as you said and changed my DB username, etc to my site.  This is a huge learning curve for me and I am trying all these things on a 'dummy' site before I do any changes to my main site.  So far, I feel really stupid as I don't seem to get anything right LOL.  But I will keep trying - there is a lot of information and very helpful people here so hoefully I will eventually succeed.

Thanks

Quote · 10 Oct 2008

@ Ottar - do you know what code to use for MSN status or I guess it's called windows live messenger status now. I can't figure that one out - It seems my users may have to do something through windows live site for their status to be available? In other words each user would have a unique string of code to add to the site to obtain their status.

.

.

.

@ Dartin - take your time with it and follow every step exactly. It will work as you saw on my site. I didn't do anything different than what Ottar said in his original post.

Quote · 10 Oct 2008

LOL Justin - what you don't know is that I have no clue what I am doing LOL   I did eventually manage to get my yahoo to show on the profile page, could not get the URL of the website to show (and I did not add the http:// when I entered the info)  Still getting some error after posting the info in the DB, and still cant get rid of the underscore before the Contact Information name.

I am going to throw the database problem at my son, he doesn't know Dolphin but perhaps can figure out what I have done wrong (didn't send him to college for 4 years to qualify as a computer major for nothing... payback time !!)

Thanks for the help

Quote · 10 Oct 2008

if you want to go on msn I am online - you should also post the exact error you are currently experiencing

Quote · 10 Oct 2008

Thanks Justin - I finally found an error, I had written websites on one and website on another.  Fixed that and my link showed up.  Still can't figure why I have an Underscore before the name on the block heading.  Found another thread relating to that so working my way through there.

I must thank you and the other members for your willingness to help members like myself who are novices .

Quote · 10 Oct 2008

You need to compile your language files

admin -> settings -> languages -> under your language select compile

-----------------------------------------------

you may also need to go to the individual fields that you created using the search function and edit those

Quote · 10 Oct 2008

I'm trying to do this in Dolphin 7.0.3 everything seams ok but I'm getting theis error

 

Couldn't select a database.

This is the code I putting in the database I've XXX out the login info, is there something different in the coode that should be changed in 7.0.3

 

$profileID = getID( $_REQUEST['ID'] );

$my_dbHost="localhost";
$my_dbLogin="XXX";
$my_dbPass="XXX";
$my_db="XXX ";

$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);

Quote · 4 Nov 2010
 
 
Below is the legacy version of the Boonex site, maintained for Dolphin.Pro 7.x support.
The new Dolphin solution is powered by UNA Community Management System.