Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

WordPress

Kael McDonald
Kael McDonald
2,180 Points

Accessing CPanel via Webhostingforstudents. Trying to adjust max_file_upload_size, but how can I create a php.ini file?

Hello everyone,

I am trying to install a larger theme to my WP site, and I'm encountering the error with max_file_upload_size being exceeded (it's an LMS theme, fairly large). From what I have researched on the subject, I should be able to edit my php.ini file to change the value to something higher than the 2Mb default. Unfortunately, there is no php.ini file within my File Manager on CPanel, and I can't find any information on generating one - at least not through the CPanel options that Webhostingforstudents provides.

Could anyone tell me how I might generate a php.ini file, so that I can adjust the max_file_upload_size?

Thanks in advance!

4 Answers

Hi Kael,

You shouldn't need to upload a file that size very often. However, in the case that you do, try using an FTP client. You should've received login credentials when you signed up, and you'll want to use it with a program like Cyberduck or Filezilla. According to the FAQ section, the SFTP port is 18765.

Simply unzip the theme and place it in wp-content/themes/. From there, you should now see the theme within the Wordpress admin area via AppearanceThemes. You can now activate the theme. Hope this solution helps solve your issue, if not let me know, and I'll see what else I can recommend.

Logan R
Logan R
22,989 Points

I could be completely wrong, but I think standard web hosts with Cpanel do not allow for you to edit php.ini if you do not have root access.

Kael McDonald
Kael McDonald
2,180 Points

Thank you both for your timely responses!

Dustin, you've confirmed what I've suspected - that I need to get an FTP client. A friend of mine uses Wordpress for his site but doesn't require an FTP client, so I was doing my best to avoid that being the answer. :)

I've heard good things about Cyberduck, so I will check into that and follow your instructions. I suspect it will go well, but either way I'll come back and let you know. Thanks again!

Kael McDonald
Kael McDonald
2,180 Points

Sorry it took me some time, but to follow up:

Cyberduck did the trick. :)

I hadn't realized it was a free application, or else I would have tried it initially; nonetheless, it was a surprisingly simple thing to connect to my website and install the theme I needed. I greatly appreciate the help.

In case anyone is interested, you can also contact your hosting company to raise the max_file_upload_size for you, but they'll only take it up so much, depending on who you go through. In my own case, webhostingforstudents increased me from 2Mb to 18Mb, which unfortunately didn't meet my requirements.