Welcome Guest, Not a member yet? Register   Sign In
Problem uploading picture
#5

(09-11-2019, 03:21 AM)mandiatutti Wrote:
PHP Code:
<?php if(is_writable(base_url('assets/profiles'))){
    echo 'writable';
}
else { 
echo  (base_url('assets/profiles'). ' ' ."is not writable");} ?>
 This code is always returning me that is not writable, but on terminal i have these permissions on the folder: drwxrwxrwx, which I obtained with chmod 777 profiles/

is_writable check if a local file or a directory is writable but you pass an URL! Don't use base_url, pass the path to the local directory.
CodeIgniter 4 tutorials (EN/FR) - https://includebeer.com
/*** NO support in private message - Use the forum! ***/
Reply


Messages In This Thread
Problem uploading picture - by mandiatutti - 09-11-2019, 03:21 AM
RE: Problem uploading picture - by InsiteFX - 09-11-2019, 08:14 AM
RE: Problem uploading picture - by mandiatutti - 09-11-2019, 09:50 AM
RE: Problem uploading picture - by InsiteFX - 09-11-2019, 05:57 PM
RE: Problem uploading picture - by includebeer - 09-12-2019, 12:58 PM
RE: Problem uploading picture - by mandiatutti - 09-16-2019, 01:26 AM
RE: Problem uploading picture - by mboufos - 09-16-2019, 05:53 AM
RE: Problem uploading picture - by mandiatutti - 09-16-2019, 06:11 AM
RE: Problem uploading picture - by yeumaytinh - 06-15-2020, 06:50 AM



Theme © iAndrew 2016 - Forum software by © MyBB