Results 1 to 6 of 6

Thread: Tutorial to remove the "Price" field.

  1. #1
    Thread Starter
    Newbie gemwol's Avatar
    Join Date
    Jun 2009
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Tutorial to remove the "Price" field.

    I am looking for a tutorial to remove the "Price" field from the latest Classipress theme. $10 by Paypal for the first clear solution that works posted below.

  2. #2
    Senior Member jakesterz's Avatar
    Join Date
    Aug 2009
    Posts
    194
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Tutorial to remove the "Price" field.

    I just followed the tutorial on how to add a field, but in reverse. Hope that helps.

  3. #3
    Senior Member herb_'s Avatar
    Join Date
    May 2009
    Posts
    230
    Thanks
    0
    Thanked 6 Times in 6 Posts

    Re: Tutorial to remove the "Price" field.

    (perform at your own risk, i just threw this together)

    just quickly, it'd probably involve opening post-form.php and commenting out the following:

    <label for="price"><?php _e('Price','cp'); ?> <span>*</span> <?php _e('(do not enter currency symbol)','cp'); ?></label>
    <input type="text" id="price" class="adfields" name="price" size="60" maxlength="100" value="<?php echo $_POST['price']; ?>" />
    then opening form_process.php and removing price as a mandatory field.

    Find this:

    if ($post_title == "" || $post_cat == "" || $price == "" || $location == "" || $name == "" || $email == "" || $description == "") {
    and replace with this:

    if ($post_title == "" || $post_cat == "" || $location == "" || $name == "" || $email == "" || $description == "") {
    ------------------------------------------------------------------------

    now price column needs to be removed from index.php

    so in index.php, remove or comment out these:

    <span class="price">
    <?php _e('Price','cp'); ?>
    </span>
    AND

    <span class="price"><?php echo get_option('currency'); ?><?php echo get_post_meta($post->ID, "price", true); ?></span>
    --------------------------------------------------------

    DO THE EXACTS SAME IN SEARCH.PHP AS YOU DID IN INDEX.PHP

    ------------------------------------------------------------

    then open single.php comment out:

    <div class="prices"><?php echo get_option('currency'); ?><?php echo get_post_meta($post->ID, "price", true); ?></div>
    alternatively some of the above could be done with "display: none" for the respective class or id within master.css and your chosen color.css

    you'll probably need to adjust some css stuff to make everything look ok.

    you can keep the tenner

  4. #4
    Newbie ianabroad's Avatar
    Join Date
    Oct 2009
    Posts
    2
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Tutorial to remove the "Price" field.

    Thank you for being so kind enough to post this. It has been a great help for me too.

  5. #5
    Amateur
    Not a Verified Customer
    hubber's Avatar
    Join Date
    Nov 2009
    Posts
    13
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Tutorial to remove the "Price" field.

    If Herb_ is syill around, to remove Price, one thing you said was:
    now price column needs to be removed from index.php

    so in index.php, remove or comment out these:

    <span class="price">
    <?php _e('Price','cp'); ?>
    </span>

    In my index file I have:
    <span class="price">
    <?php _e('Price','cp'); ?>
    [img]<?php bloginfo('template_url'); ?>/images/sortup.gif[/img][img]<?php bloginfo('template_url'); ?>/images/sortdown.gif[/img]
    </span>

    Which if I delete screws up a lot of things.
    Any suggestions?

    Thanks
    Hub

  6. #6
    Senior Member herb_'s Avatar
    Join Date
    May 2009
    Posts
    230
    Thanks
    0
    Thanked 6 Times in 6 Posts

    Re: Tutorial to remove the "Price" field.

    oh yah, i forgot about the sorting stuff which i removed from my site very early on

    I would delete this entire section:

    <span class="price">
    <?php _e('Price','cp'); ?>
    [img]<?php bloginfo('template_url'); ?>/images/sortup.gif[/img][img]<?php bloginfo('template_url'); ?>/images/sortdown.gif[/img]
    </span>

    If you did that (and everything else I mentioned) and things still look screwed up, I'd need some more description, like a screen shot or a link, or details about what is screwed up.

    My site is now very far changed from the original template so it would take me a while to orientate with the original again.

    One little firefox plugin I've found helpful is ColorZilla, which you can use to hover over sections of your site and then see the div sections related to different parts of your site. Then you can open of master.css and blue.ccs (or your chosen color) and tweak those things as needed.

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. Tutorial:Change place to Currency Symbol
    By chifen in forum ClassiPress General Discussion
    Replies: 1
    Last Post: May 25th, 2009, 11:37 AM