Forum Replies Created

Viewing 9 replies - 1 through 9 (of 9 total)
  • I am installed Woocommerce Brands Plugin 0.1 properly and activate, use WooCommerce 2.0.5. problem is when I Edit Brands error ( Fatal error: Call to undefined function wc_placeholder_img_src() in D:\Xampp\htdocs\mudiwala\wp-content\plugins\woocommerce-brand\calsses\taxonomies.php on line 169 ) and when I select brand in my website front-end then error ( Fatal error: Call to undefined function wc_get_template() in D:\Xampp\htdocs\mudiwala\wp-content\plugins\woocommerce-brand\templates\taxonomy-product_brand.php on line 14 )
    please help me for shootout this problem, I am waiting your answer…

    Thread Starter duttasanjib2003

    (@duttasanjib2003)

    I am sorry, past few days i am out of station so i am not interact you.

    This is my custom post page link ( https://gorestaurant.in/city/delhi-ncr/restaurants-nightlife/bikanervala/ ) click on menu thumbnail.

    so, please explain me details how its working in my tmeplate, i am not fluent in php.

    I just submit sitemap in google webmaster tools and faced the same Missing XML tag problem, any one can help…

    Thread Starter duttasanjib2003

    (@duttasanjib2003)

    Thanking you for replay, I am working in local server offline, testing it for my online site…

    Forum: Hacks
    In reply to: hide custom field
    Thread Starter duttasanjib2003

    (@duttasanjib2003)

    Thank you my problem is solved, thanks again…

    Forum: Hacks
    In reply to: hide custom field
    Thread Starter duttasanjib2003

    (@duttasanjib2003)

    Thanks for replay.
    I want to just hide this field which is print on my ad details page (all fields display serialy) not delete because mobile no. displayed in other place in same page. please see this page https://www.opendeals.in/ads/accountant-job-2/

    Code Details
    ————-
    single-ad_listing.php

    <?php // 3.0+ display the custom fields instead (but not text areas) cp_get_ad_details( $post->ID, $cat_id ); ?>

    Theme-functions.php

    // display all the custom fields on the single ad page, by default they are placed in the list area
    if ( ! function_exists(‘cp_get_ad_details’) ) {
    function cp_get_ad_details( $post_id, $category_id, $location = ‘list’ ) {
    global $wpdb;

    // see if there’s a custom form first based on category id.
    $form_id = cp_get_form_id( $category_id );

    $post = get_post( $post_id );
    if ( ! $post )
    return;

    // if there’s no form id it must mean the default form is being used
    if ( ! $form_id ) {

    // get all the custom field labels so we can match the field_name up against the post_meta keys
    $sql = “SELECT field_label, field_name, field_type FROM $wpdb->cp_ad_fields”;

    } else {

    // now we should have the formid so show the form layout based on the category selected
    $sql = $wpdb->prepare( “SELECT f.field_label, f.field_name, f.field_type, m.field_pos FROM $wpdb->cp_ad_fields f “
    . “INNER JOIN $wpdb->cp_ad_meta m ON f.field_id = m.field_id WHERE m.form_id = %s ORDER BY m.field_pos ASC”, $form_id );

    }

    $results = $wpdb->get_results( $sql );

    if ( ! $results ) {
    _e( ‘No ad details found.’, APP_TD );
    return;
    }

    // allows to hook before ad details
    cp_action_before_ad_details( $results, $post, $location );

    foreach ( $results as $result ) {

    // external plugins can modify or disable field
    $result = apply_filters( ‘cp_ad_details_field’, $result, $post, $location );
    if ( ! $result )
    continue;

    $disallow_fields = array( ‘cp_price’, ‘cp_currency’ );
    if ( in_array( $result->field_name, $disallow_fields ) )
    continue;

    $post_meta_val = get_post_meta( $post->ID, $result->field_name, true );
    if ( empty( $post_meta_val ) )
    continue;

    if ( $location == ‘list’ ) {
    if ( $result->field_type == ‘text area’ )
    continue;

    if ( $result->field_type == ‘checkbox’ ) {
    $post_meta_val = get_post_meta( $post->ID, $result->field_name, false );
    $post_meta_val = implode( “, “, $post_meta_val );
    }

    $args = array( ‘value’ => $post_meta_val, ‘label’ => $result->field_label, ‘id’ => $result->field_name, ‘class’ => ” );
    $args = apply_filters( ‘cp_ad_details_’ . $result->field_name, $args, $result, $post, $location );

    if ( $args )
    echo ‘<li id=”‘ . $args[‘id’] . ‘” class=”‘ . $args[‘class’] . ‘”><span>’ . esc_html( translate( $args[‘label’], APP_TD ) ) . ‘:</span> ‘ . appthemes_make_clickable( $args[‘value’] ) . ”;

    } elseif ( $location == ‘content’ ) {
    if ( $result->field_type != ‘text area’ )
    continue;

    $args = array( ‘value’ => $post_meta_val, ‘label’ => $result->field_label, ‘id’ => $result->field_name, ‘class’ => ‘custom-text-area dotted’ );
    $args = apply_filters( ‘cp_ad_details_’ . $result->field_name, $args, $result, $post, $location );

    if ( $args )
    echo ‘<div id=”‘ . $args[‘id’] . ‘” class=”‘ . $args[‘class’] . ‘”><h3>’ . esc_html( translate( $args[‘label’], APP_TD ) ) . ‘</h3> ‘ . appthemes_make_clickable( $args[‘value’] ) . ‘</div>’;

    }
    }

    // allows to hook after ad details
    cp_action_after_ad_details( $results, $post, $location );
    }
    }

    Forum: Hacks
    In reply to: hide custom field
    Thread Starter duttasanjib2003

    (@duttasanjib2003)

    Thanks for replay.
    i am don’t understand php in depth so please describe me details in code..

    Thread Starter duttasanjib2003

    (@duttasanjib2003)

    details page means in my website. image not display in my webpage…

    Thread Starter duttasanjib2003

    (@duttasanjib2003)

    I would like to add a line in the single-ad_listing.php that displays the cp-city code after the post title…

    <?php if(get_option(‘cp_city’) == ‘yes’); echo get_option (‘cp-city’); ?>

    Just wondering if anyone can help with the correct line of php?

    Thanks
    Sanjib

Viewing 9 replies - 1 through 9 (of 9 total)