Really Need Help!

I am getting the following error:

 

Parse error: syntax error, unexpected ';', expecting ')' in /home/maburker/public_html/inc/prof.inc.php on line 400

We tried to add a status function but, we think it's for the wrong version. We did the foolowing in mysql

 

ALTER TABLE `Profiles` ADD `Emotional_State` VARCHAR( 255 ) NOT NULL AFTER `Tags` ;
ALTER TABLE `Profiles` ADD `Current_Status` VARCHAR( 255 ) NOT NULL AFTER `Tags` ;

 

Where can we look to undo it. Site is down and need to fix it. Any ideas please let me know thanks.

Quote · 4 Aug 2009

Well, you could go to inc/prof.inc.php and look for the erroneous semi colon, that would be good start.  Check the code that you added and make sure you got all of it, it's easy when copy/pasting in mods to miss a small item or put more in a place than your supposed to.

 

Curious, since your adding this to 6.1.6 site, what is the specific mod (url please) that your attempting to install.  Someone here might have the answer for you if we know what your trying to do exactly.

Quote · 4 Aug 2009

We have deleted the semicolons. Still nothing. Is it because we changes the tables like I mentioned in the first post. We didn't realize that the mod wasn't for the version that we have. It's a free mod for the Emoticon Status update.

Quote · 4 Aug 2009

FRSAdmin, I can't answer your question unless I can see what you have.  I understand it's a free mod for emoticon status, but that means I have to go hunt all over the world for it, if you can provide the link where you got it that would be great, then it can be looked at and we can help you fix this.  

 

 

Quote · 4 Aug 2009

Maybe this will help. It's a free mod and I can't seem to find it on expertzzz right now. Below is the instructions on how to implement it. We converted everything back and now we're trying to convert the sql to the original format.

 

EXECUTE the following MYSQL script:


ALTER TABLE `Profiles` ADD `Emotional_State` VARCHAR( 255 ) NOT NULL AFTER `Tags` ;
ALTER TABLE `Profiles` ADD `Current_Status` VARCHAR( 255 ) NOT NULL AFTER `Tags` ;

OPEN: ./inc/prof.inc.php

FIND:

 $prof['drinker'][4] = "Very often";

 


BELOW ADD:


$prof['Emotional_State'][1] = 'aggressive';
$prof['Emotional_State'][2] = 'amazed';
$prof['Emotional_State'][3] = 'amused';
$prof['Emotional_State'][4] = 'angelic';
$prof['Emotional_State'][5] = 'angry';
$prof['Emotional_State'][6] = 'apprehensive';
$prof['Emotional_State'][7] = 'approved';
$prof['Emotional_State'][8] = 'asleep';
$prof['Emotional_State'][9] = 'bahahaha';
$prof['Emotional_State'][10] = 'bashful';
$prof['Emotional_State'][11] = 'bitched';
$prof['Emotional_State'][12] = 'bitchy';
$prof['Emotional_State'][13] = 'blah';
$prof['Emotional_State'][14] = 'bookworm';
$prof['Emotional_State'][15] = 'bored';
$prof['Emotional_State'][16] = 'breezy';
$prof['Emotional_State'][17] = 'brooding';
$prof['Emotional_State'][18] = 'busy';
$prof['Emotional_State'][19] = 'buzzed';
$prof['Emotional_State'][20] = 'chatty';
$prof['Emotional_State'][21] = 'cheeky';
$prof['Emotional_State'][22] = 'cheerful';
$prof['Emotional_State'][23] = 'cloud_9';
$prof['Emotional_State'][24] = 'cold';
$prof['Emotional_State'][25] = 'confused';
$prof['Emotional_State'][26] = 'cool';
$prof['Emotional_State'][27] = 'crackhead';
$prof['Emotional_State'][28] = 'crappy';
$prof['Emotional_State'][29] = 'curmudgeon';
$prof['Emotional_State'][30] = 'cynical';
$prof['Emotional_State'][31] = 'daring';
$prof['Emotional_State'][32] = 'dead';
$prof['Emotional_State'][33] = 'depressed';
$prof['Emotional_State'][34] = 'devilish';
$prof['Emotional_State'][35] = 'disapprove';
$prof['Emotional_State'][36] = 'doh';
$prof['Emotional_State'][37] = 'doubtful';
$prof['Emotional_State'][38] = 'drunk';
$prof['Emotional_State'][39] = 'dunce';
$prof['Emotional_State'][40] = 'festive';
$prof['Emotional_State'][41] = 'fine';
$prof['Emotional_State'][42] = 'flirty';
$prof['Emotional_State'][43] = 'footMouth';
$prof['Emotional_State'][44] = 'gay';
$prof['Emotional_State'][45] = 'goofy';
$prof['Emotional_State'][46] = 'grumpy';
$prof['Emotional_State'][47] = 'hacker';
$prof['Emotional_State'][48] = 'haha';
$prof['Emotional_State'][49] = 'happy';
$prof['Emotional_State'][50] = 'horny';
$prof['Emotional_State'][51] = 'hot';
$prof['Emotional_State'][52] = 'hotflash';
$prof['Emotional_State'][53] = 'innocent';
$prof['Emotional_State'][54] = 'inpain';
$prof['Emotional_State'][55] = 'inspired';
$prof['Emotional_State'][56] = 'lonely';
$prof['Emotional_State'][57] = 'love';
$prof['Emotional_State'][58] = 'lurking';
$prof['Emotional_State'][59] = 'mad';
$prof['Emotional_State'][60] = 'mellow';
$prof['Emotional_State'][61] = 'nerdy';
$prof['Emotional_State'][62] = 'ornery';
$prof['Emotional_State'][63] = 'pensive';
$prof['Emotional_State'][64] = 'persnickety';
$prof['Emotional_State'][65] = 'pissedoff';
$prof['Emotional_State'][66] = 'psychedelic';
$prof['Emotional_State'][67] = 'question';
$prof['Emotional_State'][68] = 'redtemp';
$prof['Emotional_State'][69] = 'relaxed';
$prof['Emotional_State'][70] = 'roflol';
$prof['Emotional_State'][71] = 'sad';
$prof['Emotional_State'][72] = 'sassy';
$prof['Emotional_State'][73] = 'scared';
$prof['Emotional_State'][74] = 'shh';
$prof['Emotional_State'][75] = 'shocked';
$prof['Emotional_State'][76] = 'sick';
$prof['Emotional_State'][77] = 'sleepy';
$prof['Emotional_State'][78] = 'sneaky';
$prof['Emotional_State'][79] = 'starving';
$prof['Emotional_State'][80] = 'stuck';
$prof['Emotional_State'][81] = 'studly';
$prof['Emotional_State'][82] = 'sunshine';
$prof['Emotional_State'][83] = 'suspicious';
$prof['Emotional_State'][84] = 'talkative';
$prof['Emotional_State'][85] = 'tell';
$prof['Emotional_State'][86] = 'tired';
$prof['Emotional_State'][87] = 'tolerant';
$prof['Emotional_State'][88] = 'torn';
$prof['Emotional_State'][89] = 'twisted';
$prof['Emotional_State'][90] = 'vilified';
$prof['Emotional_State'][91] = 'volatile';
$prof['Emotional_State'][92] = 'wasted';
$prof['Emotional_State'][93] = 'where';
$prof['Emotional_State'][94] = 'wicked';
$prof['Emotional_State'][95] = 'woot';
$prof['Emotional_State'][96] = 'yeehaw';


6)

OPEN: ./inc/header.inc.php

   Find the line of code :
 
 $site['smiles']            = "{$site['url']}media/images/smiles/";
 
  Just Below it, Add :
 
 $site['emoticons']         = "{$site['url']}media/images/emoticons/";
 
 


UPLOAD the emoticons folder to ./media/images/

 

OPEN: ./templates/base/scripts/BxBaseProfileView.php


FIND FUNCTION: showBlockProfileDetails

FIND:
  
 $sDetails = $this -> showProfileFields( $aFields );

 

BELOW ADD:

 

 if($p_arr['Emotional_State'] != ""){
  $sEmotional_State = $prof['Emotional_State'][$p_arr['Emotional_State']];
  $Emotional_StateIcon = strtolower($sEmotional_State);
  $Emotional_StateIcon = str_replace(' ', '', $Emotional_StateIcon);
  $Emotional_StateIcon = str_replace( '(', '', $Emotional_StateIcon);
  $Emotional_StateIcon = str_replace( ')', '', $Emotional_StateIcon);
  $Emotional_StateDisplay = "<img src='{$site['emoticons']}{$Emotional_StateIcon}.gif' alt='{$sEmotional_State}'

/>";
 }


FIND:

 <?= $sDetails ?>

 

ABOVE ADD:

 


<? if( $p_arr['Emotional_State'] != "" ){ ?>
  <tr>
   <td class="profile_td_1">Emotional Status:</td>
   <td class="profile_td_2"><?php echo $Emotional_StateDisplay ?></td>
  </tr>
 <?}?>
 <? if( $p_arr['Current_Status'] != "" ){ ?>  
  <tr>
   <td class="profile_td_1">Current Status:</td>
   <td class="profile_td_2" colspan=2 height=40><?php echo $p_arr['NickName']."

".$p_arr['Current_Status']; ?></td>
  </tr>
 <?}?>
 

OPEN: ./templates/tmpl_uni/searchrow.html

FIND:

 
 <div class="nick">__nick__</div>


REPLACE WITH:

  <div class="age_from">__nick__ __Current_Status_status____Emotional_State__</div>

 
OPEN: ./inc/members.inc.php


FIND:

 global $NickName;

 

BELOW ADD:

 $Emotional_StateDisplay = "";
 if($p_arr['Emotional_State'] != ""){
  $sEmotional_State = $prof['Emotional_State'][$p_arr['Emotional_State']];
  $Emotional_StateIcon = strtolower($sEmotional_State);
  $Emotional_StateIcon = str_replace(' ', '', $Emotional_StateIcon);
  $Emotional_StateIcon = str_replace( '(', '', $Emotional_StateIcon);
  $Emotional_StateIcon = str_replace( ')', '', $Emotional_StateIcon);
  $Emotional_StateDisplay = "&nbsp; <img src='{$site['emoticons']}{$Emotional_StateIcon}.gif' alt='{$sEmotional_State}'

/>";
 }
 $Current_Status_status = "<br>{$p_arr['Current_Status']}";

 


FIND:
 
 $templ = str_replace ( "__nick__", $nick, $templ );

 


BELOW ADD:

 $templ = str_replace ( "__Emotional_State__",  $Emotional_StateDisplay, $templ  );
 $templ = str_replace ( "__Current_Status_status__", $Current_Status_status, $templ );

 

 

OPEN: ./templates/tmpl_uni/scripts/functions.php

FIND:

                        <div class="hello_member"><font color=ffffff><?= _t( '_Hello member', getNickName( $memberID ) ) ?></font></div>


BELOW ADD:

<div class="hello_actions"><b><div style='align:right' id='Current_Status_msg'><font color="white"><? echo $p_arr['NickName']; ?><?= $Current_Status?></font></div></b>
<div

style='float:right'>&nbsp;<a href='javascript://'

onclick="document.getElementById('Current_Statusblock').style.display='block'"><font color="white">Update Status</font></a></div>
  <br>

 <div id="Current_Statusblock" style="display:none">
     <input class=no type=textfield id="Current_Status" name="Current_Status"

value="<?=$Current_Status?>" size=25 width="250px" >
     <input class=no type=button name="go" value="Update"

onclick="document.getElementById('Current_Statusblock').style.display='none';var

Current_Status=document.getElementById('Current_Status').value; getHtmlData( 'Current_Status_msg',

'member.php?Current_Status='+Current_Status+'&amp;show_only=Current_Status');return false;">
   </div></div>


OPEN: ./member.php

FIND:


  case 'shareVideos':
   $sCaption = db_value( "SELECT `Caption` FROM `AccountCompose` WHERE `Func` =

'ShareVideos'" );
   echo PageCompShareVideosContent($sCaption, $member['ID']);
  break;


BELOW ADD:

  case 'Emotional_State':
   echo setEmotional_State($member['ID']);
   $p_arr = getProfileInfo( $member['ID'] );
  break;
  
  case 'Current_Status':
   echo setCurrent_Status($member['ID']);
   $p_arr = getProfileInfo( $member['ID'] );
  break;
 
 
FIND FUNCTION:  PageCompMemberInfo
 
FIND:

  global $en_sdating;

 


BELOW ADD:

 
 global $prof;

 $supdateC = _t( "_update" );
 $Current_Status = $p_arr['Current_Status'];

 
 
FIND:
 
 $free_mode = getParam("free_mode") == "on" ? 1 : 0;


BELOW ADD:

 $Emotional_State = $p_arr['Emotional_State'];
  

 $sEmotional_StateOptions = '';
 foreach ( $prof['Emotional_State'] as $key => $value ) {  
  if( $Emotional_State == "$key" ){
   $sEmotional_StateKeySel = 'selected="selected"';
   $selEmotional_State = $value;
  }else{
   $sEmotional_StateKeySel = '';
  }
  $sEmotional_StateOptions .= "<option value=\"{$key}\" {$sEmotional_StateKeySel} >{$value}</option>";
 }

 if($selEmotional_State != ''){
  $Emotional_StateAlt = $selEmotional_State;
  $iconImg = strtolower($selEmotional_State);
  $iconImg = str_replace( ' ', '', $iconImg);
  $iconImg = str_replace( '(', '', $iconImg);
  $iconImg = str_replace( ')', '', $iconImg); 
  $Emotional_StateIcon = "<img src='{$site['emoticons']}{$iconImg}.gif' alt='{$Emotional_StateAlt}' />";
 }


   


FIND:
 
 <tr class=table>

 <!-- Profile Status -->

 

ABOVE ADD:

<table>
<tr class=table>
 <td valign=top align="left" class=control_panel_td_1>Current Status:</td>
<td valign=top align="left" class=control_panel_td_2> 
<div><b><div style='align:right' id='Current_Status_msg'><b><div style='float:left' id='Current_Status_msg'><? echo $p_arr['NickName']; ?><?= $Current_Status ?></div></b><br>

<div style='float:left'>&nbsp;<a href='javascript://' onclick="document.getElementById('Current_Statusblock').style.display='block'">Update Status</a></div>
  
<div id="Current_Statusblock" style="display:none">
<br>
     <input class=no type=textfield id="Current_Status" name="Current_Status" value="<?=$Current_Status?>" size=25 width="250px" >
     <input class=no type=button name="go" value="Update" onclick="document.getElementById('Current_Statusblock').style.display='none';var Current_Status=document.getElementById('Current_Status').value; getHtmlData( 'Current_Status_msg', 'member.php?Current_Status='+Current_Status+'&amp;show_only=Current_Status');return false;">
</div></div></div>
</td>
 </tr>
   

 </td>
 </tr>

 

<br>

 

 <tr class=table>
 <td valign=top align="left" class=control_panel_td_1>Emotional State: </td>
 <td valign=top align="left" class=control_panel_td_2>
  <table cellpadding=0 cellspacing=0>
   <tr>
    <td><select class="no" id="Emotional_State" name="Emotional_State" onchange="sEmotional_State=this.value; getHtmlData( 'Emotional_State_icon', 'member.php?Emotional_State='+sEmotional_State+'&amp;show_only=Emotional_State');return false;"><? echo

$sEmotional_StateOptions; ?></select></td>
    <td><span id='Emotional_State_icon'><? echo $Emotional_StateIcon ?></span></td>
   </tr>
  </table>
 </td>
 </tr>

 


FIND:

 /**
  * contr panel "member info"
  */
 function PageCompMemberInfo()
 {

 

ABOVE ADD:

 function setEmotional_State($memberID){

  global $prof;
  global $site;

  $newEmotional_State = $_REQUEST['Emotional_State'];

  $sql = "update `Profiles` set Emotional_State=$newEmotional_State WHERE `ID` = $memberID";
  db_res($sql);

  foreach ( $prof['Emotional_State'] as $key => $value ) {  
   if( $newEmotional_State == "$key" ){
    $selEmotional_State = $value;
   }
  }

  if($selEmotional_State != ''){
   $Emotional_StateAlt = $selEmotional_State;
   $iconImg = strtolower($selEmotional_State);
   $iconImg = str_replace( ' ', '', $iconImg);
   $iconImg = str_replace( '(', '', $iconImg);
   $iconImg = str_replace( ')', '', $iconImg);
   createUserDataFile( $memberID );
   return "<img src='{$site['emoticons']}{$iconImg}.gif' alt='{$Emotional_StateAlt}' />";
  }else{
   return '';
  }
 }

 

 function setCurrent_Status($memberID){
  
  $Current_Status = $_REQUEST['Current_Status'];

  $sql = "update `Profiles` set Current_Status='$Current_Status' WHERE `ID` = $memberID";
  
  if($res = db_res($sql)){
   createUserDataFile( $memberID );
   return $Current_Status;
  }else{
   return '';
  }
 }

 

It simply doesn't work with our site.

 

 

THE END

 

Quote · 4 Aug 2009

Ok, I finally found it and here is the url:

 

http://www.expertzzz.com/Downloadz/view/3779

Quote · 4 Aug 2009
 
 
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.