Title: monkeybrain's Replies | WordPress.org

---

# monkeybrain

  [  ](https://wordpress.org/support/users/monkeybrain/)

 *   [Profile](https://wordpress.org/support/users/monkeybrain/)
 *   [Topics Started](https://wordpress.org/support/users/monkeybrain/topics/)
 *   [Replies Created](https://wordpress.org/support/users/monkeybrain/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/monkeybrain/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/monkeybrain/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/monkeybrain/engagements/)
 *   [Favorites](https://wordpress.org/support/users/monkeybrain/favorites/)

 Search replies:

## Forum Replies Created

Viewing 15 replies - 1 through 15 (of 34 total)

1 [2](https://wordpress.org/support/users/monkeybrain/replies/page/2/?output_format=md)
[3](https://wordpress.org/support/users/monkeybrain/replies/page/3/?output_format=md)
[→](https://wordpress.org/support/users/monkeybrain/replies/page/2/?output_format=md)

 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Renaming a theme and migrating customizer settings](https://wordpress.org/support/topic/renaming-a-theme-and-migrating-customizer-settings/)
 *  Thread Starter [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [8 years, 7 months ago](https://wordpress.org/support/topic/renaming-a-theme-and-migrating-customizer-settings/#post-9400452)
 * Hi Jacob,
 * Yes, thanks, got it working.
    (Had to save the customizer settings afterwards
   as the search and replace in the theme files also renamed the custom css filename
   the theme writes. Doh!)
 * Cheers
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Renaming a theme and migrating customizer settings](https://wordpress.org/support/topic/renaming-a-theme-and-migrating-customizer-settings/)
 *  Thread Starter [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [8 years, 7 months ago](https://wordpress.org/support/topic/renaming-a-theme-and-migrating-customizer-settings/#post-9398434)
 * Hi Jacob,
 * Thanks! I know where the customizer options are stored. Replacing the old theme
   name with the new one, did not result in all options being used correctly by 
   the renamed theme though. I might have to manually look into the options that
   do not migrate as expected. Maybe I made a mistake while renaming.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Slider, Gallery, and Carousel by MetaSlider - Image Slider, Video Slider] Set SRCSET as of WordPress 4.4](https://wordpress.org/support/topic/set-srcset-as-of-wordpress-44/)
 *  [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [9 years, 8 months ago](https://wordpress.org/support/topic/set-srcset-as-of-wordpress-44/#post-6989149)
 * Any news on this feature? Or does someone has a solution to get srcset into the
   meta slider via functions.php?
 *   Forum: [Hacks](https://wordpress.org/support/forum/plugins-and-hacks/hacks/)
   
   In reply to: [Custom Taxonomy get most recent item of sub categories](https://wordpress.org/support/topic/custom-taxonomy-get-most-recent-item-of-sub-categories/)
 *  Thread Starter [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [9 years, 9 months ago](https://wordpress.org/support/topic/custom-taxonomy-get-most-recent-item-of-sub-categories/#post-7538079)
 * Hey [@bcworkz](https://wordpress.org/support/users/bcworkz/),
 * Thanks a lot! I’ll give it a try but am not great with frustrating moments and
   might end up hiring someone to help me with this. 🙂
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Help with the loop (custom post type taxonomy)](https://wordpress.org/support/topic/help-with-the-loop-custom-post-type-taxonomy/)
 *  Thread Starter [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/help-with-the-loop-custom-post-type-taxonomy/#post-7380987)
 * Marking this as resolved, but feel free to let me know of a better solution using
   WP_Query.
    Thanks!
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Help with the loop (custom post type taxonomy)](https://wordpress.org/support/topic/help-with-the-loop-custom-post-type-taxonomy/)
 *  Thread Starter [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/help-with-the-loop-custom-post-type-taxonomy/#post-7380986)
 * I found a solution! When I put this into my taxonomy-photo.php it displays the
   correct posts from the photo cpt.
 *     ```
       <?php $term = get_term_by( 'slug', get_query_var( 'term' ), get_query_var( 'taxonomy' ) ); ?>
       <?php query_posts(array( 'post_type'=>'photo', 'gallery'=>$term->slug)); ?>
       <?php if ( have_posts() ): ?>
       <?php while ( have_posts() ) : the_post();?>
       ```
   
 * The only thing I’m not sure about is using query_posts since I read somewhere
   that it shouldn’t be used. But a quick try with WP_Query did not work. If someone
   has a solution that works with WP_Query, let me know.
 * Cheers and thanks again for the help.
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Help with the loop (custom post type taxonomy)](https://wordpress.org/support/topic/help-with-the-loop-custom-post-type-taxonomy/)
 *  Thread Starter [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/help-with-the-loop-custom-post-type-taxonomy/#post-7380980)
 * Hi TrishaM,
 * Thanks for your reply! And thanks for the compliment regarding my English skills.
   Whenever misunderstandings happen I tend to think it’s because of not being a
   native English speaker.
 * 1. Oddly enough, my query above worked even without defining the_post, but it
   wasn’t dynamic and only worked for the defined term ‘black-and-white’.
 * 2. First off, I followed your advice and renamed the cpt to `photo` and also 
   renamed the taxonomy to `gallery` … I then tried to find the problem with the
   normal
 *     ```
       <?php if ( have_posts() ): ?>
       <?php while ( have_posts() ) : the_post(); ?>
       ```
   
 * approach. And while trying to find the problem I thought I’d test the custom 
   taxonomy for normal posts and see if that works, and to my surprise it does.
   
   So, when I change
 *     ```
       register_taxonomy( 'gallery', 'photo',
           	array(
       ```
   
 * to
 *     ```
       register_taxonomy( 'gallery', 'post',
           	array(
       ```
   
 * the taxonomy-gallery.php template works as expected (using the normal WP posts).
   
   When I try to use it for the cpt `photo` it doesn’t.
 * Now I wonder if the solution could be to tell the taxonomy-gallery.php loop to
   somehow use the post_type ‘photo’ and not ‘post’. (Even after changing `register_taxonomy('
   gallery', 'post',` back to `register_taxonomy( 'gallery', 'photo',` the page 
   still displays the posts. It really seems like it is only looking for posts and
   not post_type photo at all.
 * Do you have any ideas on how to get the attention of a mod?
 * Thanks a lot! I feel like I’m really close to the solution. 🙂
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Help with the loop (custom post type taxonomy)](https://wordpress.org/support/topic/help-with-the-loop-custom-post-type-taxonomy/)
 *  Thread Starter [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/help-with-the-loop-custom-post-type-taxonomy/#post-7380938)
 * Hi TrishaM,
 * Thanks a lot, but if I understand correctly this is not exactly what I’m trying
   to do. I’m trying to create multiple photo galleries, each with its own url/page.
 * I actually have an archive-photos.php with a query very similar to your code,
   except the ‘posts_per_page’ => 1, … this page will be used as an overview of 
   all terms/galleries, from there I link to < a href=”/photo-gallery/<?php echo
   $tax_term->slug; ?>/” on the most recent photo thumbnail within that term. This
   terms/galleries overview will be found under /photos/ (Because there the user
   finds all photos is why I called the CTP photos and not photo, your reasoning
   makes sense though)
 * What I’m now trying to do is a template file that lists the photos from within
   ONE term, so if I understand correctly, no foreach($terms as $term). It should
   work like /tag/black-and-white/ or /category/black-and-white/ works for normal
   WordPress posts.
 * What confuses me is that the normal tag.php or category.php of WordPress uses
   a simple
 *     ```
       <?php if ( have_posts() ): ?>
       <?php while ( have_posts() ) : the_post(); ?>
       <?php endwhile; ?>
       // Content like <?php the_title(); ?> etc...
       <?php else: ?>
       	No posts to display
       <?php endif; ?>
       ```
   
 * but if I use this for my custom taxonomy and browse to /photo-gallery/black-and-
   white/, it returns “No posts to display”.
 * And with my code
 *     ```
       <?php $term_loop = new WP_Query( array(
           'post_type' => 'photos',
           'photo-gallery' => 'black-and-white',
           )
         );
       ?>
       <?php the_thumbnail() ?>
       <?php endwhile; ?>
       ```
   
 * the taxonomy-photo-gallery.php returns all photos within the term ‘black-and-
   white’. That’s why I thought if I could replace that line with something that
   grabs the term name from the URL, it would work for all terms (/photo-gallery/
   black-and-white/ aswell as /photo-gallery/portrait/ and all other terms/galleries.)
 * Any ideas on how to solve that?
    And sorry if my explanation is not clear, English
   is not my first language.
 * Thanks so much for your help!
 * edit: This is the code I use to create the custom taxonomy, maybe there is something
   wrong with it?
 *     ```
       function build_photo_taxonomies() {
           register_taxonomy( 'photo-gallery', 'photos',
           	array(
           		'label' => 'Gallery',
                   'public' => true,
           		'hierarchical' => true,
           		'query_var' => true
           		)
           	);
       }
       ```
   
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Help with the loop (custom post type taxonomy)](https://wordpress.org/support/topic/help-with-the-loop-custom-post-type-taxonomy/)
 *  Thread Starter [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/help-with-the-loop-custom-post-type-taxonomy/#post-7380900)
 * Hi TrishaM
 * Thanks for your reply!
 * 1. Sorry about that, makes sense, thanks.
 * 2. I have a custom post type named ‘photos’ which has a custom taxonomy called‘
   photo-gallery’. For each taxonomy term (e.g. ‘black and white’, ‘portrait’, etc…)
   I’d like to have an overview which lists all photos that are within that term.
 * So, what I’m trying to do is list all photos that are tagged with ‘black-and-
   white’ but also not hardcode the name of the tag, so that the template file works
   with all future tags/terms.
    I first thought that I could use
 *     ```
       <?php if ( have_posts() ): ?>
       <?php while ( have_posts() ) : the_post(); ?>
       ```
   
 * because I thought taxonomy-photo-gallery.php is associated with all the terms
   that I create within the taxonomy ‘photo-gallery’, but that does not seem to 
   work as expected. So I tried and looked around on how to return the photos for
   one term and then go from there and adapt it for all other terms.
 * If you see my mistake in code or thinking, any help would be greatly appreciated.
 * Thanks!
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [How to change the size of the H2 tag](https://wordpress.org/support/topic/how-to-change-the-size-of-the-h2-tag/)
 *  [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/how-to-change-the-size-of-the-h2-tag/#post-7381252)
 * And if your theme offers user-added CSS or you installed a CSS plugin, the CSS
   to change the font size looks like this:
 *     ```
       h2 {
       font-size: 20px;
       }
       ```
   
 * And change the `20px` until you like its size.
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Help with the loop (custom post type taxonomy)](https://wordpress.org/support/topic/help-with-the-loop-custom-post-type-taxonomy/)
 *  Thread Starter [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [9 years, 10 months ago](https://wordpress.org/support/topic/help-with-the-loop-custom-post-type-taxonomy/#post-7380896)
 * I still haven’t found a solution for this. If someone has an idea, help would
   be very much appreciated.
 * Thanks!
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [Upload an image in customizer then select thumbnail](https://wordpress.org/support/topic/upload-an-image-in-customizer-then-select-thumbnail/)
 *  [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/upload-an-image-in-customizer-then-select-thumbnail/#post-6362358)
 * I was looking for a solution for this too, and found this solution that seems
   to work fine:
 * [https://pippinsplugins.com/retrieve-attachment-id-from-image-url/](https://pippinsplugins.com/retrieve-attachment-id-from-image-url/)
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Lost my website, but a backup exists on Goodreads…](https://wordpress.org/support/topic/lost-my-website-but-a-backup-exists-on-goodreads/)
 *  [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/lost-my-website-but-a-backup-exists-on-goodreads/#post-7288064)
 * There are quite a few plugins that let you import from an RSS feed. Unfortunately
   there are only a limited number of posts in an RSS feed.
    [https://wordpress.org/plugins/search.php?q=import+rss](https://wordpress.org/plugins/search.php?q=import+rss)
 * Maybe there is an export function for your Goodreads? Maybe even contact them
   and ask for help, maybe they can send you an XML or JSON file with your content?
   WordPress can import quite a few different formats. [https://codex.wordpress.org/Importing_Content#Importing_from_.5BX.5DHTML](https://codex.wordpress.org/Importing_Content#Importing_from_.5BX.5DHTML)
 * Maybe this helps? [https://www.goodreads.com/help/show/5-how-do-i-import-or-export-my-books](https://www.goodreads.com/help/show/5-how-do-i-import-or-export-my-books)
   
   Or this: [http://fictionvixen.com/how-to-back-up-export-your-goodreads-library-in-case-you-want-to-move-it/](http://fictionvixen.com/how-to-back-up-export-your-goodreads-library-in-case-you-want-to-move-it/)(
   WordPress can import CSV)
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Images not showing on posts](https://wordpress.org/support/topic/images-not-showing-on-posts-3/)
 *  [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/images-not-showing-on-posts-3/#post-7288057)
 * It looks like your theme is showing the excerpt of the post and therefore not
   displaying the images from the content. Assigning featured images, like deepbevel
   suggested, probably is the right solution indeed.
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [List posts for each taxonomy/tag of a custom post type](https://wordpress.org/support/topic/list-posts-for-each-taxonomytag-of-a-custom-post-type/)
 *  Thread Starter [monkeybrain](https://wordpress.org/support/users/monkeybrain/)
 * (@monkeybrain)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/list-posts-for-each-taxonomytag-of-a-custom-post-type/page/2/#post-7277293)
 * Add some if custom field is not empty return some html and it’s even more yikes.
   
   I’m glad and astonished that I was able to help and simplify. (Even though I 
   just followed your link.) 🙂

Viewing 15 replies - 1 through 15 (of 34 total)

1 [2](https://wordpress.org/support/users/monkeybrain/replies/page/2/?output_format=md)
[3](https://wordpress.org/support/users/monkeybrain/replies/page/3/?output_format=md)
[→](https://wordpress.org/support/users/monkeybrain/replies/page/2/?output_format=md)