Welcome Guest, Not a member yet? Register   Sign In
Creating a uniqd id for users upload folder name
#1

Hi, I am just trying to get some ideas what best and whats not.

I was thinking when user creates a new account it also creates a upload folder for that user using its date_joined time()

The users folder would be in time() format


PHP Code:
$userdata $this->user_model->getuser($this->user_model->getuserid());

if (!
is_dir(FCPATH 'uploads/' $userdata['date_created'])) {
    mkdir(FCPATH 'uploads/' $userdata['date_created'], 0777true);


Out put

PHP Code:
C:\xampp\htdocs\project\uploads/1487475460 

Is that OK or if you have any other suggestions
There's only one rule - please don't tell anyone to go and read the manual.  Sometimes the manual just SUCKS!
Reply


Messages In This Thread
Creating a uniqd id for users upload folder name - by wolfgang1983 - 03-04-2017, 08:12 PM



Theme © iAndrew 2016 - Forum software by © MyBB