Title: Kerosity's Replies | WordPress.org

---

# Kerosity

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

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

 Search replies:

## Forum Replies Created

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

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

 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[WooCommerce] How to list specific products on a page or page template?](https://wordpress.org/support/topic/how-to-list-specific-products-on-a-page-or-page-template/)
 *  Thread Starter [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [5 years, 10 months ago](https://wordpress.org/support/topic/how-to-list-specific-products-on-a-page-or-page-template/#post-13019583)
 * Hey thanks for the response!
 * I did see the shortcode, but is there a way to do it with code in the template
   file?
 * Because if we used a shortcode, we’d have to have something that auto-generated
   the shortcode after having some type of selector that we use to choose which 
   products to display. Right?
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Image Cropper Not Working Every time?](https://wordpress.org/support/topic/image-cropper-not-working-every-time/)
 *  Thread Starter [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [11 years, 11 months ago](https://wordpress.org/support/topic/image-cropper-not-working-every-time/#post-4962078)
 * I found a plugin that does something better than what I was looking for.
 * [http://sewpafly.github.io/post-thumbnail-editor/editor/](http://sewpafly.github.io/post-thumbnail-editor/editor/)
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[W3 Total Cache] Can't Install Without White Screen](https://wordpress.org/support/topic/cant-install-without-white-screen/)
 *  Thread Starter [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/cant-install-without-white-screen/#post-4586174)
 * ^
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Fixed Widget and Sticky Elements for WordPress] Plugin not working in my site](https://wordpress.org/support/topic/pligin-not-working-in-my-site/)
 *  [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/pligin-not-working-in-my-site/#post-3736443)
 * By chance did you trouble shoot and solve this one? I have a Yoothemes template
   also and I’d really like to get your plugin working on my site. They all run 
   off of the same framework so it should be a very similar fix.
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [If Parent Page > First Child, If Child > Show Next Child](https://wordpress.org/support/topic/if-parent-page-first-child-if-child-show-next-child/)
 *  Thread Starter [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/if-parent-page-first-child-if-child-show-next-child/#post-4543903)
 * Any assistance?
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [Commenter Avatar Choice From Select Box](https://wordpress.org/support/topic/commenter-avatar-choice-from-select-box/)
 *  Thread Starter [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [12 years, 3 months ago](https://wordpress.org/support/topic/commenter-avatar-choice-from-select-box/#post-4541714)
 * Any input?
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [What makes Menu CSS Classes print to html?](https://wordpress.org/support/topic/what-makes-menu-css-classes-print-to-html/)
 *  Thread Starter [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [12 years, 4 months ago](https://wordpress.org/support/topic/what-makes-menu-css-classes-print-to-html/#post-4512367)
 * Okay I read up a little bit more on the walker class. “I think” I understand 
   it enough to say I’m not using it.
 * When I registered my menu I just used the theme_location and nothing else.
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [What makes Menu CSS Classes print to html?](https://wordpress.org/support/topic/what-makes-menu-css-classes-print-to-html/)
 *  Thread Starter [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [12 years, 4 months ago](https://wordpress.org/support/topic/what-makes-menu-css-classes-print-to-html/#post-4512285)
 * I’ve never heard of a custom menu walker until I started searching for a solution
   to this problem. I tried reading the docs for the menu walkers but I didn’t fully
   understand them. (I’m learning PHP/Wordpress as I go – pretty new to it all.)
 * The only thing I did was follow a guide to create the menu and register it in
   the functions.php
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [If Child Page > Show Parent Title > If No Parent > Show Current Title](https://wordpress.org/support/topic/if-child-page-show-parent-title-if-no-parent-show-current-title/)
 *  Thread Starter [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/if-child-page-show-parent-title-if-no-parent-show-current-title/#post-4377391)
 * So I probably went about 6 pages deep on google searches for the debug notice
   I got above… after trying (trial/error) a dozen different things… this seems 
   to work:
 *     ```
       <?php
   
       global $post;
   
       if( $post->post_parent ) { ?>
         <a href="<?php get_permalink( $post->post_parent ); ?>"><?php echo get_the_title( $post->post_parent ); ?></a>
       <?php } else {
         the_title();
       } ?>
       ```
   
 * All that I did was add `global $post;` before.
 * Can someone explain what is going on so I can know what I’m doing in the future…
   lol.
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [If Child Page > Show Parent Title > If No Parent > Show Current Title](https://wordpress.org/support/topic/if-child-page-show-parent-title-if-no-parent-show-current-title/)
 *  Thread Starter [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/if-child-page-show-parent-title-if-no-parent-show-current-title/#post-4377354)
 * First off, thanks a ton for all of your help. I really appreciate it!
 * This is a custom page template that I’m going to be using for about 40-50 pieces
   of content on my site (and possibly go from there). So I do want it to be different
   then the rest of the site, but I used a custom template so I can just easily 
   select it while creating the page/child-pages. (I’m not wrong with this line 
   of thinking am I?)
 * -edit- And since I’m using the Warp Framework, it’s very funky how you have to
   create custom page templates, which is why the pastebin I linked above has all
   that extra code.
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [If Child Page > Show Parent Title > If No Parent > Show Current Title](https://wordpress.org/support/topic/if-child-page-show-parent-title-if-no-parent-show-current-title/)
 *  Thread Starter [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/if-child-page-show-parent-title-if-no-parent-show-current-title/#post-4377348)
 * There’s a lot more going on! Basically what I did so far was take their “template”
   file and edit it down to where it’s just displaying the header/footer. Then I
   was going to put my page template code in the middle.
 * [http://pastebin.com/dpzXiSDX](http://pastebin.com/dpzXiSDX)
 * The stuff I’m entering starts at line #112
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [If Child Page > Show Parent Title > If No Parent > Show Current Title](https://wordpress.org/support/topic/if-child-page-show-parent-title-if-no-parent-show-current-title/)
 *  Thread Starter [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/if-child-page-show-parent-title-if-no-parent-show-current-title/#post-4377341)
 * Okay! I turned on the debug mode (that’s really cool!).
 * I get this error on both lines where `$post->post_parent` exists.
 * Here’s the error:
 * >  Notice: Undefined variable: post in /file/path/to/template.php on line 116
   > Notice: Trying to get property of non-object in /file/path/to/template.php 
   > on line 116
   > Notice: Undefined variable: post in /file/path/to/template.php on line 118
   > Notice: Trying to get property of non-object in /file/path/to/template.php 
   > on line 118
 * I’m using a WordPress Framework (Yootheme’s Warp v6) so I’m assuming this has
   something to do with it…
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [If Child Page > Show Parent Title > If No Parent > Show Current Title](https://wordpress.org/support/topic/if-child-page-show-parent-title-if-no-parent-show-current-title/)
 *  Thread Starter [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/if-child-page-show-parent-title-if-no-parent-show-current-title/#post-4377327)
 * -edit- nevermind… still trying to figure it out.
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [If Child Page > Show Parent Title > If No Parent > Show Current Title](https://wordpress.org/support/topic/if-child-page-show-parent-title-if-no-parent-show-current-title/)
 *  Thread Starter [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/if-child-page-show-parent-title-if-no-parent-show-current-title/#post-4377326)
 * Okay started debugging:
 * When I put your line of code before it, It displayed “Parent: ” “
 * So then I looked into the loop link you sent. If I’m reading it right I should
   wrap my “post content” with this:
 *     ```
       <?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
       ~post content here~
       <?php endwhile; else: ?>
       <p><?php _e('Sorry, no posts matched your criteria.'); ?></p>
       <?php endif; ?>
       ```
   
 * Right? I wrapped the previous code in that and it I get the same results.
 *   Forum: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
   
   In reply to: [If Child Page > Show Parent Title > If No Parent > Show Current Title](https://wordpress.org/support/topic/if-child-page-show-parent-title-if-no-parent-show-current-title/)
 *  Thread Starter [Kerosity](https://wordpress.org/support/users/kerosity/)
 * (@kerosity)
 * [12 years, 5 months ago](https://wordpress.org/support/topic/if-child-page-show-parent-title-if-no-parent-show-current-title/#post-4377323)
 * I put that into the second line of what alchymyth suggest right?
 * If so that didn’t seem to work either.

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

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