Depth > 2 possible with multisite?

Answering your first question, yes it is absolutely possible to have one installation of WordPress running ‘within’ another (i.e. installed at example.com and example.com/child). I have something like that running right now.

Change location of header.php and footer.php

It is not possible to override header/footer via hooks in respective get_header()/get_header() functions. However it is often overlooked that these function allow input and loading different headers. For example get_header( ‘nested/header’ ); will look for header-nested/header.php in theme’s folder. It’s kind of a hack in regards to subdirectory use, but it works. 🙂

how to create a folder in wordpress

It might be best not to think of it as “folders” since it all runs off of index.php. The rest of the URL structure does not represent the file structure (eg Folders) but the permalink rewriting structure. (And thus make sure you have Permalinks enabled.) To create example.com/miami, you would create a Page within WordPress … Read more

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

You can use PHP5 RecursiveDirectoryIterator with RecursiveIteratorIterator $directory = ‘/project_root/wp-content/plugins/your-plugin’; //Your plugin dir $it = new RecursiveIteratorIterator(new RecursiveDirectoryIterator($directory)); while ($it->valid()) { //Check the file exist if (!$it->isDot()) { //if not parent “..” or current “.” if (strpos($it->key(), ‘.php’) !== false || strpos($it->key(), ‘.css’) !== false || strpos($it->key(), ‘.js’) !== false ) { //Do your stuff … Read more

bloginfo(‘template_directory’) img src

You cannot use bloginfo() while your are outputting using echo because bloginfo it self also out puts string using echo. Below will work for you, you also have extra double quote which i have removed…. <?php $attch_id_1 = pn_get_attachment_id_from_url(get_post_meta($post->ID, ‘img1’, true)); $image_attributes_1 = wp_get_attachment_image_src( $attch_id_1, ‘full’); $attch_id_2 = pn_get_attachment_id_from_url(get_post_meta($post->ID, ‘img2’, true)); $image_attributes_2 = wp_get_attachment_image_src( $attch_id_2, … Read more