Jump to content

runnerjp

Members
  • Posts

    2,214
  • Joined

  • Last visited

Everything posted by runnerjp

  1. just like to say tho that the image link worked :D:D nice 1 yeey lol just white text and its dun :P
  2. well i want the white text on a black background u see :D where do i add the white text code :P
  3. sweet thanks....any idea about adding the picture and changein the text to white... tride to add codes in and keep gttin errors... simple i know yet its l8 lol had bad day need to fin of this so i can sleep well 2night haha cheers
  4. hey just had help with gttin this script to work...now i need to tweak it a ll is their away so in between each post it displayes this image [url=http://www.runnerselite.com/image/runner.gif]http://www.runnerselite.com/image/runner.gif[/url] to split them up also if you look at the page its on [url=http://www.runnerselite.com]www.runnerselite.com[/url] you can see that the username and the message does not have a space inbetween it so its all crunched together  is their away so a can add [  (space):  ] to it if you get me....basicly space it out?? heres code [code]<?php ################################# include("chatbox/connect.php"); ################################# mysql_connect($host,$dbuser,$dbpass) or die(mysql_error()); // Select the database. mysql_select_db($dbname) or die(mysql_error()); $query = "SELECT poster, message FROM ch_messages order by id DESC LIMIT 5"; $result = mysql_query($query); $marquee = ""; while($r=mysql_fetch_array($result)) {    $marquee.= $r[poster]. ''. $r[message]. '</a>'; } echo "<marquee><font size='3'>". $marquee. "</font></marquee>"; ?>[/code]
  5. ok i know im gonna be a pain in ass but as im on a role i wanna know ... is their a way of separatin the name and message the some space cos at mo if you look [url=http://www.runnerselite.com]www.runnerselite.com[/url] it comes as one lol and could i add a picture like my logo in between each diff comment ??? or is that all 2 hard to do
  6. YEEEEEEEEEEEEEEEEEEEEEEEEEY IT WORKS i would just like to thank you all for you help!!! if at any point i can offer a fav in any of your diractions i will help as much as i can....thank you again
  7. surey $dbname = "runnerse_chatbox"; wud mean that the db is set to nothing :S
  8. the new code looks like this [code]<?php $host  = "localhost"; $dbuser = "myusername"; $dbpass = "mypassword"; $dbname = "runnerse_chatbox"; mysql_connect($host,$dbuser,$dbpass) or die("Could not connect: ".mysql_error()); // Select the database. mysql_select_db($dbname) or die(mysql_error()); if(!$db)         die("no db"); if(!mysql_select_db("runnerse_chatbox",$db))         die("No database selected."); if(!get_magic_quotes_gpc()) {   $_GET = array_map('mysql_real_escape_string', $_GET);   $_POST = array_map('mysql_real_escape_string', $_POST);   $_COOKIE = array_map('mysql_real_escape_string', $_COOKIE); } else {   $_GET = array_map('stripslashes', $_GET);   $_POST = array_map('stripslashes', $_POST);   $_COOKIE = array_map('stripslashes', $_COOKIE);   $_GET = array_map('mysql_real_escape_string', $_GET);   $_POST = array_map('mysql_real_escape_string', $_POST);   $_COOKIE = array_map('mysql_real_escape_string', $_COOKIE); } ?>[/code] yet it still keeps comein up with no db :S here is marquee to bd if that helps [code]<?php ################################# include("chatbox/connect.php"); ################################# mysql_connect($host,$dbuser,$dbpass) or die(mysql_error()); // Select the database. mysql_select_db($dbname) or die(mysql_error()); $query = "SELECT poster, message FROM ch_messages order by id DESC LIMIT 5"; $result = mysql_query($query); $marquee = ""; while($r=mysql_fetch_array($result)) {   $marquee.= $r[poster]. ''. $r[message]. '</a>'; } echo "<marquee><font size='3'>". $marquee. "</font></marquee>"; ?>[/code]
  9. so if i took of the or die("Could not connect."); it will work...thanks guy 4 thery fast reply
  10. Parse error: syntax error, unexpected T_LOGICAL_OR in /home/runnerse/public_html/chatbox/connect.php on line 5 thats the issue here is the code [code]<?php $host  = "localhost"; $dbuser = "runnerse"; $dbpass = "runnerjp2003"; $dbname = "runnerse_shoutbox"; or die("Could not connect."); mysql_connect($host,$dbuser,$dbpass) or die(mysql_error()); // Select the database. mysql_select_db($dbname) or die(mysql_error()); if(!$db)         die("no db"); if(!mysql_select_db("runnerse_chatbox",$db))         die("No database selected."); if(!get_magic_quotes_gpc()) {   $_GET = array_map('mysql_real_escape_string', $_GET);   $_POST = array_map('mysql_real_escape_string', $_POST);   $_COOKIE = array_map('mysql_real_escape_string', $_COOKIE); } else {   $_GET = array_map('stripslashes', $_GET);   $_POST = array_map('stripslashes', $_POST);   $_COOKIE = array_map('stripslashes', $_COOKIE);   $_GET = array_map('mysql_real_escape_string', $_GET);   $_POST = array_map('mysql_real_escape_string', $_POST);   $_COOKIE = array_map('mysql_real_escape_string', $_COOKIE); } ?>[/code]
  11. thanks i did that yet their still seems to be a problem on line 7 :S
  12. sweet nice 1 thats done.....now i got error on line 7!!!!! this usuall never happens lol i will post my connect script as well just incase its a link thing 1st my connect script [code]<?php $host  = "localhost"; $dbuser = "my user name to db is here"; $dbpass = "this is where i have typed my pass"; $dbname = "my db name is here"; or die("Could not connect."); if(!$db)         die("no db"); if(!mysql_select_db("this is where i have added my db name for my chatbox",$db))         die("No database selected."); if(!get_magic_quotes_gpc()) {   $_GET = array_map('mysql_real_escape_string', $_GET);   $_POST = array_map('mysql_real_escape_string', $_POST);   $_COOKIE = array_map('mysql_real_escape_string', $_COOKIE); } else {   $_GET = array_map('stripslashes', $_GET);   $_POST = array_map('stripslashes', $_POST);   $_COOKIE = array_map('stripslashes', $_COOKIE);   $_GET = array_map('mysql_real_escape_string', $_GET);   $_POST = array_map('mysql_real_escape_string', $_POST);   $_COOKIE = array_map('mysql_real_escape_string', $_COOKIE); } ?>[/code] now my new maq [code]<?php ################################# include("chatbox/connect.php"); ################################# mysql_connect($host,$dbuser,$dbpass) or die(mysql_error()); // Select the database. mysql_select_db($dbname) or die(mysql_error()); $query = "SELECT poster, message FROM ch_messages order by id DESC LIMIT 5"; $result = mysql_query($query); $marquee = ""; while($r=mysql_fetch_array($result)) {   $marquee.= $r[poster]. ''. $r[message]. '</a>'; } echo "<marquee><font size='3'>". $marquee. "</font></marquee>"; ?>[/code]
  13. Parse error: syntax error, unexpected T_CONSTANT_ENCAPSED_STRING in /home/runnerse/public_html/chatbox/maq.php on line 16 [code] <?php ################################# include("chatbox/connect.php"); ################################# mysql_connect($host,$dbuser,$dbpass) or die(mysql_error()); // Select the database. mysql_select_db($dbname) or die(mysql_error()); $query = "SELECT poster, message FROM ch_messages order by id DESC LIMIT 5"; $result = mysql_query($query); $marquee = ""; while($r=mysql_fetch_array($result)) {    $marquee.= $r[poster]. ''. $r[message]. '</a>'"; } echo "<marquee><font size='3'>". $marquee. "</font></marquee>"; ?>[/code]
  14. ow yer sweet thanks....im tryin to get a php script workin but i aint havein much look in this forum lol
  15. i found it but 4 sum reason it wnt let me post it on here so  i slapped it on website [url=http://www.runnerselite.com/phpfreaks.html]www.runnerselite.com/phpfreaks.html[/url]
  16. really i swear it should b their what would an expample little bit of the code be??
  17. ohh ok here is index bit [code]include("./config.php"); include("./lang.php"); // array_to_string and string_to_array functions // originally by daenders AT yahoo DOT com on php.net function array_to_string($array) {   $retval = '';   foreach ($array as $index => $value) {       $retval .= urlencode(base64_encode($index)) . '|' . urlencode(base64_encode($value)) . '||';   }   return urlencode(substr($retval, 0, -2)); } function string_to_array($string) {   $retval = array();   $string = urldecode($string);   $tmp_array = explode('||', $string);   foreach ($tmp_array as $tmp_val) {       list($index, $value) = explode('|', $tmp_val);       $retval[base64_decode(urldecode($index))] = base64_decode(urldecode($value));   }   return $retval; } function check_words($string,$banwordz) {   for($i=0;$i<sizeof($banwordz);$i++){     $string=eregi_replace($banwordz[$i], "****", $string);   }   return $string; } function check_ip($bannedipz) {   $isokay = true;   foreach($bannedipz as $banip) {     if ($_SERVER['REMOTE_ADDR'] == $banip) {       $isokay = false;     }   }   return $isokay; } function getTagName($text,$cnt) {         while(($cnt < strlen($text))&&(eregi("[^a-z0-9]",substr($text,$cnt,1))))$cnt++;         $tagNameStart=$cnt;         while(($cnt < strlen($text))&&(!eregi("[^a-z0-9]",substr($text,$cnt,1))))$cnt++;         return substr($text,$tagNameStart,$cnt-$tagNameStart); } function getTagEnd($text,$cnt) {         return strpos($text,">",$cnt); } function closeUnclosedTags($text) {         $openedTags=array();         $cnt=0;         while(($cnt < strlen($text))&&(true))         {                 if(substr($text,$cnt,2)=="</")                 {                         $tagEnd=getTagEnd($text,$cnt);                         $tagName=getTagName($text,$cnt);                         $lastOpenedTag=array_pop($openedTags);                         if($lastOpenedTag==NULL)                         {                                 //error: no tag was opened - delete the close tag                                 $text=substr($text,0,$cnt).substr($text,$tagEnd+1);                         }elseif($lastOpenedTag!=$tagName){                                 //error: closing unopened tag (possible cross-nesting) - return the original opened tag and delete the close tag                                 array_push($openedTags,$lastOpenedTag);                                 $text=substr($text,0,$cnt).substr($text,$tagEnd+1);                         }else{ $cnt=$tagEnd+1; }                 }elseif(substr($text,$cnt,1)=="<"){                         $tagEnd=getTagEnd($text,$cnt);                         $tagName=getTagName($text,$cnt);                         if(substr($text,$tagEnd-1,1)!="/")array_push($openedTags,$tagName);                         $cnt=$tagEnd+1;                 }else{                         $cnt++;                 }         }         while(count($openedTags)>0)$text.="</".array_pop($openedTags).">";         return $text; } function parse_smileys($string) { $smileylist = array(); $i = 0; if ($handle = opendir('./smileys/')) {   while (false !== ($file = readdir($handle))) {       if ($file != "." && $file != "..") {           $smileylist[$i] = str_replace(".gif", "", $file);           $i++;       }   }   closedir($handle); } foreach ($smileylist as $smileycheck){         $string = str_replace(":".$smileycheck.":", "<img src=\"smileys/".$smileycheck.".gif\" />", $string); } return $string; } [/code]
  18. sorry  :) here u go [quote]MA%253D%253D%7CMA%253D%253D%7C%7CMQ%253D%253D%7CUm9i%7C%7CMg%253D%253D%7CaHR0cDovL3d3dy5rdWhhYy5jby51aw%253D%253D%7C%7CMw%253D%253D%7CODMuMTAwLjE5My4xNw%253D%253D%7C%7CNA%253D%253D%7CSVwnbGwgZG8gZ3JhZmZpdGkgaWYgeW91IHNpbmcgdG8gbWUgaW4gZnJlbmNo%7C%7CNQ%253D%253D%7CMTE1NTc2MDg0MA%253D%253D [/quote]
  19. pllleeeaaasssseeeeeeeeee hhhheeelllpppppp
  20. nooooooooo please i need to do this.... is it the code that is writin instead of the text like this  MA%253D%253D%7CMA%253D%253D%7C%7CMQ%253D
  21. hha yer ur point is true lol i dnt know where it is.... any idea where i might find it >???
  22. ok so what do i need to send you.....thanks soooo much 4 duin this :D:D:D:D
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.