Re: problems with uploads to wordpress

Steve Holdoway <[email protected]> Sat, 03 Dec 2011 13:26:38 +1300
Newsgroups gmane.org.user-groups.linux.new-zealand.general
Organization Green Gecko Global Ltd.
Message-ID <1322871998.2554.410.camel@steve-desktop>
--===============1553477974==
Content-Type: multipart/signed; micalg="sha1";
	protocol="application/x-pkcs7-signature";
	boundary="=-pW6tuQL7+w+v0d/Au/73"


--=-pW6tuQL7+w+v0d/Au/73
Content-Type: text/plain; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

On Sat, 2011-12-03 at 12:59 +1300, Robin Paulson wrote:
> On Sat, 03 Dec 2011 12:47:43 +1300, Steve Holdoway wrote:
> > On Sat, 2011-12-03 at 12:22 +1300, Robin Paulson wrote:
> >> On Sat, 3 Dec 2011 11:28:13 +1300, David Pando wrote:
> >> >> size. i can upload a small png no problem, but the 3.6MB .xpi=20
> >> files
> >> >> causes
> >> >> problems as it is beyond the maximum of 2MB. so, i increased the
> >> >> value of
> >> >> upload_max_filesize in /etc/php5/apache2/php.ini to 5MB, but it
> >> >> still fails
> >> >>
> >> >>
> >> >>
> >> > Increasing upload_max_filesize is not usually enough, as you also
> >> > have to
> >> > increase post_max_size .
> >>
> >>  that's at 8MB already, should it be bigger than upload_max_filesize=20
> >> by
> >>  some factor?
> >>
> > You can also set  MAX_FILE_SIZE in a form to limit it. Also, check=20
> > that
>=20
>  i'm not sure what you mean by "a form"
Most uploads are controlled by a button saying 'go'. In the pre-ajax
world at least. This is encompassed in a <form></form> block.
>=20
> > the default upload_max_filesize and post_max_size aren't being
> > overridden either in code or .htaccess.
>=20
>  i haven't defined any .htaccess files, where in the code is it likely=20
>  to be altered? the web searches i ahve found point to wordpress taking=20
>  whatever is defined by php as the limiting factor
>=20
Exactly.

Defaults are in /etc/php.ini ( or in your debian/ubuntu /  apache
case /etc/php5/apache2/php.ini ).
    upload_max_filesize =3D 2M

Overrides can be put in .htaccess
    php_value  upload_max_filesize  2M

Or in php code
    ini_set("upload_max_filesize", "2M");

hth,

Steve

--=20
Steve Holdoway BSc(Hons) MNZCS <[email protected]>
http://www.greengecko.co.nz
MSN: [email protected]
Skype: sholdowa

--=-pW6tuQL7+w+v0d/Au/73--



--===============1553477974==
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
NZLUG mailing list [email protected]
http://www.linux.net.nz/cgi-bin/mailman/listinfo/nzlug

--===============1553477974==--