标签:
1‘标题:
{if isset($SEO[‘title‘]) && !empty($SEO[‘title‘])}{$SEO[‘title‘]}{/if}{$SEO[‘site_title‘]}
2.搜索关键词:<meta name="keywords" content="{$SEO[‘keyword‘]}">
网站描述:<meta name="description" content="{$SEO[‘description‘]}">
SEO技巧:网页描述不要超过40个字,否则被认为作弊。
3.
{CSS_PATH}:http://localhost/phpcms/statics/css/(CSS样式表路径)
{JS_PATH}:http://localhost/phpcms/statics/js/(JS路径)
{IMG_PATH}:http://localhost/phpcms/statics/images/(图片路径)
{_PATH}:http://localhost/phpcms/uploadfile/(附件路径)
4.PC标签
{pc:content action="position" posid="9" order="id" num="10" cache="3600"}
<div id="announ">
<ul>
{loop $data $k $v}
<li><a href="{$v[url]}">{$v[title]}</a></li>
{/loop}
</ul>
</div>
{/pc}
{pc:content 参数名="参数值" 参数名="参数值" 参数名="参数值"}{/pc}
登录注册:
<script type="text/javascript">document.write(‘<iframe src="{APP_PATH}index.php?m=member&c=index&a=mini&forward=‘+encodeURIComponent(location.href)+‘&siteid={get_siteid()}" allowTransparency="true" width="500" height="24" frameborder="0" scrolling="no"></iframe>‘)</script>
{APP_PATH}:http://localhost/phpcms/(网站根目录)
{get_siteid()}:获取当前站点的ID号。
{siteurl($siteid)}:http://localhost/phpcms/(站点首页)
5.搜索部分:
搜索对象是搜索的新闻?图片?下载?专题?
<div class="tab" id="search">
{php $j=0}
{php $search_model = getcache(‘search_model_‘.$siteid, ‘search‘);}
{loop $search_model $k=>$v}
{php $j++;}
<a href="javascript:;" onclick="setmodel({$v[‘typeid‘]}, $(this));" style="outline:medium none;" hidefocus="true" {if $j==1 && $typeid=$v[‘typeid‘]} class="on" {/if}>{$v[‘name‘]}</a>{if $j != count($search_model)}<span> | </span>{/if}
{/loop}
{php unset($j);}
</div>
6.表单部分:
<div class="bd">
<form action="{APP_PATH}index.php" method="get" target="_blank">
<input type="hidden" name="m" value="search"/>
<input type="hidden" name="c" value="index"/>
<input type="hidden" name="a" value="init"/>
<input type="hidden" name="typeid" value="{$typeid}" id="typeid"/>
<input type="hidden" name="siteid" value="{$siteid}" id="siteid"/>
<input type="text" class="text" name="q" id="q"/><input type="submit" value="搜 索" class="button" />
</form>
</div>
7.广告位部分:
<script language="javascript" src="{APP_PATH}index.php?m=poster&c=index&a=show_poster&id=1"></script>
8.菜单部分:
<map>
{pc:content action="category" catid="0" num="25" siteid="$siteid" order="listorder ASC"}
<ul class="nav-site">
<li><a href="{siteurl($siteid)}"><span>首页</span></a></li>
{loop $data $r}
<li class="line">|</li>
<li><a href="{$r[url]}"><span>{$r[catname]}</span></a></li>
{/loop}
</ul>
{/pc}
{php echo runhook(‘glogal_menu‘)}
</map>
8.子菜单:
{if $top_parentid}
<div class="subnav">
{pc:content action="category" catid="$top_parentid" num="15" siteid="$siteid" order="listorder ASC"}
{loop $data $r}
<a href="{$r[url]}">{$r[catname]}</a><span> | </span>
{/loop}
{/pc}
<a href="{APP_PATH}index.php?m=video&c=index&a=album">视频专辑</a> <span> | </span>
{if $modelid}<a href="{APP_PATH}index.php?m=content&c=search&catid={$catid}">搜索</a>{/if}
</div>
{/if}
标签:
原文地址:http://www.cnblogs.com/shark1100913/p/5573605.html