عرض مشاركة مفردة
 
  #3  
قديم 19-08-2007, 05:27 AM
roudyhermez roudyhermez غير متصل
عضو
 
تاريخ التسجيل: Aug 2007
مشاركة: 2
مستوى تقييم العضوية: 0
roudyhermez is on a distinguished road
الافتراضي

في صفحة mainfile

ملاحظة : خذ نسخة احتياطية من الملف قبل العمل

ابحث عن الكود التالي


كود PHP:
 
 
function check_html ($str$strip="") {
/* The core of this code has been lifted from phpslash */
/* which is licenced under the GPL. */
include("config.php");
if (
$strip == "nohtml")
$AllowableHTML=array('');
$str stripslashes($str);
$str eregi_replace("<[[:space:]]*([^>]*)[[:space:]]*>",'<\\1>'$str);
// Delete all spaces from html tags .
$str eregi_replace("<a[^>]*href[[:space:]]*=[[:space:]]*\"?[[:space:]]*([^\" >]*)[[:space:]]*\"?[^>]*>",'<a href="\\1">'$str);
// Delete all attribs from Anchor, except an href, double quoted.
$str eregi_replace("<[[:space:]]* img[[:space:]]*([^>]*)[[:space:]]*>"''$str);
// Delete all img tags
$str eregi_replace("<a[^>]*href[[:space:]]*=[[:space:]]*\"?javascript[[:punct:]]*\"?[^>]*>"''$str);
// Delete javascript code from a href tags -- Zhen-Xjell @ http://nukecops.com
$tmp "";
while (
ereg("<(/?[[:alpha:]]*)[[:space:]]*([^>]*)>",$str,$reg)) {
$i strpos($str,$reg[0]);
$l strlen($reg[0]);
if (
$reg[1][0] == "/"$tag strtolower(substr($reg[1],1));
else 
$tag strtolower($reg[1]);
if (
$a $AllowableHTML[$tag])
if (
$reg[1][0] == "/"$tag "</$tag>";
elseif ((
$a == 1) || ($reg[2] == "")) $tag "<$tag>";
else {
# Place here the double quote fix function.
$attrb_list=delQuotes($reg[2]);
// A VER
$attrb_list ereg_replace("&","&amp;",$attrb_list);
$tag "<$tag$attrb_list ">";
# Attribs in tag allowed
else $tag "";
$tmp .= substr($str,0,$i) . $tag;
$str substr($str,$i+$l);
}
$str $tmp $str;
return 
$str;
exit;
/* Squash PHP tags unconditionally */
$str ereg_replace("<\?","",$str);
return 
$str;

و احذفه نهائياً ثم جرب