pageadmin cms模板建站和帝国cms模板建站哪款比较好?
前者相对比较简单、后台也比较符合新老站长的建站需求;后者界面一直没有更新、相对后台繁琐而复杂、不太适合新手用户建站的。pageadmin大公司用得多。帝国CMS 7.5仿《酷酷游戏网 》源码,帝国CM
顺晟科技
2019-08-16 15:31:27
412
<?php if (have_posts()) : ?>
<?php while (have_posts()) : the_post(); ?>
<?php endwhile; ?>
<?php else : ?>
<?php endif; ?>
标题:<a href=”<?php the_permalink() ?>”><?php the_title_attribute(); ?></a>
调用文章内容:
<?php the_content(“Read More…”); ?>
调用文章内容摘要:
<?php the_excerpt(“Read More…”); ?>
作者:<?php the_author_posts_link(); ?>
日期:<?php the_time(‘F d, Y’) ?>
<?php the_time(‘m-d’) ?>
<?php the_date_xml()?>
评论调用:<?php comments_number(‘No Comment’, ‘1 Comment’, ‘% Comments’ );?>
文章所属分类:标签:<?php the_category(‘, ‘) ?>
上一页,下一页调用:
<div style=”float:left”><?php previous_post_link(‘« %link’); ?></div>
<div style=”float:right”><?php next_post_link(‘%link »’); ?></div>
在single.php中调用<?php endwhile; ?>和<?php else : ?>中间让入
<?php comments_template(); ?>
Page.php和single.php一样
archive.php和index.php一样
添加functions.php,
<?php
if ( function_exists(‘register_sidebar’) )
register_sidebar(array(
‘before_widget’ => ‘<div class=”sidebox”> ‘,
‘after_widget’ => ‘</div>’,
‘before_title’ => ‘<h2>’,
‘after_title’ => ‘</h2>’,
));
?>
在sidebar.php中模块最上面插入:
<?php if ( !function_exists(‘dynamic_sidebar’)
|| !dynamic_sidebar() ) : ?>
Sidebar最下面,添加<?php endif; ?>
14
2022-09
14
2022-09
14
2022-09
14
2022-09
14
2022-09
28
2021-06