Skip to content

Tag: wordpress

PHP – Uploading multiple files

I’m working on a plugin for wordpress and I want to be able to upload multiple pictures from a form. Right now when I have a form for two pictures and submit it empty, my $_FILES array looks like this: Now the problem is that I want to use wordpress’ upload handler, wp_handle_upload. It expects th…

How do I add static pages to WordPress?

How do I add my own static HTML pages to WordPress? For example, let’s say I have a page, products.html, how would I add it to WordPress (any menu, etc.) and once added, how do I visit them, because WordPress had a typical URL structure? Answer The static page functionality of WordPress is called, cleve…

Create a folder if it doesn’t already exist

I’ve run into a few cases with WordPress installs with Bluehost where I’ve encountered errors with my WordPress theme because the uploads folder wp-content/uploads was not present. Apparently the Bluehost cPanel WordPress installer does not create this folder, though HostGator does. So I need to a…