Help Messages

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Help Messages

    Hi friends!! chat messages continue to disappear after 50 seconds, I tried to solve this problem, we can not.
    file core.php
    Code:
    ///////////////////////////////////////Add to chat
    
    
    
    function addtochat($uid, $rid)
    
    {
      $bago = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_chonline WHERE uid='".$uid."' AND rid='".$rid."'"));
    if($bago[0]==0){
    $msg = "*mat Enter the Room";
    mysql_query("INSERT INTO ibwf_chat SET timesent='".time()."', chatter='".$uid."', text='".$msg."'");
    }
    
      $timeto = 86400;
    
      $timenw = time();
    
      $timeout = $timenw - $timeto;
    
      //$exec = mysql_query("DELETE FROM ibwf_chonline WHERE lton<&#39;".$timeout."&#39;");
    
      $res = mysql_query("INSERT INTO ibwf_chonline SET lton=&#39;".time()."&#39;, uid=&#39;".$uid."&#39;, rid=&#39;".$rid."&#39;");
    
      if(!$res)
      if($counter<15)
    
      {
        
        mysql_query("UPDATE ibwf_chonline SET lton=&#39;".time()."&#39;, rid=&#39;".$rid."&#39; WHERE uid=&#39;".$uid."&#39;");
    
      }
    
    }
    and file chat.php
    Code:
    addtochat($uid, $rid);
            $timeto = 86400;
            $timenw = time();
            $timeout = $timenw-$timeto;
            $rooms = mysql_fetch_array(mysql_query("SELECT id, name FROM ibwf_rooms WHERE id=&#39;".$rid."&#39;"));
            $rname = $rooms[1];
            $nick = getnick_sid($sid);
       
           
          if ($action=="")
          {
         $check = mysql_fetch_array(mysql_query("SELECT uid FROM ibwf_chonline WHERE uid=&#39;".$uid."&#39;, rid=&#39;".$rid."&#39;"));
            if($check[0]!=$uid){
          
          mysql_query("INSERT INTO ibwf_chat SET timesent=&#39;".time()."&#39;, chatter=&#39;".$uid."&#39;, text=&#39;".$msg."&#39;");
    }
    addtochat($uid, $rid);
          echo "<head>";
          echo "<title>$rname</title>";
          echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
          $unreadpopup=mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_popups WHERE unread=&#39;1&#39; AND touid=&#39;".$uid."&#39;"));
          if ($unreadpopup[0]<1)
          {
          echo "<meta http-equiv=\"refresh\" content=\"20; url=chat.php?time=";
          echo "".date("dmHis")."";
          echo "&amp;sid=$sid&amp;rid=$rid&amp;rpw=$rpw\">";
    thanks to those who solves this problem

    #2
    lavalair lmao
    Visit: Chat4u.mobi - The New Lay Of being a site of your dreams!
    Visit: WapMasterz Coming Back Soon!
    _______
    SCRIPTS FOR SALE BY SUBZERO
    Chat4u Script : coding-talk.com/f28/chat4u-mobi-script-only-150-a-17677/ - > Best Script for your site no other can be hacked by sql or uploaders.
    FileShare Script : coding-talk.com/f28/file-wap-share-6596/ -> Uploader you will never regret buying yeah it mite be old now but it still seems to own others...
    _______
    Info & Tips
    php.net
    w3schools.com

    Comment


      #3
      About Imao NOT UNDERSTAND

      Comment


        #4
        it would help if u put the right files up here these file dont even have the delete chat message query

        Comment


          #5
          I have this
          -- Table structure for table `ibwf_chat`
          --

          CREATE TABLE `ibwf_chat` (
          `id` int(99) NOT NULL auto_increment,
          `chatter` int(100) NOT NULL default &#39;0&#39;,
          `who` int(100) NOT NULL default &#39;0&#39;,
          `timesent` int(50) NOT NULL default &#39;0&#39;,
          `msgtext` varchar(255) NOT NULL default &#39;&#39;,
          `rid` int(99) NOT NULL default &#39;0&#39;,
          `exposed` char(1) NOT NULL default &#39;0&#39;,
          PRIMARY KEY (`id`)
          ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;

          --
          -- Dumping data for table `ibwf_chat`
          --

          Comment


            #6
            there not querys either thats your db

            Comment


              #7
              if chat messages are being deleted every 50 seconds obviously its a problem with the $timeto =function basically just search every single one of them in core and chat.php that should solve the problem i think
              like the following crap

              Code:
              function cleardata()
              {
                $timeto = 120;
                $timenw = time();
                $timeout = $timenw - $timeto;
                $exec = mysql_query("DELETE FROM ibwf_chonline WHERE lton<&#39;".$timeout."&#39;");
                $timeto = 300;
                $timenw = time();
                $timeout = $timenw - $timeto;
                $exec = mysql_query("DELETE FROM ibwf_chat WHERE timesent<&#39;".$timeout."&#39;");
              forgotten how this script works now not used or touched it for well over a year now

              Comment


                #8
                amylee in file core.php is the same that I have

                Comment


                  #9
                  <div class='quotetop'>QUOTE (Leviathan73 @ Feb 9 2009, 06:26 PM) <{POST_SNAPBACK}></div>
                  Hi friends!! chat messages continue to disappear after 50 seconds, I tried to solve this problem, we can not.
                  file core.php
                  <div class='codetop'>CODE
                  <div class='codemain' style='height:200px;white-space:pre;overflow:auto'>///////////////////////////////////////Add to chat



                  function addtochat($uid, $rid)

                  {
                  $bago = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_chonline WHERE uid=&#39;".$uid."&#39; AND rid=&#39;".$rid."&#39;"));
                  if($bago[0]==0){
                  $msg = "*mat Enter the Room";
                  mysql_query("INSERT INTO ibwf_chat SET timesent=&#39;".time()."&#39;, chatter=&#39;".$uid."&#39;, text=&#39;".$msg."&#39;");
                  }

                  $timeto = 86400;

                  $timenw = time();

                  $timeout = $timenw - $timeto;

                  //$exec = mysql_query("DELETE FROM ibwf_chonline WHERE lton<&#39;".$timeout."&#39;");

                  $res = mysql_query("INSERT INTO ibwf_chonline SET lton=&#39;".time()."&#39;, uid=&#39;".$uid."&#39;, rid=&#39;".$rid."&#39;");

                  if(!$res)
                  if($counter<15)

                  {

                  mysql_query("UPDATE ibwf_chonline SET lton=&#39;".time()."&#39;, rid=&#39;".$rid."&#39; WHERE uid=&#39;".$uid."&#39;");

                  }

                  }</div>
                  and file chat.php
                  <div class='codetop'>CODE</div><div class='codemain' style='height:200px;white-space:pre;overflow:auto'>addtochat($uid, $rid);
                  $timeto = 86400;
                  $timenw = time();
                  $timeout = $timenw-$timeto;
                  $rooms = mysql_fetch_array(mysql_query("SELECT id, name FROM ibwf_rooms WHERE id=&#39;".$rid."&#39;"));
                  $rname = $rooms[1];
                  $nick = getnick_sid($sid);


                  if ($action=="")
                  {
                  $check = mysql_fetch_array(mysql_query("SELECT uid FROM ibwf_chonline WHERE uid=&#39;".$uid."&#39;, rid=&#39;".$rid."&#39;"));
                  if($check[0]!=$uid){

                  mysql_query("INSERT INTO ibwf_chat SET timesent=&#39;".time()."&#39;, chatter=&#39;".$uid."&#39;, text=&#39;".$msg."&#39;");
                  }
                  addtochat($uid, $rid);
                  echo "<head>";
                  echo "<title>$rname</title>";
                  echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
                  $unreadpopup=mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_popups WHERE unread=&#39;1&#39; AND touid=&#39;".$uid."&#39;"));
                  if ($unreadpopup[0]<1)
                  {
                  echo "<meta http-equiv=\"refresh\" content=\"20; url=chat.php?time=";
                  echo "".date("dmHis")."";
                  echo "&amp;sid=$sid&amp;rid=$rid&amp;rpw=$rpw\">";</div>
                  thanks to those who solves this problem [/b][/quote]
                  this is part of code from chat.php
                  the only important thing is number 259200...
                  posted value 259200 will keep last 10(if set so) msgs in chat for 3(!) days,
                  cos value is in secunds...........
                  Code:
                  addtochat($uid, $rid);
                                     $timeto = 259200;
                                     $timenw = time();
                                     $timeout = $timenw-$timeto;
                                     $deleted = mysql_query("DELETE FROM ibwf_chat WHERE timesent<".$timeout."");
                                 if ($action=="")
                                 {
                                 echo "<card id=\"chat\" title=\"$s_name\" ontimer=\"chat.php?time=";
                                 echo date(&#39;dmHis&#39;);
                                 echo "&amp;sid=$sid&amp;rid=$rid&amp;rpw=$rpw";
                                 echo "\">";
                  ////////////////////////////////////////////////////////////////////////////////////////////
                  meanwhile in code from core.php
                  Code:
                  function addtochat($uid, $rid)
                             {
                               $timeto = 45;
                               $timenw = time();
                               $timeout = $timenw - $timeto;
                               $exec = mysql_query("DELETE FROM ibwf_chonline WHERE lton<&#39;".$timeout."&#39;");
                               $res = mysql_query("INSERT INTO ibwf_chonline SET lton=&#39;".time()."&#39;, uid=&#39;".$uid."&#39;, rid=&#39;".$rid."&#39;");
                               if(!$res)
                               {
                                 mysql_query("UPDATE ibwf_chonline SET lton=&#39;".time()."&#39;, rid=&#39;".$rid."&#39; WHERE uid=&#39;".$uid."&#39;");
                               }
                             }
                  value $timeto only means for how long(again in secunds!) user will be shown
                  as present in chat room eventhough he already left room...
                  It's better to keep your mouth shut and give the impression that you're stupid, than to open it and remove all doubt.
                  ⓣⓗⓔ ⓠⓤⓘⓔⓣⓔⓡ ⓨⓞⓤ ⓑⓔ©ⓞⓜⓔ, ⓣⓗⓔ ⓜⓞⓡⓔ ⓨⓞⓤ ⓐⓡⓔ ⓐⓑⓛⓔ ⓣⓞ ⓗⓔⓐⓡ !
                  ιη тнєσяу, тнє ρяα¢тι¢є ιѕ α яєѕυℓт σƒ тнє тнєσяу, вυт ιη ρяα¢тι¢є ιѕ тнє σρρσѕιтє.
                  キノgんイノ刀g 4 ア乇ムc乇 ノ丂 レノズ乇 キucズノ刀g 4 √ノ尺gノ刀ノイリ!

                  Comment


                    #10
                    does not work either, in addition to the messages disappear, disappeared the names of the rooms and the background color

                    Comment


                      #11
                      <div class='quotetop'>QUOTE (Leviathan73 @ Feb 12 2009, 11:10 AM) <{POST_SNAPBACK}></div>
                      does not work either, in addition to the messages disappear, disappeared the names of the rooms and the background color [/b]
                      any1 who ever edited anything in lava script
                      will know that my reply is 100% correct...
                      if that doesnt work for you...
                      then you didnt explain your problem properly
                      or you have some other problems as well
                      It's better to keep your mouth shut and give the impression that you're stupid, than to open it and remove all doubt.
                      ⓣⓗⓔ ⓠⓤⓘⓔⓣⓔⓡ ⓨⓞⓤ ⓑⓔ©ⓞⓜⓔ, ⓣⓗⓔ ⓜⓞⓡⓔ ⓨⓞⓤ ⓐⓡⓔ ⓐⓑⓛⓔ ⓣⓞ ⓗⓔⓐⓡ !
                      ιη тнєσяу, тнє ρяα¢тι¢є ιѕ α яєѕυℓт σƒ тнє тнєσяу, вυт ιη ρяα¢тι¢є ιѕ тнє σρρσѕιтє.
                      キノgんイノ刀g 4 ア乇ムc乇 ノ丂 レノズ乇 キucズノ刀g 4 √ノ尺gノ刀ノイリ!

                      Comment


                        #12
                        Other problems I have, in games, the upload, opening that does not refresh inside the room when sends a message. This is the Community, I do not want to spam

                        Comment


                          #13
                          <div class='quotetop'>QUOTE (Leviathan73 @ Feb 12 2009, 06:21 PM) <{POST_SNAPBACK}></div>
                          Other problems I have, in games, the upload, opening that does not refresh inside the room when sends a message. This is the Community, I do not want to spam[/b]
                          i dont understand language on site anyway...
                          It's better to keep your mouth shut and give the impression that you're stupid, than to open it and remove all doubt.
                          ⓣⓗⓔ ⓠⓤⓘⓔⓣⓔⓡ ⓨⓞⓤ ⓑⓔ©ⓞⓜⓔ, ⓣⓗⓔ ⓜⓞⓡⓔ ⓨⓞⓤ ⓐⓡⓔ ⓐⓑⓛⓔ ⓣⓞ ⓗⓔⓐⓡ !
                          ιη тнєσяу, тнє ρяα¢тι¢є ιѕ α яєѕυℓт σƒ тнє тнєσяу, вυт ιη ρяα¢тι¢є ιѕ тнє σρρσѕιтє.
                          キノgんイノ刀g 4 ア乇ムc乇 ノ丂 レノズ乇 キucズノ刀g 4 √ノ尺gノ刀ノイリ!

                          Comment

                          Working...
                          X