文档下载 文档下载导航
设为首页 | 加入收藏
搜索 请输入内容:  
 导航当前位置: 文档下载 > 所有分类 > IT/计算机 > wordpress高级函数
侵权投诉

wordpress高级函数

wordpress高级函数

WPCANDY Advanced WordPress Help Sheet

<?php if ( is_home() ) { include ('example.php'); } ?>

This snippet will include the le speci ed, only if the user is on the home page of the site. Place this code in the index.php le.

<?php if ( is_category('15') ) {

<link rel="stylesheet" href="<?php

bloginfo('template_url'); ?>/cat-15.css" type="text/css"

media="screen" />;

<?php } else { ?>

<link rel="stylesheet" href="<?php

bloginfo('stylesheet_url'); ?>" type="text/css" media="screen"

/>

<?php } ?>

This snippet assigns a speci c stylesheet (category-15.css) to category 15 and will assign the rest of the site the default stylesheet (style.css). Place this code in the <head> area.

<?php if (is_category('7') ):

<img src='<?php

bloginfo('template_url'); ?>/images/cat7.jpg' alt='' /> <?php }

elseif (is_category('8') ):

<img src='<?php

bloginfo('template_url'); ?>/images/cat8.jpg' alt='' /> <?php

endif; ?>

This snippet assigns an image (cat7.jpg) next to each post title in category 7 and an image (cat8.jpg) next to each post title in category 8. Place this code in the category.php le.

<div id="post-<?php the_ID(); ?>">

This snippet will assign the post ID to the DIV. For example, if the ID for the post is 8, that line will

第1页

你可能喜欢

热门文档

相关文档

  • WordPress模板的简单介绍以及常用函数

    超详细WordPress常用函数... 22页 免费 WordPress高级教程 60页 免费...WordPress模板基本文件 style.css 样式表文件 <?php bloginfo( 'stylesheet_...

  • 通俗易懂的WordPress函数简明教程

    WordPress主题函数 3页 免费 wordpress常用函数 2页 免费 wordpress高级函数 ...WordPress 是目前十分流行的独立博客程序,因傻瓜化安装和使用,其在网 民中的...

  • WordPress高级教程

    WordPress高级教程_计算机软件及应用_IT/计算机_专业资料。精通WordPress 主题制作...> : 将由 WordPress 函数自动生成的信息传回博客, 然后再在其他地方使用你的 ...

  • wordpress函数说明(已汉化中文)

    wordpress函数说明(已汉化中文)_互联网_IT/计算机_专业资料。终于有人翻译成... WordPress高级教程 60页 1下载券 将WordPress扩展成CMS的... 10页 免费...

  • wordpress函数大全-补完

    wordpress函数大全-补完_数学_自然科学_专业资料。wordpress函数大全,维度空间www.vduzone.com提供今天想给博客弄个留言页面,又不想要它太过简单,在网上搜代码,...

  • wordpress函数使用介绍

    ($v); wordpress部分函数理解 1.get_post():根据ID返回文章信息★必须知道的用法: <?php $id=5; $content=get_post($id); //ID参数必须是一个变量 //...

  • WordPress高级教程

    高级教程 r P es 无忧学院:5uxy.com 精通 WordPress 主题制作技巧 <?php get_bloginfo (''); ?> : 将由 WordPress 函数自动生成的信息传回博客, 然后再在...

  • wordpress调用函数大全

    wordpress调用函数大全_数学_自然科学_专业资料。wordpress调用函数大全WordPress 中模版代码 WordPress 中的文件 style.css 样式表文件 index.php 主页文件 single....

  • wordpress调用函数大全

    wordpress调用函数大全_互联网_IT/计算机_专业资料。详细罗列了WordPress的调用... wordpress代码调用大全 31页 2下载券 WordPress高级教程 60页 免费...

  • wordpress常用函数及使用方法

    wordpress常用函数及使用方法_IT/计算机_专业资料。wordpress常用函数及使用方法1.<?phpget_sidebar(); ?>sidebar.php <?phpget_footer(); ?>footer.php <?...

站点地图 | 文档上传 | 侵权投诉 | 手机版
本站所有资源均来自互联网,本站只负责收集和整理,均不承担任何法律责任,如有侵权等其它行为请联系我们.
文档下载 Copyright 2013 doc.guandang.net All Rights Reserved.  -  email