Register for your free account! | Forgot your password?

You last visited: Today at 08:07

  • Please register to post and access all features, it's quick, easy and FREE!


[Release] Ingamechat Php Script

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Sep 2010
Posts: 17
Received Thanks: 4
[Release] Ingamechat Php Script

hey epvp

I share a script I wrote recently ,

I apologize if shared ..

PHP Code:
<?php 
error_reporting
(1);
    
define("MSQL_HOST""ip"); 
    
define("MSQL_USER""user"); 
    
define("MSQL_PASS""pass"); 
     
    
$connect = @mysql_connect(MSQL_HOSTMSQL_USERMSQL_PASS);     
    if(
$connect){ 
        
$limit 15
        
$sqlCmd "SELECT `3` as 'empire',`4` as 'shout',`1` as 'msgTime' FROM log.shout_log ORDER BY msgTime DESC LIMIT ".$limit
        
$sqlQry mysql_query($sqlCmd); 
        echo 
'<table><tr><th>Date</th><th>Post</th></tr>'
        while(
$row mysql_fetch_object($sqlQry)){ 
            echo 

                <tr> 
                    <td> 
                        '
.$row->msgTime.
                    </td> 
                    <td> 
            '

                if(
$row->empire == 1){ 
                    echo 
'<span style="color:red;">'.htmlspecialchars($row->shout).'</span>'
                } elseif(
$row->empire == 2){ 
                    echo 
'<span style="color:yellow;">'.htmlspecialchars($row->shout).'</span>'
                } elseif(
$row->empire == 3){ 
                    echo 
'<span style="color:blue;">'.htmlspecialchars($row->shout).'</span>'
                } 
            echo 

                    </td> 
                </tr> 
            '

        } 
        echo 
'</table>'
    } else { 
        echo 
"Error connecting to server"
    } 
?>



masdenqqq is offline  
Thanks
4 Users
Old 01/14/2012, 15:34   #2
 
elite*gold: 25
Join Date: Sep 2011
Posts: 5,537
Received Thanks: 1,265
Useless but nice idea!


IchVerabschiedeMich is offline  
Thanks
1 User
Old 01/14/2012, 16:23   #3
 
elite*gold: 0
Join Date: May 2009
Posts: 152
Received Thanks: 36
Help me pls


Warning: mysql_query() [function.mysql-query]: Can't connect to local MySQL server through socket '/tmp/mysqld.sock' (2) in /homepages/26/d364543118/htdocs/pages/online.php on line 2

Warning: mysql_query() [function.mysql-query]: A link to the server could not be established in /homepages/26/d364543118/htdocs/pages/online.php on line 2

Warning: mysql_query() [function.mysql-query]: Can't connect to local MySQL server through socket '/tmp/mysqld.sock' (2) in /homepages/26/d364543118/htdocs/pages/online.php on line 3

Warning: mysql_query() [function.mysql-query]: A link to the server could not be established in /homepages/26/d364543118/htdocs/pages/online.php on line 3

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /homepages/26/d364543118/htdocs/pages/online.php on line 3

Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /homepages/26/d364543118/htdocs/pages/online.php on line 26
Date Post
ixel4 is offline  
Old 01/14/2012, 16:30   #4
 
elite*gold: 25
Join Date: Sep 2011
Posts: 5,537
Received Thanks: 1,265
Quote:
Originally Posted by ixel4 View Post
Help me pls


Warning: mysql_query() [function.mysql-query]: Can't connect to local MySQL server through socket '/tmp/mysqld.sock' (2) in /homepages/26/d364543118/htdocs/pages/online.php on line 2

Warning: mysql_query() [function.mysql-query]: A link to the server could not be established in /homepages/26/d364543118/htdocs/pages/online.php on line 2

Warning: mysql_query() [function.mysql-query]: Can't connect to local MySQL server through socket '/tmp/mysqld.sock' (2) in /homepages/26/d364543118/htdocs/pages/online.php on line 3

Warning: mysql_query() [function.mysql-query]: A link to the server could not be established in /homepages/26/d364543118/htdocs/pages/online.php on line 3

Warning: mysql_fetch_assoc(): supplied argument is not a valid MySQL result resource in /homepages/26/d364543118/htdocs/pages/online.php on line 3

Warning: mysql_fetch_object(): supplied argument is not a valid MySQL result resource in /homepages/26/d364543118/htdocs/pages/online.php on line 26
Date Post
Ich habe grade 3 vServer und auf keinem nen Webserver um das zu testen...
Lold

Ich teste das script mal.


IchVerabschiedeMich is offline  
Thanks
1 User
Old 01/14/2012, 16:31   #5
 
elite*gold: 0
Join Date: Feb 2011
Posts: 590
Received Thanks: 201
Werd ich auf meinem Server bzw. auf der Homepage meines Servers einbauen. Danke ;-)
Kugelsicher is offline  
Thanks
1 User
Old 01/14/2012, 16:32   #6
 
elite*gold: 0
Join Date: May 2009
Posts: 152
Received Thanks: 36
Ok ich habe alles richtig gemacht aber kp wiesoe diese fehler meldung kommt
ixel4 is offline  
Old 01/14/2012, 16:49   #7
 
elite*gold: 0
Join Date: Nov 2009
Posts: 9
Received Thanks: 2
as like (:
akalod is offline  
Old 01/14/2012, 16:52   #8
 
elite*gold: 25
Join Date: Sep 2011
Posts: 5,537
Received Thanks: 1,265
Wenn ich recht überlege könnte man damit doch ne xss Lücke erzeugen o.O
IchVerabschiedeMich is offline  
Old 01/14/2012, 16:55   #9
 
elite*gold: 0
Join Date: Jan 2012
Posts: 2
Received Thanks: 0
I saw it. 2 weeks ago metin2mad
SayanorA is offline  
Old 01/14/2012, 17:00   #10
 
elite*gold: 0
Join Date: May 2009
Posts: 152
Received Thanks: 36
hmm aber wieso geht das den nciht bei mit weist das jemand ?
ixel4 is offline  
Old 01/14/2012, 17:16   #11
 
elite*gold: 25
Join Date: Sep 2011
Posts: 5,537
Received Thanks: 1,265
Quote:
Originally Posted by ixel4 View Post
hmm aber wieso geht das den nciht bei mit weist das jemand ?
Kp geht bei mir auch net.
Denke Querys sind falsch kenne mich mit php net so aus.
IchVerabschiedeMich is offline  
Old 01/14/2012, 17:56   #12
 
elite*gold: 0
Join Date: May 2009
Posts: 152
Received Thanks: 36
ahso ok danke egal dann wolte nur wiessen ob das nur bei mir so ist
ixel4 is offline  
Old 01/14/2012, 18:04   #13
 
elite*gold: 25
Join Date: Sep 2011
Posts: 5,537
Received Thanks: 1,265
Quote:
Originally Posted by ixel4 View Post
ahso ok danke egal dann wolte nur wiessen ob das nur bei mir so ist
3. Query ist falsch.
Also bei jedem so

Zeile 24 mit dem ersetzen:
PHP Code:
        $sqlCmd "SELECT `3` as 'empire',`4` as 'shout',`1` as 'msgTime' FROM log.shout_log ORDER BY msgTime DESC LIMIT ".$limit

Danke @ Mythen

Vorsicht XSS Lücke!
IchVerabschiedeMich is offline  
Thanks
1 User
Old 01/14/2012, 18:07   #14
 
elite*gold: 0
Join Date: Aug 2009
Posts: 962
Received Thanks: 96
iost vom anderen forum^^
lautlosertot is offline  
Old 01/14/2012, 18:20   #15

 
elite*gold: 0
Join Date: Feb 2010
Posts: 7,213
Received Thanks: 6,752
Quote:
Originally Posted by lautlosertot View Post
iost vom anderen forum^^
Dann sag uns doch auch direkt von welchem Forum, mit Link, sonst ist's nur Spam.


#SoNiice is offline  
Reply



« [Release]Quest-Zusammenstellung | [How To]Metin2 Teleporter Quest Einfügen »

Similar Threads
[HELP] game 2089 GM Private Chat
01/14/2012 - Metin2 PServer - Discussions / Questions - 5 Replies
Hello, I have a problem with GM's Private Chat; I use 2089 gamefile and the messages sended by GM player, do not arrive to destination. It is a launcher problem? Or what? Thanks for your attention.
Chat game
06/04/2011 - Main - 1 Replies
das ist mein selbstgemachtes chat spiel ihr könnt es jedem veraten . was ihr braucht : einen chat zwei bis unendlich spieler einen master der spielverlauf : der master schreibt fertig danach denkt sich jeder spieler ein wort aus...
i want to change the chat text in game.
03/23/2011 - Archlord - 7 Replies
can anyone explain to me how to change the text in this crap game? :P
[Help]In Game chat images
01/28/2009 - EO PServer Hosting - 2 Replies
Good day, Recently the images for in game chat have gone missing. I'm talking about the images that say legion, whisper, team and so on. Can anyone help me with fixing these issues? Perhaps tell which folder I should be looking in. The images...
Game Chat
09/21/2008 - General Coding - 3 Replies
Hallo Leute Ich wollte mal fragen ob mir jemand ein Chat programm machen kann das nicht viel res friesst und wo man eine IP bekommt und sich damit einlogen muss.Weil icq ist mir zu verfressen! Sollte auf meinem FTP laufen um history zu...



All times are GMT +2. The time now is 08:07.


Powered by vBulletin®
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Abuse
Copyright ©2018 elitepvpers All Rights Reserved.