Fork me on GitHub

Updownload +2MB?  Bottom

Go to page 1 - 2 [+1]:

  • Hey how can i upload files to my site there is bigger then 2 MB?
    i use updownload.
    Please help :D
  • It's a setting in PHP itself, in PHP.ini:

    Code

    ; Maximum allowed size for uploaded files.
    upload_max_filesize = 2M

    You should be able to set it by putting that last line in an .htaccess file (if hosted on Apache).
    If there isn't one already, create a text file with the name .htaccess in your PostNuke root.
  • Sorry i am a noob i am confucedcan you make a step by step thx :D
  • PHP by default sets an upload limit of 2Mb, which is set in its main configuration file.

    You should be able to override that in your site by creating a plain text file (with for instance Notepad, not Word) and entering the line

    Code

    upload_max_filesize = 10M
    (or however many megabytes you want)
    then save as .htaccess. Note the full stop at the beginning. This signifies a hidden system file. On my Windows system at least I can still see them, but on Unix systems, where you presumably are hosted, it is hidden.
    Now upload that file into your PostNuke root.
    Hopefully that should work. I haven't tried it.
  • I don't think you can rename a file to .htaccess on Windows, at least I tried it on my own computer and it didn't work.

    Try uploading the file named as upload.htaccess or something and then rename it when it is inside your postnuke to .htaccess
  • Win Explorer, the unstable piece of crap, doesn't let you rename a file to .htaccess, as it complains there is no filename, thinking everything after the full stop is an extension. But fortunately it doesn't complain about existing ones. What I do is save from a text editor, no problem with the name there. A DOS aficionado (or any Linux user)
    would simply jump on the command line.
    I'm astonished MS, with all their money and resources, still hasn't been able to make something better, faster, and more stable. I have real trouble with folders with a lot of image files in them, even in list view. I need a Mac!!
  • But where schall i place the file?
    In root?
    And overwrite this file

    Quote

    # -FrontPage-

    IndexIgnore .htaccess */.??* *~ *# */HEADER* */README* */_vti*

    .htaccess
    <limit get="get" post="post">
    order deny,allow
    deny from all
    allow from all
    </limit>
    <limit put="put" delete="delete">
    order deny,allow
    deny from all
    </limit>
  • As mentioned, if you already have an htaccess file in your PostNuke root, don't overwrite it. You can add to it. Place it at the top, or at the bottom, it shouldn't matter in this case, as longs as it's not in the middle of the last block of Limit directives.
    That's a curious htaccess file, set by FrontPage it seems.
  • Hmmm diddent work

    When the file was like this.

    Quote


    # -FrontPage-

    IndexIgnore .htaccess */.??* *~ *# */HEADER* */README* */_vti*

    .htaccess
    <limit get="get" post="post">
    order deny,allow
    deny from all
    allow from all
    </limit>
    <limit put="put" delete="delete">
    order deny,allow
    deny from all
    </limit>
    upload_max_filesize = 100M


    The error

    Quote

    Internal Server Error
    The server encountered an internal error or misconfiguration and was unable to complete your request.
    Please contact the server administrator, support@b-one.net and inform them of the time the error occurred, and anything you might have done that may have caused the error.

    More information about this error may be available in the server error log.
  • Try removing the piece of shit that FrontPage set?
  • Then the file will look like this is that okay?

    Quote

    <limit get="get" post="post">
    order deny,allow
    deny from all
    allow from all
    </limit>
    <limit put="put" delete="delete">
    order deny,allow
    deny from all
    </limit>
    upload_max_filesize = 100M
  • Then i get this error.

    Quote

    The page cannot be displayed
    There is a problem with the page you are trying to reach and it cannot be displayed.

    --------------------------------------------------------------------------------

    Please try the following:

    Open the www.gamle-spil.dk home page, and then look for links to the information you want.
    Click the Refresh button, or try again later.

    Click Search to look for information on the Internet.
    You can also see a list of related sites.




    HTTP 500 - Internal server error
    Internet Explorer
  • Please help :D
  • Sorry, I didn't specify correctly.

    I meant try renaming the original .htaccess file to something else like original.htaccess in case you need it.

    Then upload a new .htaccess file with the upload max fie size coding.
  • First of all, I wouldn't recommend removing stuff in it without knowing what it's for just because it's created by FrontPage. They're Apache directives, the first telling it to ignore the sorts of folders FrontPage creates for itself if directory iindexing is allowed. It's harmless, mostly directory listing would be off anyway.
    The second block is a set of allow/deny rules for POST and GET requests. I guess it's automatically generated, because it says
    deny from all
    allow from all

    which cancels each other out. Deny everybody, but also allow everyone. Huh?

    Anyway, I had time to look it up. The syntax I listed is how it is in the PHP.ini file.
    To put it in the htaccess file, which belongs to the Apache server, it needs to be told it's a PHP directive. So:

    Code

    php_value upload_max_filesize 100M

    # -FrontPage-
    IndexIgnore .htaccess */.??* *~ *# */HEADER* */README* */_vti*

    .htaccess
    <Limit GET POST>
    order deny,allow
    deny from all
    allow from all
    </Limit>
    <Limit PUT DELETE>
    order deny,allow
    deny from all
    </Limit>

    I installed UpDownloads to have a look, since if that failed it's possible to give the directive in the script.
    The above worked. UpDownloads keeps it's files in its module folder, so you may also have the .htaccess file in the UpDownloads folder instead. Either way should be fine.
    Note: All this assumes the server isn't set up to ignore htaccess files, which some hosts might. You then either ask your host to allow them for you.

    One more thing:
    UpDownloads has a config file where it also sets max fileupload size. It's located in modules/UpDownload/includes/config.php
    Change the $limit_size variable so it reads:

    Code

    //Filesize-Limit for Upload
    $size_limit = "yes"; //do you want a size limit yes or no. (PHP has got a size-limit too -> see phpinfo() )
    $limit_size = "104857600"; // 100Mb // "2097152"; //How big do you want size limit to be in _bytes_ (1024 byte = 1 kbyte)
    //STOP: A limit is not only set by this variable but may be set by your server through the
    //PHP-variable "upload_max_filesize", too !!!!!

    Notice how it gives the size in Bytes, so 100Mb is 100x1024x1024 = 104857600 bytes. The old value is 2097152, which is 2Mb.

    Well, that should do it.

    Martin

Go to page 1 - 2 [+1]:

  • 0 users

This list is based on users active over the last 60 minutes.