The tag has no wiki summary.

learn more… | top users | synonyms (3)

24
votes
1answer
1k views

Add multiple plugin directories

The task You can register add additional Themes directories using register_theme_directory() for your WP installation. Sadly core doesn't deliver with the same functionality for plugins. We already ...
15
votes
9answers
3k views

How to structure a plugin

This isn't a question about how to build a WordPress plugin. Rather, what, if any, guides could be applied to how to put together the file architecture of any plugin. Some other programming languages ...
10
votes
1answer
2k views

Custom Post Type Templates from Plugin Folder?

I'd like to offer my custom post type as a Plugin, so that people can use it without touching their theme folder. But custom post type templates -- such as single-movies.php -- reside in the theme ...
9
votes
1answer
135 views

How MUST the directory for a plugin be structured?

I get the basic plugin concept. I've read the Codex article on Writing a Plugin That article talks about the "main plugin file". How does Wordpress determine "the main plugin file" ? Q1: Is it ...
8
votes
7answers
16k views

Cannot access non-wordpress subdirectories as wordpress overrides them with a 404 error

I refer to this question previously asked and not suitably answered: Wordpress overriding actual subdirectories and also Non "Wordpress" pages/code getting 404 error. I have the same ...
7
votes
5answers
7k views

Can wordpress theme folder name be changed freely and nothing technically happens

Can the wordpress theme folder be renamed any time freely and everything works fine after that , themes/oldthemename themes/whatevernewname or is it so that if you change the folder name that ...
7
votes
1answer
4k views

get_template_directory() vs bloginfo( 'template_directory' ) vs TEMPLATEPATH

I was reading this article: Common WordPress Development Mistakes and How to Fix Them, and in it, they author says: Getting the theme location: If you are using TEMPLATEPATH or bloginfo( ...
7
votes
1answer
3k views

Moving a WP Multisite to a subdirectory

Firstly, I've read a number of posts on this process. However, for various reasons, the process remains difficult to implement or troubleshoot for lack of even abstracted examples, or maybe too ...
6
votes
2answers
216 views

Categorising themes by folders in backend

I want to organize themes like: wp-content/themes/themeshop/theme1 wp-content/themes/themeshop/theme2 wp-content/themes/themeshop/theme3 Now from my understanding, this organization works ...
5
votes
1answer
2k views

Change upload directory for PDF files

I would like to change the upload directory for PDF files only, not for other files. For example, the PDF files would be uploaded to wp-content/uploads/pdf but other files would remain in ...
5
votes
2answers
799 views

File and directory permissions

I installed latest WordPress 3.5 in my CentOS server. When I tried accessing http://example.com/wp-includes/, I received a listing of the directory: (Index of wp-includes). I added the following code ...
5
votes
1answer
2k views

Use a separate upload folder for custom post attachment upload

So, i'm trying to find out a way to use two separate upload folders, being the default one wp-content/uploads for general media uploads, and another one say wp-content/custom for one specific type of ...
4
votes
3answers
4k views

What is the best way to get directory path for wp-config.php?

I am developer of the plugin mapsmarker.com which also offers several APIs which can be accessed directly (eg www.mapsmarker.com/wp-content/plugins/leaflet-maps-marker/leaflet-geojson.php?marker=1) ...
4
votes
1answer
90 views

How to individually set WP_DEBUG on a sub-directory multisite?

According to this question, it's possible to turn on/off WP_DEBUG for specific sites on a multisite. Is it possible to do this with a sub-directory multisite?
4
votes
2answers
810 views

Get a path to a different plug-in

To get a the path to a plugin you can use plugin_dir_path(__FILE__) - but this obviously has to be called from within the plug-in. How can you reliably get the path to plugin B (pluginb/pluginb.php) ...
3
votes
4answers
427 views

Dash or underscore in theme folder name?

I'm confused and I didn't find any answer by Googling. My theme files such as single.php or header.php reside in a folder. Should I use dashes or underscores in the folder name? My web server run on ...
3
votes
3answers
846 views

How to create a mini directory in WordPress?

I'm looking to create a simple directory, something similar but not so powerful as SOBI2 for Joomla. Is there something like this for Wordpress? I want to store informations like: Name URL Address ...
3
votes
2answers
593 views

Creating a Link Directory using WordPress?

I would like to create a dmoz like website, using WP. Any suggestions on plugins or site's architecture would be welcomed.
3
votes
3answers
3k views

Benefits or Problems for using Sub-Directory vs Sub-Domain install of WP Network

Reading through the documentation you have the ability to setup a WP Network in two ways, Sub-Domains and Sub-Directories. The only explanation they give you is Sub-directory sites It works with ...
3
votes
3answers
669 views

Changing directory and/or URL structure

I'm curious if its possible (and advisable) to change certain directory names and URL structure via customization by themes or plugins. For example, say I wanted the list of all a user's posts to ...
3
votes
1answer
128 views

Isolating WordPress to a subfolder

I'm trying to isolate a wordpress installation on our site to a specific subfolder. I created a folder on our root site named _wp and placed all the wordpress files in there. I added the following ...
3
votes
0answers
76 views

A way to sort WordPress themes? [closed]

I want to write a plugin which can sort themes into categories. For example I have Categories 3 themes in Business as subfolder from /themes/business 7 themes in Nature /themes/nature 2 themein in ...
2
votes
2answers
10k views

How to get the path to the current theme?

This code is used to get the directory of the current plugin: plugin_dir_url( __FILE__ ). What should I use to get the directory of the current theme?
2
votes
3answers
1k views

Sending form data via PHPMailer - How to action PHP script from a form

Some easy points on offer... I wish to action a PHP script from a WordPress page but where is the best place to store the script? The script works perfectly fine using a non-WordPress environment in ...
2
votes
2answers
880 views

Why doesn't WP_PLUGIN_DIR definition use DIRECTORY_SEPARATOR?

Whilst writing some code that backs-up a plugin, I hit a problem with 'the wrong kind of directory slash' on my windows dev environment. Tracking it through I find in default-constants.php:91 ...
2
votes
2answers
80 views

When developing a distributable Theme, does it HAVE to be “inheritable”?

I'm currently developing a complex Theme (or framework, if it can be called that) for my own personal use. However, in the event that it becomes appreciated to the public - does it necessarily HAVE ...
2
votes
2answers
429 views

Post Ancestor and Child Post in Custom Post Type

Hierarchical structure of custom post type "Book" (for example). When we are on Post 2-95, I want to know: Does the post has this post ancestor(Post 1-31)? Does it have child posts(Post 3-19, ...
2
votes
1answer
107 views

Hosting plugin Google Code with auto update?

I've been developing a WordPress plugin for a friend who needs something completely out-of-the-box, at least what WordPress is cornerned. Now, I could use the WordPress plugin repository to host this, ...
2
votes
2answers
527 views

How is a student directory best handled in WordPress?

I am doing a WordPress site for a school. One of the pages would have a list of 20 or so students, which would include their name, photo and small blurb. How is this type of thing handled in ...
2
votes
1answer
4k views

Wordpress .htaccess subdirectory problem

I've been having some issues with my Wordpress install allowing me to access subdirectories, specifically a CodeIgniter install at mydomain.com/codeigniter. I know that technically it should work just ...
2
votes
1answer
105 views

register_theme_directory somehow “fails” when folder is outside of WP-Folder

This is a simple skeleton for WordPress, that makes it possible to have just "themes" and "plugins" under version control: https://github.com/sourcerer-mike/WordPress-GIT-Skeleton When doing ...
2
votes
1answer
101 views

How can the temporary update directory be changed?

When a plugin, theme, or even WordPress itself are updated, it downloads and saves the files (.zip, extracted files, etc.) to wp-content\upgrade. This is not always desirable. For example, I run a ...
2
votes
1answer
641 views

How do I set up single sign on for multiple WP installs across the same domain?

I want to set up multiple WP installs in a few subdirectories. For example, one WP install would live at mydomain.com/blog. Another WP install might live at mydomain.com/project1 and another might ...
2
votes
2answers
354 views

Want to turn Wordpress into a paid subscription directory

I need to create a paid subscription directory where people can register their business and enter its details. Subscriptions should be paid on a monthly or yearly basis. Business details include ...
2
votes
1answer
2k views

Wordpress 3.0 Media Upload Directory

I am using Wordpress 3.0 and would like to organize the directory where uploads are made. Is there any way to change where the files get uploaded or is the only real organization the Media tag plugin? ...
2
votes
1answer
95 views

Second wordpress installation on subdirectory

I currently have a blog setup as a subdomain on my website as, to my knowledge, it's the only way to use a different WordPress theme. Am I able to setup another WordPress installation on my current ...
2
votes
2answers
199 views

Custom Post Type Archive in Sub Folder

I have a sub-directory in my Wordpress theme (there are a lot of pages and I want a more logical structure). I have a custom post type called "entry" but if I place the archive-entry.php template in ...
2
votes
2answers
478 views

Opendir and Wordpress Path

I wrote a simple function to get the contents in a folder (called templates) in my wordpress plugin, but am having problems getting the path to work (thus the function always dies). My question is: ...
2
votes
1answer
288 views

2 wordpress blogs with 1 users table and 1 login

I have been trying to achieve that and I did without the 1 login part I fallowed this post/tutorial , but no matter what I do I can not get it to login ones for both websites. My set up is ...
2
votes
1answer
344 views

What is the best way to move a plugin´s subdirectory+files to wp-content/uploads-directory?

I am developer of the plugin Leaflet Maps Marker (http://www.mapsmarker.com - "Pin, organize & show your favorite places through OpenStreetMap, OGD Vienna or any custom WMTS-map") and have one ...
2
votes
2answers
96 views

Install theme on multiple domains

i'm hosting several sites. they all have the same base theme that i need to install. I want to develop this theme and have them updated on all the sites simultaneously. I have the following folder ...
2
votes
0answers
85 views

Namespacing WordPress project according to FIG standards

I am trying to wrap my head around the namespaces, autoloaders and FIG standards and most importantly how to achieve their integration to WordPress as close as possible. Here is my file structure, ...
2
votes
0answers
165 views

How to get WordPress to save upload file beyond web root

I am using nginx on a multisite install. I am trying to get WordPress to save uploads to a folder beyond the webroot : /home/mydomain/file_secure as opposed to ...
2
votes
1answer
44 views

Installing multisite on domain with existing subdirectory wordpress installations

I have a domain that already has a number of wordpress installations in existing subdirectories. I would like to activate wordpress multisite to manage so new subdirectory installations with a new ...
2
votes
1answer
204 views

Remove 'wp-content/themes/themename/' from Image path

I'm currently moving an old website based on some other CMS towards a new server, with WordPress. However, the site ranks good on Google, and I'm have to keep all the link structure, including the ...
1
vote
2answers
2k views

How to build a directory with indexes in Wordpress

I am working on a site that is using posts as a way to manage glossary articles like the example site below. I would like to find a way to display articles alphabetically and grouped by a selected ...
1
vote
4answers
2k views

Moving to directory creates path problems.. how to solve?

I've moved my installation from example.com/beta to example.com and I've noticed that there are a few broken images. Looking at the source, it appears that they are still looking in looking in the ...
1
vote
3answers
160 views

Use WP_Theme::scandir function to scan a plugin directory. Is there a way?

I'd like to scan a plugin's directory for files with specific extensions, like php, css and js. I know there is scandir() function in WP_Theme class that's perfect for this work. The problem is that ...
1
vote
5answers
1k views

WP Page and Subdirectory with same name

I have a subdirectory within my WP installation called labs. I created a WP page called labs as well. When a user hits mydomain.com/labs/ I want them to load up the WP page. But instead it's loading ...
1
vote
3answers
221 views

Depth > 2 possible with multisite?

Is there anyway to create blogs with 2 depths using multisite? I want to have an installation in root and blogs with 2 depths. Something like: / - WP installation: root aggregate /foo - ...