Results 1 to 3 of 3

Thread: Removing the price tag when using a child theme in Classipress

  1. #1
    Thread Starter
    Amateur jeffagogo's Avatar
    Join Date
    Jun 2011
    Location
    Perth Australia
    Posts
    16
    Thanks
    6
    Thanked 0 Times in 0 Posts

    Removing the price tag when using a child theme in Classipress

    Hi, I'm using Classipress 3.15 (dev) version and want to remove the price tag from all adverts. (I don't like it)

    This is quite easy to do by modifying the parent theme file /includes/theme-actions.php
    Remove this line:


    <div class="price-wrap">
    <span class="tag-head">&nbsp;</span><p class="post-price"><?php if ( get_post_meta( $post->ID, 'price', true ) ) cp_get_price_legacy( $post->ID ); else cp_get_price( $post->ID, 'cp_price' ); ?></p>
    </div>


    and it's gone.


    I'd like to do this in the child theme now... yes I can modify the core file directly, but there must be a better way by using the functions.php file in the child theme diectory to some how unhook it or remove the action.

    The theme-actions.php file is this:

    * add the ad price field in the loop before the ad title
    * @since 3.1.3
    */
    function cp_ad_loop_price() {
    if ( is_page() ) return; // don't do ad-meta on pages
    global $post;
    ?>
    <div class="price-wrap">
    <span class="tag-head">&nbsp;</span><p class="post-price"><?php if ( get_post_meta( $post->ID, 'price', true ) ) cp_get_price_legacy( $post->ID ); else cp_get_price( $post->ID, 'cp_price' ); ?></p>
    </div>

    <?php
    }
    add_action( 'appthemes_before_post_title', 'cp_ad_loop_price' );





    What do I need to put in the child theme functions.php file to disable this?
    Can it be done at all, or should I just edit the core file in an unelegant way?

    regards & thanks.

  2. #2
    dimitris's Avatar
    Join Date
    Oct 2011
    Location
    Earth
    Posts
    20,618
    Thanks
    222
    Thanked 1,873 Times in 1,770 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!

  3. #3
    maximus's Avatar
    Join Date
    Mar 2011
    Location
    France
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts
    You must be an AppThemes customer and logged in to view this response. Join today!

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. classipress child theme
    By moabi in forum Showcase & Feedback
    Replies: 9
    Last Post: October 24th, 2011, 09:05 AM
  2. Creating child theme, Modifying classipress theme
    By kajaja in forum ClassiPress General Discussion
    Replies: 2
    Last Post: September 29th, 2011, 11:28 AM
  3. Classipress As Its Own Child Theme
    By bhaynet1 in forum ClassiPress General Discussion
    Replies: 3
    Last Post: June 22nd, 2011, 01:22 PM
  4. Artisteer/existing theme to child theme it on classipress
    By jpartner in forum ClassiPress General Discussion
    Replies: 3
    Last Post: October 30th, 2010, 12:06 PM