站长百科 | 数字化技能提升教程 数字化时代生存宝典
首页
数字化百科
电子书
▼
建站程序
开发
服务器
办公软件
开发教程
▼
服务器教程
软件使用教程
运营教程
热门电子书
▼
CSS教程
WordPress教程
导航
程序频道
推广频道
网赚频道
人物频道
网站程序
网页制作
云计算
服务器
CMS
论坛
网店
虚拟主机
cPanel
网址导航
WIKI使用导航
WIKI首页
热点词条
最新资讯
网站程序
站长人物
页面分类
使用帮助
编辑测试
创建条目
网站地图
站长百科导航
站长百科
主机侦探
IDCtalk云说
跨境电商导航
WordPress啦
站长专题
网站推广
网站程序
网站赚钱
虚拟主机
cPanel
网址导航专题
云计算
微博营销
虚拟主机管理系统
开放平台
WIKI程序与应用
美国十大主机
编辑“
WordPress:Customizing Your Sidebar
”(章节)
人物百科
|
营销百科
|
网赚百科
|
站长工具
|
网站程序
|
域名主机
|
互联网公司
|
分类索引
跳转至:
导航
、
搜索
警告:
您没有登录。如果您做出任意编辑,您的IP地址将会公开可见。如果您
登录
或
创建
一个账户,您的编辑将归属于您的用户名,且将享受其他好处。
反垃圾检查。
不要
加入这个!
==导航== Historically, the main purpose of the sidebar has been to provide navigation assistance for the visitor - a function that commonly continues to the present day. These navigation aids are designed to help people move about your site and find the information you want them to see. The list of navigation items includes [[WordPress:Administration_Panels#Categories|Categories]], [[WordPress:Pages]], [[WordPress:WordPress_Features#Archives_and_Search|Archives]], and even the most recent posts. Another navigational tool you'll see in the sidebar is a search form to help people find what they are looking for on your site. 从历史记录来看,边栏的主要目的是为访客提供导航帮助-一直持续到今天的功能。设计这些导航帮助是要帮助人们在你的站点上浏览,并且找到你想要显示的信息。导航列表内容包括[[WordPress:Administration_Panels#Categories|类别]], [[WordPress:Pages|网页]], [[WordPress:WordPress_Features#Archives_and_Search|归档]]和最近的文章。你在边框中看到的另一个导航工具是搜索形式,用来帮助人们找到他们在你的站点上查找的内容。 The first information in the standard WordPress installation is a list of [[WordPress:Pages]] or Categories. Listing [[WordPress:Pages]] helps the visitor find more information about your site, like '''About''', '''Contact''', '''Register''', or '''Site Map'''. 标准的WordPress安装中首次出现的信息,就是一列[[WordPress:Pages|网页]]或者类别。列出[[WordPress:Pages|网页]]帮助访客找到更多的关于你的站点的信息,像'''关于''', '''联系''', '''登录''', 或者 '''站点 地图'''。 The information displayed in the sidebar is controlled by your [[WordPress:Using Themes|Theme's]] [[WordPress:Templates|Template]] <tt>sidebar.php</tt> file. 边栏中显示的信息,有你的[[WordPress:Using Themes|主题的]] [[WordPress:Templates|模板]] <tt>sidebar.php</tt> 文件控制。 An example usage of the Pages list template tag in your <tt>sidebar.php</tt> file might be: <tt>sidebar.php</tt> 文件中的网页列表模板标签的用法例子可能是: <?php wp_list_pages('title_li=<h2>Pages</h2>'); ?> <?php wp_list_pages('title_li=<h2>Pages</h2>'); ?> This puts the title '''Pages''' in an <tt>H2</tt> heading and then puts the Pages in a list below the title. This is just one sample of its usage and there are more options available for controlling the end result of the template tag called [[WordPress:Template Tags/wp_list_pages|wp_list_pages()]]. 这个例子使得标题'''网页'''放入了<tt>H2</tt>标题中,然后将网页放入标题下面的列表中。这只是用法的一个例子,还有更多的选项用来控制称为[[WordPress:Template Tags/wp_list_pages|wp_list_pages()]]的模板标签的最后结果。 Listing the [[WordPress:Template Tags/wp_list_cats|Categories]] helps the visitor find the information they want by topic. This might look like: 列出[[WordPress:Template Tags/wp_list_cats|类别]]帮助访客找到他们想要的信息。这可能看起来像: <pre><li id="categories"><?php _e('Categories:'); ?> <ul> <?php wp_list_cats(); ?> </ul> </li></pre> <pre><li id="categories"><?php _e('Categories:'); ?> <ul> <?php wp_list_cats(); ?> </ul> </li></pre> This lists the title '''Categories''' within the <tt>menu</tt> list, and then creates a nested list underneath to list the WordPress categories you've added to your site. If you have no posts in a category, it will not show up on the list by default. Add a post, and it will be there. 这个在<tt>菜单</tt>列表内列出了标题'''类别''',然后在下面创建了嵌套的列表,列出了你添加到站点上的WordPress类别。如果类别中没有文章,默认情况下,就不会显示列表。添加一篇文章,列表就会显示。 The WordPress Default Theme, Kubrick, uses a set of navigation tags on its <tt>index.php</tt> template file, but you can use this same set in your sidebar to emphasize the navigation from one post to another in chronological order: WordPress默认主题,Kubrick,在它的<tt>index.php</tt>模板文件中使用一组导航标签,但是你可以在你的边框中使用同样的导航标签,突出按时间顺序,从一篇文章导航到另一篇文章: <pre><div class="navigation"> <div class="alignleft"> <?php next_posts_link('&laquo; Previous Entries') ?> </div> <div class="alignright"> <?php previous_posts_link('Next Entries &raquo;') ?> </div> </div></pre> <pre><div class="navigation"> <div class="alignleft"> <?php next_posts_link('&laquo; Previous Entries') ?> </div> <div class="alignright"> <?php previous_posts_link('Next Entries &raquo;') ?> </div> </div></pre> This example puts the text for the links to the right and left parts of the screen. You can change this to something more suitable to your sidebar's look by changing the style sheet references or by further customizing the [[WordPress:Template_Tags/next_post|next and previous post links]]. 这个例子将链接的文本放置到屏面的右边和左边的部分。通过更改样式表references或者通过自定义[[WordPress:Template_Tags/next_post|下一个和上一个文章链接]]你可以更改这种链接文本的位置,使得布局更适合你的边栏的外观。
摘要:
请注意,您对站长百科的所有贡献都可能被其他贡献者编辑,修改或删除。如果您不希望您的文字被任意修改和再散布,请不要提交。
您同时也要向我们保证您所提交的内容是您自己所作,或得自一个不受版权保护或相似自由的来源(参阅
Wordpress-mediawiki:版权
的细节)。
未经许可,请勿提交受版权保护的作品!
取消
编辑帮助
(在新窗口中打开)