Thank you very much for the help, I got the smileys working. found out what I needed to do was CHMOD each image over to 0777. Now I seem to have a problem with getting the other pages to work when I press the sign button.
The sign button is programmed to activate gb_sign.php which makes sense. Im just not sure whats stopping it from activating. I tried CHMOD 0777 like the images but that didnt help
Any suggestions?
Here is gb_sign.php
Code:
<?
include("gb_config.php");
$dosign = $_REQUEST['dosign'];
$pcode = md5($spam_protection_code);
$scheck = $pcode{0}.$pcode{2}.$pcode{4}.$pcode{1}.$pcode{5};
if($dosign == $scheck){
$page = $_REQUEST['page'];
$name = $_POST['name'];
$homepage = $_POST['homepage'];
$email = $_POST['email'];
$message = $_POST['message'];
$ip = $_SERVER['REMOTE_ADDR'];
$browser = getBrowser($_SERVER['HTTP_USER_AGENT']);
$stime = time();
if (trim($name) && trim($message)){
if ($flood_protection != "0"){
if ($_COOKIE['signed'] == "yes") {
echo("$la21");
exit;
}
}
//Cut name's length
$name = cut_str($name, 35);
//Check for valid email
if(strpos ($email, '@') === false){
$email = "";
}
if (!(file_exists($data_file))){
fopen($data_file,"w");
}
$message = scheck($message);
$name = scheck(trim($name));
$email = scheck(trim($email));
$homepage = scheck(trim($homepage));
$message = ereg_replace("\r", "", $message);
$message = ereg_replace("\n", "<br> ", $message);
$new_entry = $name."|".$homepage."|".$email."|".$message."|".$ip."|".$stime."|".$browser."\n";
$data=fopen($data_file,"a+");
flock($data, LOCK_EX);
fwrite($data,$new_entry);
flock($data, LOCK_UN);
fclose($data);
//End writing entry
}else{
echo("$la22");
}
}else{//end dosign
echo("$la23");
}
function scheck($value){
global $bad_words;
$value = strip_tags($value);
$value = stripslashes($value);
$value = ereg_replace("\|", "", $value);
if(trim($bad_words) != ''){
$filter = explode(',',$bad_words);
foreach ($filter as $badword){
$value = ereg_replace($badword," **** ",$value);
}
}
return $value;
}
//Get Browser Type Function by Daniel.
function getBrowser($userAgent) {
$browsers = array(
'Opera' => 'Opera',
'Mozilla Firefox'=> '(Firebird)|(Firefox)',
'Galeon' => 'Galeon',
'Mozilla'=>'Gecko',
'MyIE'=>'MyIE',
'Lynx' => 'Lynx',
'Netscape' => '(Mozilla/4\.75)|(Netscape6)|(Mozilla/4\.08)|(Mozilla/4\.5)|(Mozilla/4\.6)|(Mozilla/4\.79)',
'Konqueror'=>'Konqueror',
'SearchBot' => '(nuhk)|(Googlebot)|(Yammybot)|(Openbot)|(Slurp/cat)|(msnbot)|(ia_archiver)',
'Internet Explorer 7' => '(MSIE 7\.[0-9]+)',
'Internet Explorer 6' => '(MSIE 6\.[0-9]+)',
'Internet Explorer 5' => '(MSIE 5\.[0-9]+)',
'Internet Explorer 4' => '(MSIE 4\.[0-9]+)',
);
foreach($browsers as $browser=>$pattern) {
if(eregi($pattern, $userAgent)) {
return $browser;
}
}
return 'Unknown';
}
//Cut the length of a string
function cut_str($str, $length){
if(strlen($str) > $length){
for ($i=0; $i<$length; $i++){
$cut_name = $cut_name.$str[$i];
}
return $cut_name;
}else{
return $str;
}
}
?>