Platform: Microsoft Windows XP
Programming language: PHP
Web server: IIS
ปัญหา: ไม่สามารถส่ง mail ใน PHP
Programming language: PHP
Web server: IIS
ปัญหา: ไม่สามารถส่ง mail ใน PHP
มีสาวน่ารัก มาปรึกษาว่าทำไมส่ง mail ด้วย function mail ไม่ได้ (ตั้งนานแล้วเพิ่งจะ update)
ก็เลยเอามาลองที่เครื่อง ปรากฎว่าขึ้น error เป็น
"Warning: mail() [function.mail]: SMTP server response: 550 5.7.1 Unable to relay for ..."
วิธีแก้ก็คือ
1. เปิด Control Panel เลือก Administrative Tools
2. เลืิอก Internet Information Services
3. เลือก [Local computer]
4. click ขวา ที่ Default SMTP Virtual Server เลือก Properties
5. เลือก tab Access
6. ที่ Relay Restrictions, click ที่ Relay แล้ว click Add
7. เลือก Single Computer แล้วใส่ IP address เป็น 127.0.0.1
1. เปิด Control Panel เลือก Administrative Tools
2. เลืิอก Internet Information Services
3. เลือก [Local computer]
4. click ขวา ที่ Default SMTP Virtual Server เลือก Properties
5. เลือก tab Access
6. ที่ Relay Restrictions, click ที่ Relay แล้ว click Add
7. เลือก Single Computer แล้วใส่ IP address เป็น 127.0.0.1
แต่สุดท้ายก็แก้ปัญหาให้สาวผู้น่ารักไม่ได้ เพราะสาวเจ้าใช้ Web server เป็น Apache
ซึ่งพยายามลง Apache แ้ล้วก็ไม่สำเร็จ แต่ลง Appserv ได้ -_-"
