hello to everyone, I wanted to add the heading "On-line chatting" to MEMBERS module on homepage, I added the following items in bold, but I get an error in mod ... Some may give a look?
file: templates/base/scripts/BxBaseIndex.php
------from the line: 366 onwards ----------
// Get Sex from GET data
if ( $_GET['Sex'] && $_GET['Sex'] != "all" ) {
$sex = process_db_input( $_GET['Sex'] );
$query_add = " AND `Sex` = '$sex'";
} else {
$sex = "all";
$query_add = "";
}
$query_add .= ' AND (`Couple`=0 OR `Couple`>`ID`)';
$query = "
SELECT
`Profiles`. `Raychatcurrentuser`.*
";
if ( $_GET['members_mode'] == 'online' or
$_GET['members_mode'] == 'rand' or
$_GET['members_mode'] == 'last' or
$_GET['members_mode'] == 'chat' or
$_GET['members_mode'] == 'top' )
$mode = $_GET['members_mode'];
else
$mode = 'last';
$aDBTopMenu = array();
//$menu = '<div class="dbTopMenu">';
foreach( array( 'last', 'top', 'online', 'rand', 'chat' ) as $myMode )
{
switch ( $myMode )
{
case 'online':
if( $mode == $myMode )
$filter = " FROM `Profiles` WHERE `DateLastNav` > SUBDATE(NOW(), INTERVAL ".(int)getParam( "member_online_time" )." MINUTE) AND `Status` = 'Active' $query_add ORDER BY `Couple` ASC";
$modeTitle = _t('_Online');
break;
case 'rand':
if( $mode == $myMode )
$filter = " FROM `Profiles` WHERE `Status` = 'Active' $query_add ORDER BY `Couple` ASC, RAND()";
$modeTitle = _t('_Random');
break;
case 'chat':
if( $mode == $myMode )
$filter = " FROM `Raychatcurrentusers` WHERE `Online` = 'online'" ;
$modeTitle = _t('_chat');
break;
case 'last':
if( $mode == $myMode )
$filter = " FROM `Profiles` WHERE `Status` = 'Active' $query_add ORDER BY `Couple` ASC, `DateReg` DESC";
$modeTitle = _t('_Latest');
break;
case 'top':
if( $mode == $myMode )
{
$oVotingView = new BxTemplVotingView ('profile', 0, 0);
$aSql = $oVotingView->getSqlParts('`Profiles`', '`ID`');
$sqlOrderBy = $oVotingView->isEnabled() ? " ORDER BY `Couple` ASC, (`pr_rating_sum`/`pr_rating_count`) DESC, `pr_rating_count` DESC, `DateReg` DESC" : $sqlOrderBy ;
$sqlFields = $aSql['fields'];
$sqlLJoin = $aSql['join'];
$filter = "$sqlFields FROM `Profiles` $sqlLJoin WHERE `Status` = 'Active' AND `pr_rating_count` > 2 $query_add $sqlOrderBy";
$filter2 = " FROM `Profiles` $sqlLJoin WHERE `Status` = 'Active' AND `pr_rating_count` > 2 $query_add $sqlOrderBy";
}
$modeTitle = _t('_Top');
break;
}
------------------------------------
the voice comes up, but when we click above, instead of leaving users me this:
Warning: mail () [function.mail]: Failed to connect to mailserver at "localhost" port 25, verify your "SMTP" and "smtp_port" setting in php.ini or use ini_set () in D: \ xampp \ htdocs \ dol \ inc \ utils.inc.php on line 422
-------------------------------------
another thing I noticed is that the values of tables db RayChatRoomsUsers
always remain empty ...