Tuesday, 9 December 2014

plugin - advanced-custom-fields

https://wordpress.org/plugins/advanced-custom-fields/screenshots/

this plugin is for a-z solution for all your custom fields needs.
A perfect plugin.

unexpected output" During Plugin Activation error

  • use this plugin "unexpected output" During Plugin Activation by David Wells.
check in file zilla error messages are shown there.

start removing data causing this error.

Monday, 8 December 2014

gravity forms taxonomy

Once you've created your Custom Taxonomy, make sure you have at least a draft post of a CPT using that taxonomy.
Once you're adding/editing your Gravity Form, just use the regular ole Drop Down field (NOT a post field) and you should see the Populate w/ Taxonomy option.

Multiple Categories and classipress or vantage?

ClassiPress does not have any functionality to sell items within the theme, so if you're needing purchase options, these are not available by default. There are a couple of ClassiPress child themes available in the AppThemes marketplace which will allow you to add such functionality through compatibility with woocommerce.

Users cannot select multiple categories from the front end, however admin can select multiple categories for listings from the wp-admin.

There is only one login type available, so this would require customization on your part if you were looking to implement different login types. ClassiPress is not encrypted, so you are free to modify the theme as you wish. Thanks.    

step forms data comes from -
step1.php
step2.php
step-functions.php
file kept in includes/forms/step-functions.php                                                    

About me

Hello Visitors,
My Name is Madhukar , i am a PHP developer.I have started working on wordpress from past two year 
This site is developed for Learning purpose.This site will contain very basics of wordpress so that beginners may learn the basics.

Post types Retrive data

Codes start here.
<code> 
<?php 
                    $args = array(
                         'post_type' => 'betts_team',
                         'post_status' => 'publish',
                         'posts_per_page' => -1,
                         'orderby'=>'menu_order', 
                         'order'=> 'ASC'
                         );
                    $team_query = new WP_Query($args);
                   if($team_query->have_posts()){
                    while ($team_query->have_posts()) : $team_query->the_post();
                    
                    $content = get_the_content();

                    $image= wp_get_attachment_image_src(get_post_thumbnail_id($post->ID),'team-thumb');
                                 
                    if(get_post_meta($post->ID, 'title-people-page', true) !=""){
                    $title =  get_post_meta($post->ID, 'title-people-page', true);
                    }else{
                    $title= "";
                    }
                    if(get_post_meta($post->ID,'resume-pdf-download-people-page',true) !=""){
                    $resume = get_post_meta($post->ID,'resume-pdf-download-people-page',true);
                    }else{
                     $resume="";
                    }
                    
                    if(get_post_meta($post->ID,'email-people-page',true) !=""){
                    $email= get_post_meta($post->ID,'email-people-page',true);
                    }else{
                    $email="";
                    }
                    if(get_post_meta($post->ID,'phone-number-people-page',true) !=""){
                    $phone = get_post_meta($post->ID,'phone-number-people-page',true);    
                    }else{
                    $phone="";
                    }
                    if(get_post_meta($post->ID,'extension-people-page',true) !=""){
                    $extension = get_post_meta($post->ID,'extension-people-page',true);
                    }else{
                    $extension = "";
                    }
                    if(get_post_meta($post->ID,'accreditation-logos-people-page',true) !=""){
                    $images = get_post_meta($post->ID,'accreditation-logos-people-page',true);
                    }else{
                    $images = "";
                     }
                    ?>
 </code>
<code> 
if($resume[0]['image'] !=""){ ?>
                    <a href="<?php echo $resume[0]['image']; ?>" target="_blank" class="pdf-link"><span>CV</span></a>    
                    <?php } ?>
                    </p>
                    <?php if($email !=""){ ?>
                    <p class="people-mail"><a href="mailto:<?php echo $email; ?>"><?php echo $email; ?></a></p>
                    <?php } if($phone !=""){ ?>
                    <p class="people-tel"><?php    echo $phone; ?>
                    &nbsp;Ext.&nbsp; <span><?php echo $extension; ?></span>
                    </p>
                    <?php } if(!empty($images)){  ?>
                         <p class="people-logo">
                        <b>Accreditations</b> <br />
                        <?php
                      foreach($images as $imgs){    
                      ?>
                        <img src = "<?php echo $imgs['image']; ?>" />
                        <?php } 
                       echo "</p>";
                    }
                       ?>
                        
                    </div>
                    </div>
                 <?php endwhile;
                  wp_reset_query();
                  }
                  ?> 
</code>

Custom Post types

Custom Post Type -  
<code> 
function home_custom_slider() {
  $labels = array(
    'name' => _x('Slider', 'post type general name', 'your_text_domain'),
    'singular_name' => _x('Slides', 'post type singular name', 'your_text_domain'),
    'add_new' => _x('Add New', 'Slides', 'your_text_domain'),
    'add_new_item' => __('Add New Slides', 'your_text_domain'),
    'edit_item' => __('Edit Slides', 'your_text_domain'),
    'new_item' => __('New Slides', 'your_text_domain'),
    'all_items' => __('All Slides', 'your_text_domain'),
    'view_item' => __('View Slides', 'your_text_domain'),
    'search_items' => __('Search Slides', 'your_text_domain'),
    'not_found' =>  __('No Slides found', 'your_text_domain'),
    'not_found_in_trash' => __('No Slides found in Trash', 'your_text_domain'), 
    'parent_item_colon' => '',
    'menu_name' => __('Home Slider', 'your_text_domain')

  );
  $args = array(
    'labels' => $labels,
    'public' => true,
    'publicly_queryable' => true,
    'show_ui' => true, 
    'show_in_menu' => true, 
    'query_var' => true,
    'rewrite' => array( 'slug' => _x( 'slides', 'URL slug', 'your_text_domain' ) ),
    'capability_type' => 'post',
     'menu_icon' => get_stylesheet_directory_uri() . '/images/icon_slides.png',
    'has_archive' => true, 
    'hierarchical' => false,
    'menu_position' => null,
    'supports' => array( 'title', 'editor', 'author', 'thumbnail','custom-fields','page-attributes')
  ); 
  register_post_type('Slides', $args);
}
add_action( 'init', 'home_custom_slider' );
add_image_size( 'slider-post-thumbnail', 775, 452, true ); // Slider Thumbnail
</code>