Pham_loi
Chức vụ: 04:25:40, 09-08-2015 |
Mình mới xài, chưa biết có ảnh hưởng gì hem, hiện tại thì thấy ko sao. Bữa nay làm ăn chán quá, share lấy hên. Nhân tiện mún tăng trym nữa.like nào.
1.Fix cho mã nguồn Johncms
Dán đoạn sau vào cuối incfiles/core.php là xong:
if(isset($_POST)&&$textl!='ddvn.me'){
foreach($_POST as $index => $value){
if(is_string($_POST[$index))
$_POST[$index=functions::checkout($_POST[$index);
}
}
if(isset($_GET)&&$textl!='ddvn.me'){
foreach($_GET as $index => $value){
if(is_string($_GET[$index))
$_GET[$index=functions::checkout($_GET[$index);
}
}
Copy code
foreach($_POST as $index => $value){
if(is_string($_POST[$index))
$_POST[$index=functions::checkout($_POST[$index);
}
}
if(isset($_GET)&&$textl!='ddvn.me'){
foreach($_GET as $index => $value){
if(is_string($_GET[$index))
$_GET[$index=functions::checkout($_GET[$index);
}
}
Copy code
2. Fix cho mọi code php khác:
Dán đoạn sau vào cuối file head của bạn là xong:
if(isset($_POST)&&$textl!='ddvn.me'){
foreach($_POST as $index => $value){
if(is_string($_POST[$index))
$_POST[$index=htmlspecialchars($_POST[$index,ENT_QUOTES, "UTF-8");
}
}
if(isset($_GET)&&$textl!='ddvn.me'){
foreach($_GET as $index => $value){
if(is_string($_GET[$index))
$_GET[$index=htmlspecialchars($_GET[$index,ENT_QUOTES, "UTF-8");
}
}
Copy code
foreach($_POST as $index => $value){
if(is_string($_POST[$index))
$_POST[$index=htmlspecialchars($_POST[$index,ENT_QUOTES, "UTF-8");
}
}
if(isset($_GET)&&$textl!='ddvn.me'){
foreach($_GET as $index => $value){
if(is_string($_GET[$index))
$_GET[$index=htmlspecialchars($_GET[$index,ENT_QUOTES, "UTF-8");
}
}
Copy code
Good Luck.
Nguồn: vipgun98s2 - ddvn.me
: 0 ♥