limiting the upload file sizes and overall storage amounts

Posted on 2010-01-06
Last Modified: 2012-05-08

We are currently using (install on a win server) for managing our projects however we have come across a flaw. There is no way to limit the amount of data uploaded into the document area or file size of the opject being uploaded.

We are considering the option of building our own activecollab module to:
- limit the amount of data stored.
- limit the file size of the object uploaded.
- limit the types of files that can be uploaded by extension type.

This feature is quite common in other applications, we are just wondering if someone could please explain the logic behind it so that we can draft technical requirements.

Thanks :)
Question by:PlumInternet
    LVL 40

    Accepted Solution

    LVL 5

    Assisted Solution

    Say the below is the file uploader:-

    <input type="file" name="company_logo" />

    Using PHP we can find the filesize using


    We can find the type of the file using


    For images the file type will be as follows-

    "image/extension of the image"  - For example :- "image/jpeg" -> For a jpeg image.

    You can use these to

    - limit the amount of data stored.
    - limit the file size of the object uploaded.
    - limit the types of files that can be uploaded by extension type.
    LVL 5

    Expert Comment

    I had a look at ur site which is developed in PHP .. Thats y i suggested the above methods in PHP..

    Author Closing Comment

    Not very specific to windows and activecollab

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    Join & Write a Comment

    Introduction Knockoutjs (Knockout) is a JavaScript framework (Model View ViewModel or MVVM framework).   The main ideology behind Knockout is to control from JavaScript how a page looks whilst creating an engaging user experience in the least …
    Active Directory replication delay is the cause to many problems.  Here is a super easy script to force Active Directory replication to all sites with by using an elevated PowerShell command prompt, and a tool to verify your changes.
    The viewer will learn how to count occurrences of each item in an array.
    In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…

    733 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    24 Experts available now in Live!

    Get 1:1 Help Now