Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6091685
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 23, 20262026-05-23T12:21:22+00:00 2026-05-23T12:21:22+00:00

I have a folder which php uploads to located in the directory above www

  • 0

I have a folder which php uploads to located in the directory above www (/home/user/upload). I have made the folders permissions 770 and made a custom group, which includes user apache and nobody, to own it.

When I do a chgrp mygrp upload, php is able to upload to it, but after it does one time… it all of a sudden can’t write or read from it anymore…

Anyone have any ideas?

====EDIT====

Here is the code I’m currently using to dl a remote file:

$ch = curl_init($url);

$image = TMP_DIR.'/'.getRandomString(10).".{$info->extension}";
while (file_exists($image))
    $image = TMP_DIR.'/'.getRandomString(10).".{$info->extension}";

$image_handle = fopen($image, 'w');
curl_setopt($ch, CURLOPT_FILE, $image_handle);
if (curl_exec($ch) === false)
    throw new Exception('Curl error: '.curl_error($ch), curl_errno($ch));

curl_close($ch);
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-23T12:21:23+00:00Added an answer on May 23, 2026 at 12:21 pm

    Well i feel a bit stupid now… after adding and changing users and groups I never restarted php or apache. So if anyone else ever has this problem make sure you do that first.

    Thanks for your time and help guys!

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a PHP file located in a folder (www.mysite.com/folder/test.php) which accepts a get
I have a php script which uploads images to a temporary folder on the
I have a PHP file which creates a unique directory for each user when
I have a folder FolderA which contains three sub-folders: foldera1 foldera2 and foldera3 I
i have created folder on my server (ie finesse)- 'home' in which i have
I have index.php which uploads a file to server and sets several PHP variables
the procedure: i have a script which uploads images (via hmtl-form and php) for
I have a small form in which the user uploads a file. What I
i have a form which allows the user to upload some files to a
I have a PHP web application running on IIS, which allows a user to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.