عرض مشاركة واحدة
  #1  
قديم 08-16-2011
الصورة الرمزية RSS
RSS غير متواجد حالياً
ناقل الأخبار
 
تاريخ التسجيل: 11 - 2 - 10
المشاركات: 682,465
RSS is on a distinguished road
افتراضي [ اضافة ] ملف الإتصال بقاعدة البيانات مجهز لسكربتك مقدم من مجمع السكريبتات

السلام عليكم
مرحبا بكم من جديد
اليوم أقدم لكم ملف للإتصال بقاعدة البيانات متطور جاهز لسكربتك

لمن أراد تحميله في المرفقات
configdata.txt.rar
(configdata.txt.zip

رمز Code:
define("dbhost", "localhost");
define("dbname", "database_name");
define("usernm", "database_username");
define("passwd", "database_password");
function db_connect()
{
$connection = @mysql_connect(dbhost,usernm,passwd);
if(!$connection)
{
return (array(false, "Connection to MySQL server failed due to incorrect server connection information. Please specify the correct connection crudentials.
MySQL Said: ".mysql_error()));
}

$db = @mysql_select_db(dbname);
if(!$db)
{
mysql_close($connection);
return (array(false, "Connection to MySQL was successful, how ever the database supplied does not exist. Please specify the correct database name."));
}
return (array(true, "connection was successfull."));
}
$database_connected = db_connect();
define("dbhost", "localhost");
define("dbname", "database_name");
define("usernm", "database_username");
define("passwd", "database_password");
function db_connect()
{
$connection = @mysql_connect(dbhost,usernm,passwd);
if(!$connection)
{
return (array(false, "Connection to MySQL server failed due to incorrect server connection information. Please specify the correct connection crudentials.
MySQL Said: ".mysql_error()));
}

$db = @mysql_select_db(dbname);
if(!$db)
{
mysql_close($connection);
return (array(false, "Connection to MySQL was successful, how ever the database supplied does not exist. Please specify the correct database name."));
}
return (array(true, "connection was successfull."));



}
$database_connected = db_connect();
ملف الإتصال بقاعدة البيانات مجهز لسكربتك - المنتدى مجمع السكريبتات - Forums G-Scripts.Com







أكثر...