/    Sign up×
Community /Pin to ProfileBookmark

[RESOLVED] chmod Problem

[CODE]if (!file_exists($filename)):
if(mkdir($path.”users/”.$folder.”/”, 0755)){
$file = $path.’blank.xml’;
$newfile = $path.’users/’.$folder.’/trophies.xml’;

if(copy($file, $newfile)){
setcookie(“cache”, ‘ok’, time()+432000, ‘/’); /* expire in 6 hours */
update_cache($folder, $path); //write to the xml file
}else{
echo(‘ERROR, ‘.$path.’, ‘.$folder);
header( ‘Location: clear.php’ ) ;
die;
}
}else{
echo(‘ERROR, ‘.$path.’, ‘.$folder);
header( ‘Location: clear.php’ ) ;
die;
}
endif;

chmod($path.’users/’.$folder.’/’, 0755);
chmod($path.’users/’.$folder.’/trophies.xml’, 0755);[/CODE]

i cant get my folder & file to be 755 should this work ?

to post a comment
PHP

1 Comments(s)

Copy linkTweet thisAlerts:
@gavshouseauthorDec 13.2008 — i found the problem i put this

[CODE]
chmod($path.'users/'.$folder.'/', 0755);
[/CODE]


which should of been this

[CODE]
chmod($path.'users/'.$folder, 0755);
[/CODE]
×

Success!

Help @gavshouse spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.3,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,

tipper: @Samric24,
tipped: article
amount: 1000 SATS,
)...