หากเว็บไซต์แสดงผลไม่ได้ ขึ้นข้อความ No input file specified ดังรูป



ปัญหานี้เกิดจากไฟล์ .htaccess ครับ

ขั้นแรก เข้าไปที่ Control Panel จากนั้นไปที่เก็บไฟล์เว็บไซต์
เปิดไฟล์ .htaccess ขึ้นมา หาก Code ในไฟล์ .htaccess เป็นดังนี้

RewriteEngine on
RewriteCond $1 !^(index\.php|css|gfx|js|swf|robots\.txt|favicon\.ico)
RewriteRule^(.*)$ /index.php/$1 [L]



ให้ทำการแก้ไข Code เป็น

DirectoryIndex index.php

RewriteEngine on
RewriteBase/RewriteCond%{REQUEST_FILENAME}!-f
RewriteCond%{REQUEST_FILENAME}!-d
RewriteCond $1 !^(index\.php|robots\.txt)RewriteRule^(.*)$ index.php?/$1 [L]



หลังจากแก้ไข Code เรียบร้อยแล้ว เราก็มาดูที่ permission ของไฟล์ .htaccess ครับ ให้ตั้งค่า permission เป็น 755 เท่านั้นครับ

เพียงเท่านี้เว็บไซต์ก็จะแสดงผลได้ตามปกติครับ :)

Was this answer helpful? 14 Users Found This Useful (16 Votes)