You Just write below code, your query loop inside :
<?php echo get_post_meta($post->ID, “field_name”, true); ?>
Before you add Custome field name and set Field Name Value also in post.
that is all.
You can add below code where you want in your php file inside :
<?php query_posts(‘category_name=pre-work-out&showposts=10’); ?>
<?php while (have_posts()) : the_post(); ?>
<h3><a href=”<?php echo get_permalink($page->ID); ?>”><?php the_title(); ?></a></h3>
<?php the_excerpt(); ?>
<?php endwhile;?>
This is show what you like in your recent post from your specific category wise. What you like change you “query_post” inside.
This is remove two Way :
1. Go to function.php search the twentyten_excerpt_length.
There you change below code
//return 40;
return 3000; –> Change here what extra numbers you need.
2. Second option –> Go loop.php
Find the_content
Then you remove or hide the condition part
ex :
You Place Below Code :
‘ ) ); ?>
that’s all ЁЯЩВ now this working well.
First Install WordPress main blog.
Fixed the everthing what you are using.
1. After install open the config file.php
place this code (what domain you want change here) :
define(‘WP_SITEURL’, ‘http://www.example.com/folder/blog2’); –> This is second blog URL
define(‘WP_HOME’, ‘http://www.example.com/folder/blog1’); —> This is first blog URL
2. And Edit Second Blog folder inside — copied all fist blog content OR first blog config only copied(other wordpress file you can use your fress wordpress directory files).
3. Edit Second Blog config file.php
$table_prefix = ‘wpArras_’; –> Place Same Table prefix
define(‘WP_HOME’, ‘http://www.example.com/folder/blog2’); –> This is second blog URL
now you go and check this working well.
More Details contact.
that’s all fine :).
<div>LATEST ARTICLES</div>
<?php
$args = array(‘orderby’ => ‘date’, ‘numberposts’ => 3, ‘category’ => 6, ‘order’=> ‘DESC’);
$postslist = get_posts( $args );
foreach ($postslist as $post) :┬а setup_postdata($post); ?>
<div>
<?php //the_date(); ?>
<div>
<?php //echo get_the_post_thumbnail($page->ID, ‘thumbnail’);
echo get_the_post_thumbnail($page->ID, ‘full’);
?>
</div>
<h3><a href=”<?php echo get_permalink($page->ID); ?>”><?php the_title(); ?></a></h3>
<?php the_excerpt(); ?>
</div>
<?php endforeach; ?>
<div></div>
<?php
// All Categorie Lagest Post Code
$the_query = new WP_Query( ‘cat=6&posts_per_page=10&offset=3’ );
// The Loop
while ( $the_query->have_posts() ) : $the_query->the_post();
?>
<div>
<?php //the_date(); ?>
<div>
<?php //echo get_the_post_thumbnail($page->ID, ‘thumbnail’);
echo get_the_post_thumbnail($page->ID, ‘full’);
?>
</div>
<h3><a href=”<?php echo get_permalink($page->ID); ?>”><?php the_title(); ?></a></h3>
<?php the_excerpt(); ?>
</div>
<?php
endwhile;
// Reset Post Data
wp_reset_postdata();
?>
<div></div>
<?php
// Get Categorie Slug Name
function get_cat_slug($cat_id) {
$cat_id = (int) $cat_id;
$category = &get_category($cat_id);
return $category->slug;
}
?>
<?php
// Get the categories
$category = get_the_category();
// Get the 3 Latest Article
$string = get_category_link( $category[0]->cat_ID );
//┬а┬а ┬а┬а┬а ┬аecho $string;
?>
<div><a href=”http://www.anotherway.org/category/<?php echo get_cat_slug(6); ?>”>View All Save Your Health</a></div>