New Friend Request

I was reading up on some things but im still lost...if anyone can help I would appreciate it.  Here is what I found. Im trying to create a box to display when I receive new friend requests.  This is an email version but i assume friend request would be the same.

 

2. Example of using the `PopupMenu` field
     *        - assume you need to create a `News` menu item and create a drop-down block in it which would display some information.
     *              To do so, you first need to run an SQL query which will insert data into the appropriate fields:
     *            ...`Caption` = '_News', `Link` = 'news.php'... and then specify some code in the `PopupMenu` field which will create the contents of the current menu:
     *             
     *              //example of PHP code into `PopupMenu` field; 
     *               require_once('News.php');
     *               return getNewsSubMenu();
     *                  
     * 3. Example of using the `Bubble` field (system notifiers)
     *      - assume you need your menu item to display the number of mails in real time (i.e. if someone has written you a mail, you would be notified immediately),
     *      to do so, you need to create a menu item as in the previous example and create a function in the `Bubble` field which will request the mail script for any changes:
     *
     *       bx_import('BxTemplMailBox');
     *       // return list of new messages ;
     *       $aRetEval= BxTemplMailBox::get_member_menu_bubble_new_messages({ID}, {iOldCount});
     *
     *       where $aRetEval is an array which will be processed  (it shouldn't be renamed!!!)
     *       the first parameter {ID} is Profile's ID, the second parameter is the number of mails retrieved during the previous iteration.
     *      
     *       the function will return an array looking like this:
     *
     *           $aRetEval = array(
     *               'count'     => $iNewMessages,
     *               'messages'  => $aNotifyMessages,
     *           );
     *          
     *       where 'count' is the whole number of mails, 'messages' is an array of messages;
     *       @see BxTemplMailBox::get_member_menu_bubble_new_messages;

Quote · 11 Nov 2010

You can find this module on unity's market

PS: If possible do not write me personally, please try to ask on the forum first
Quote · 11 Nov 2010

I dont want to buy all that stuff..I would like to design it myself than put it on the market for free as a mod

Quote · 11 Nov 2010

 

You can find this module on unity's market

SashaE, what is the name of the relevant mod, i would like to take a gander at it.

When a GIG is not enough --> Terabyte Dolphin Technical Support - Server Management and Support
Quote · 11 Nov 2010

whats   the mod name??

 

i need a block to show uses   friends requests   when tthey  login

i cant find anything  like this in the  market

 

Quote · 5 Jun 2012

Maybe this one... http://www.boonex.com/forums/topic/Friend-Request-2011-03-11.htm

http://pkforum.dolphinhelp.com
Quote · 5 Jun 2012

$iProfileID = getID( $_GET['ID'] );
$oDb = new BxDolDb();
$aCount = db_arr("SELECT COUNT(*) FROM `sys_friend_list` WHERE `Profile` = '$iProfileID' AND `Check` = 0 ");
if($aCount[0]>0){
$sText = ($aCount[0]>1) ? _t('_pending_frs',$aCount[0]) : _t('_pending_fr',$aCount[0]);
$sMsg='<table><tr bgcolor="#606060"><td><a href="' . $site['url'] . '/communicator.php">' . $sText . '</a></td></tr></table>';
echo $sMsg;
$query="SELECT *,UNIX_TIMESTAMP( `sys_friend_list`.`When`) AS 'When_UTS' FROM `sys_friend_list` WHERE `Profile` = '$iProfileID' AND `Check` = 0";
$Requests=db_res($query);
$sReturn='';
while ($eachrequest = mysql_fetch_array($Requests))
{
$sNickName = getNickName($eachrequest['ID']);
$sReturn .= '<div class="browse_thumb" style ="float:left;margin:0 0 10px; overflow:hidden; width:122px; position:relative;">'.get_member_thumbnail($eachrequest['ID'], 'left', true ).'<div style="float:left;"> '.getLocaleDate($eachrequest['When_UTS'],BX_DOL_LOCALE_DATE_SHORT).'</div></div>';
}
echo $sReturn;
}

the 2 language keys are

'_pending_frs' => 'You have {0} pending friend requests. Mouse over for options, or click to view profile.'

'_pending_fr'=> 'You have {0} pending friend requests. Mouse over for options, or click to view profile.'

 

I got this from an article some time ago and  just cleaned it up somewhat.

 

Also, if you have NO friend requests, it does not show up!  I have this as the top block on my home page.

http://www.mytikibar.com
Quote · 5 Jun 2012

 

$iProfileID = getID( $_GET['ID'] );
$oDb = new BxDolDb();
$aCount = db_arr("SELECT COUNT(*) FROM `sys_friend_list` WHERE `Profile` = '$iProfileID' AND `Check` = 0 ");
if($aCount[0]>0){
$sText = ($aCount[0]>1) ? _t('_pending_frs',$aCount[0]) : _t('_pending_fr',$aCount[0]);
$sMsg='<table><tr bgcolor="#606060"><td><a href="' . $site['url'] . '/communicator.php">' . $sText . '</a></td></tr></table>';
echo $sMsg;
$query="SELECT *,UNIX_TIMESTAMP( `sys_friend_list`.`When`) AS 'When_UTS' FROM `sys_friend_list` WHERE `Profile` = '$iProfileID' AND `Check` = 0";
$Requests=db_res($query);
$sReturn='';
while ($eachrequest = mysql_fetch_array($Requests))
{
$sNickName = getNickName($eachrequest['ID']);
$sReturn .= '<div class="browse_thumb" style ="float:left;margin:0 0 10px; overflow:hidden; width:122px; position:relative;">'.get_member_thumbnail($eachrequest['ID'], 'left', true ).'<div style="float:left;"> '.getLocaleDate($eachrequest['When_UTS'],BX_DOL_LOCALE_DATE_SHORT).'</div></div>';
}
echo $sReturn;
}

the 2 language keys are

'_pending_frs' => 'You have {0} pending friend requests. Mouse over for options, or click to view profile.'

'_pending_fr'=> 'You have {0} pending friend requests. Mouse over for options, or click to view profile.'

 

I got this from an article some time ago and  just cleaned it up somewhat.

 

Also, if you have NO friend requests, it does not show up!  I have this as the top block on my home page.

Thanks

 


Quote · 6 Jun 2012

Let me know if you use this, or send me a screen shot if you have it looking really cool.

 

Cool

http://www.mytikibar.com
Quote · 6 Jun 2012
 
 
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.