المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : [شرح] : تغيير اسم ملف Config من خلال سطرين فقط


فارس قطر
15-12-08, 02:50 PM
بسم الله الرحمن الرحيم

التعديل يفيدك لزيادة حماية موقعك

نظرا لكثرة الاختراقات عن طريق قراءة معلومات Config

ثم الاتصال بقاعدة موقعك .. التعديل راح يصعب على المخترق الوصول للملف

نبدأ الشرح

افتح ملف class_core.php واللي راح يكون موجود على هذا المسار رمز PHP:
vb/includes/class_core.php





وابحث عن
رمز Code:
include(CWD . '/includes/config.php');

if (sizeof($config) == 0)
{
if (file_exists(CWD. '/includes/config.php'))
{
// config.php exists, but does not define $config
die('

Configuration: includes/config.php exists, but is not in the 3.6+ format. Please convert your config file via the new config.php.new.');
}
else
{
die('

Configuration: includes/config.php does not exist. Please fill out the data in config.php.new and rename it to config.php');
}
}
استبدله بالتالي

رمز Code:
include(CWD . 'katm');

if (sizeof($config) == 0)
{
if (file_exists(CWD. 'katm'))
{
// config.php exists, but does not define $config
die('

Configuration: includes/config.php exists, but is not in the 3.6+ format. Please convert your config file via the new config.php.new.');
}
else
{
die('

Configuration: includes/config.php does not exist. Please fill out the data in config.php.new and rename it to config.php');
}
}
استبدل كلمة katm باسم ملف الكوفينق بعد اعادة تسميته

الموضوع مترجم من الفي بي اورق

عند نقله يرجى الاشارة الى مصدره (http://www.elwdad.com/vb/t32636/)