
wordpress
璞~
这个作者很懒,什么都没留下…
展开
-
WordPress 开发笔记
helloword原创 2022-05-16 10:20:12 · 158 阅读 · 0 评论 -
wordpress 调用指定页面内容详解2 get_children()
$pages = get_children(array( 'numberposts' =>8,//显示条数 'post_parent' =>44388//父级ID )); var_dump($pages);exit;原创 2022-04-22 16:24:58 · 279 阅读 · 0 评论 -
wordpress 调用指定文章列表
<?phpquery_posts('cat=2859&orderby=new');while(have_posts()): the_post();?> <div class="swiper-slide"> <a href="<?php the_permalink(); ?>" title="<?php the_title() ?>"> <?php the_post_thumbna.原创 2022-04-15 17:52:00 · 672 阅读 · 0 评论 -
WordPress获取当前TAG别名(slug)、ID
WordPress是一个非常优秀的PHP内容管理系统。Wordpress帮我们提供了很多的函数,TAG标签用得最多的函数就是single_tag_title()、get_tags()、the_tags()。如果我们要在标签页面获取当前TAG的id,获取TAG的slug呢?可能不能直接用wordpress的函数。下面看一下Wordpress如何获取当前TAG别名(slug)、ID?1、第一步获取当前TAG的名称$name =single_tag_title('', false);2、使用原创 2022-03-21 16:37:24 · 1680 阅读 · 0 评论