Warning: mysql_select_db() expects parameter 2 to be resource, null given in C:\Users\WINDOWS7\Desktop\USBWebserver v8.6\root\comservices\backend\services.php on line 117
Warning: mysql_query() expects parameter 2 to be resource, null given in C:\Users\WINDOWS7\Desktop\USBWebserver v8.6\root\comservices\backend\services.php on line 120
$conn = mysql_connect("host", "user", "password");
mysql_select_db('database_name', $conn);
จริงๆ แนะนำให้ใช้ mysqli หรือ PDO ครับ
https://programmerthailand.com/blog/view/117/%E0%B9%80%E0%B8%A1%E0%B8%B7%E0%B9%88%E0%B8%AD-php-%E0%B9%80%E0%B8%95%E0%B8%B7%E0%B8%AD%E0%B8%99-deprecated-mysql-function-%E0%B8%88%E0%B8%B0%E0%B9%80%E0%B8%A5%E0%B8%B4%E0%B8%81%E0%B9%83%E0%B8%8A%E0%B9%89-mysql-function-%E0%B9%81%E0%B8%A5%E0%B9%89%E0%B8%A7%E0%B8%99%E0%B8%B0
https://programmerthailand.com/blog/view/67/php-pdo-%E0%B8%84%E0%B8%B7%E0%B8%AD%E0%B8%AD%E0%B8%B0%E0%B9%84%E0%B8%A3
ตอบ/อธิบาย