Nếu bạn gặp lỗi này:

Warning: touch() [function.touch]: SAFE MODE Restriction in effect. The script whose uid is xxx is not allowed to access /tmp owned by uid 0 in /full_path_to_wordpress/wp-admin/includes/file.php on line 198

Hoặc

Warning: unlink() [function.unlink]: SAFE MODE Restriction in effect. The script whose uid is xxx is not allowed to access /tmp owned by uid 0 in /home/powernet/domains/powernet.vn/public_html/home/wp-admin/includes/file.php on line 489

Có nghĩa rằng server đang bật chế độ safe mode On.

Cách khắc phục như sau:
Tạo một thư mục con trong thư mục public_html với tên tùy chọn ( ở đây là mình đặt tên thư mục là tmp). Sau đó CHMOD 777

Sau đó bạn sửa file wp-config.php, thêm vào dưới dòng này

require_once(ABSPATH . 'wp-settings.php');

dòng giá trị sau:

define('WP_TEMP_DIR', ABSPATH . 'tmp');

Save và sử dụng bình thường.

Lưu ý: Việc Chmod 777 có thể gây nguy cơ cao về bảo mật, nếu không thực sự cần thiết nên chmod về 755. Ngoài ra nên Chmod thư mục public_html thành 711
31 Jan 2015

Đăng nhận xét Blogger

Emoticon
:) :)) ;(( :-) =)) ;( ;-( :d :-d @-) :p :o :>) (o) [-( :-? (p) :-s (m) 8-) :-t :-b b-( :-# =p~ $-) (b) (f) x-) (k) (h) (c) cheer
Click to see the code!
To insert emoticon you must added at least one space before the code.

 
Top