模板置标使用手册.docx

上传人:b****6 文档编号:7250391 上传时间:2023-05-11 格式:DOCX 页数:70 大小:976.09KB
下载 相关 举报
模板置标使用手册.docx_第1页
第1页 / 共70页
模板置标使用手册.docx_第2页
第2页 / 共70页
模板置标使用手册.docx_第3页
第3页 / 共70页
模板置标使用手册.docx_第4页
第4页 / 共70页
模板置标使用手册.docx_第5页
第5页 / 共70页
模板置标使用手册.docx_第6页
第6页 / 共70页
模板置标使用手册.docx_第7页
第7页 / 共70页
模板置标使用手册.docx_第8页
第8页 / 共70页
模板置标使用手册.docx_第9页
第9页 / 共70页
模板置标使用手册.docx_第10页
第10页 / 共70页
模板置标使用手册.docx_第11页
第11页 / 共70页
模板置标使用手册.docx_第12页
第12页 / 共70页
模板置标使用手册.docx_第13页
第13页 / 共70页
模板置标使用手册.docx_第14页
第14页 / 共70页
模板置标使用手册.docx_第15页
第15页 / 共70页
模板置标使用手册.docx_第16页
第16页 / 共70页
模板置标使用手册.docx_第17页
第17页 / 共70页
模板置标使用手册.docx_第18页
第18页 / 共70页
模板置标使用手册.docx_第19页
第19页 / 共70页
模板置标使用手册.docx_第20页
第20页 / 共70页
亲,该文档总共70页,到这儿已超出免费预览范围,如果喜欢就下载吧!
下载资源
资源描述

模板置标使用手册.docx

《模板置标使用手册.docx》由会员分享,可在线阅读,更多相关《模板置标使用手册.docx(70页珍藏版)》请在冰点文库上搜索。

模板置标使用手册.docx

模板置标使用手册

CMS模板置标使用手册

一首页.html

1.1首页导航

首页导航循环从数据库中获取栏目,首页栏目页内容页导航代码是一样的。

效果图如下:

1.1.1一级导航

  • [@cms_channel_list]

    首页

    [#listtag_listasc]

    ${c.name}

    [/#list]

    [/@cms_channel_list]

${base}/回到首页标签

${c.url}栏目链接

${c.name}栏目名称

1.1.2多级导航

    [@cms_channel_list]

  • 网站首页
  • [#listtag_listasc][@cms_channel_listparentId=c.id]

    [#iftag_list?

    size>0]

    [#else]

  • [/#if][/@cms_channel_list]${c.name}

    [@cms_channel_listparentId=c.id][#iftag_list?

    size>0]

      [@cms_channel_listparentId=c.id][#listtag_listasc1][@cms_channel_listparentId=c1.id][#iftag_list?

      size>0]

      [#else]

    • [/#if][/@cms_channel_list]${c1.name}[@cms_channel_listparentId=c1.id][#iftag_list?

      size>0]

        [@cms_channel_listparentId=c1.id][#listtag_listasc2]

      • ${c2.name}
      • [/#list]

        [/@cms_channel_list]

      [/#if][/@cms_channel_list]

    • [/#list][/@cms_channel_list]

    [/#if][/@cms_channel_list]

  • [/#list][/@cms_channel_list]

1.2首页图片切换

[@cms_content_listtypeId='3'styleList='3-1'titLen='20'count='5'flashWidth='300'flashHeight='200'textHeight='20'channelOption='1'tpl='2'/]

typeId='3'表示取类型为“焦点”的新闻的类型图来展示。

styleList='3-1'图片切换flash的样式,默认有三种样式,还包括'3-2','3-3'

titLen='20'新闻标题截取长度。

count='5'切换图片个数

flashWidth='300'flash高度

flashHeight='200'flash宽度

textHeight='20'标题高度,如果设置为0,则不显示标题。

1.3首页新闻列表

此框标签的作用是获取新闻列表的栏目名称及more图标。

[@cms_channelid='60']

${tag_bean.name}

[/@cms_channel]

—more图标-->

[@cms_channelid='60']

[/@cms_channel]

[@cms_channelid='60']取id为60的栏目相关信息

${tag_bean.url}栏目的超链接

${tag_bean.name}栏目的名称

此标签作用是循环获取channelId='60'新闻栏目下的新闻内容。

循环获取新闻内容。

channelId即栏目id,

orderBy='4'代表最新发布的文章放最上面。

titLen='20'截取的新闻标题长度

count='5'代表显示5条记录。

dateFormat='yyyy-MM-dd',定义日期格式。

[@text_cuts=a.titlelen=titLenappend=append/]

表示截取titLen这个长度的新闻标题进行显示。

append='...'表示超过截取标题长度后,以…结尾。

 

[@cms_content_listtpl='2'styleList='1-1'lineHeight='2'showTitleStyle='1'bottomLine='1'headMark='3'dateFormat='MM-dd'datePosition='2'titLen='10'append='…'count='3'channelId='2589'channelOption='1'/]

styleList='1-1'可以选择不同的新闻列表的样式

showTitleStyle='1'可以选择是否显示标题的样式:

变色,加粗等

bottomLine='1'是否有底线

headMark='3'选择新闻头部的箭头的样式

datePosition='2'选择时间的样式

1.4带有new图标,字体加粗,变色的首页新闻列表

[@cms_content_listchannelId='1043'siteId=1026orderBy='4'count='5'titLen='25'descLen='40'channelOption='1'dateFormat='yyyy-MM-dd']

[#listtag_listasa]

  • [#ifa.titleColor?

    exists]

    ${a.titleColor}'target=_blank>

    [#else]

    [/#if]

    [#ifa.bold==true]

    [@text_cuts=a.titlelen=titLenappend=append/]

    [#else]

    [@text_cuts=a.titlelen=titlenappend=append/]

    [/#if]

    [#ifa.isNewContentFlag?

    exists]

    [#ifa.isNewContentFlag=="1"]

    [#ifa.contentFlagHoldTime?

    ?

    ]

    [#ifa.contentFlagHoldTime?

    datetimegta.currentDate?

    datetime]

    [#ifa.newContentImgFlag?

    ?

    ]

    [/#if]

    [/#if]

    [/#if]

    [/#if]

    [/#if]

  • [/#list]

    [/@cms_content_list]

    1.5图文新闻

    1.5.1类型图

    [@cms_content_listtypeId=2count=1titLen=10channelOption="1"siteId=4]

    [#listtag_listasa]

    site.defImg}"alt="${a.title}"/>

    [@text_cuts=a.txtlen="145"append="......"/]

    [/#list][/@cms_content_list]

    typeId=2取新闻类型为图文的新闻的类型图。

    site.defImg}"alt="${a.title}"/>

    取此条新闻的类型图,即上传的图片。

    [@text_cuts=a.txtlen="145"append="......"/]

    取此条新闻的内容,截取长度为145,多出的用……代替

    1.5.2标题图

    [@cms_channelid='2']${tag_bean.name}[/@cms_channel]

    [@cms_content_listchannelId='2'orderBy='4'count='6'titLen='20'descLen='40'append='...'channelOption='1']

    [#listtag_listasa]

    [#ifa_index=0]

    ${a.stit!

    }

    site.defImg}"alt="${a.title}"/>

    [@text_cuts=a.desclen=descLenappend=append/]

    [#else]

    [${a.ctgName}][@text_cuts=a.titlelen=titLenappend=append/]

    [/#if]

    [/#list]

    [/@cms_content_list]

    [#ifa_index=0]如果是第一篇新闻

    ${a.stit}显示新闻的标题

    ${a.ctgUrl}新闻所在栏目的链接

    [${a.ctgName}]新闻所在栏目的名字

    [@text_cuts=a.desclen=descLenappend=append/]摘要

    site.defImg}"alt="${a.title}"/>标题图

    1.6滚动

    1.6.1图文列表向左滚动

    以下js放在head标签里。

    [@cms_content_listtopicId='1'typeId='2'count='8'styleList='2-4'titLen='16'rollLineHeight='70'rollSpan='1'rollSpeed='1'tpl='2'/]

    说明:

    rollLineHeight:

    滚动区行高;【按像素px计算】不能为空

    rollSpeed:

    滚动速度;【滚动速度,值越小越快,最小为1】不能为空

    rollSpan:

    滚动跨度;【一次滚动的像素,跨度越大,滚动就越快,但越不流畅】不能为空

    topicId='1'滚动中的图片要属于一个专题

    typeId='2'图片所在内容是图文类型

    1.6.2图文向上滚动

    [@cms_content_listtopicId='2'typeId='2'styleList='2-2'titLen='16'rollLineHeight='115'rollSpan='1'rollCols='4'rollSpeed='1'isSleep='1'rollSleepTime='500'rollDisplayHeight='115'tpl='2'/]

    1.6.3文字列表向上滚动

    [@cms_content_liststyleList='2-1'titLen='10'count='9'rollCols='3'rollDisplayHeight='20'rollLineHeight='29'rollSpeed='20'rollSleepTime='100'rollRows='1'dateFormat='MM-dd'datePosition='3'dateClass='red'channelOption='1'channelId='95'tpl='2'/]

    rollCols:

    滚动列数

    rollRows:

    滚动行数

    channelId='95':

    表示文字列表只获取栏目编号为95的内容。

    1.6.4首页滚动资讯:

    [@cms_channel_list]

    首页

    [#listtag_listasc]

    size+1})">${c.name}

    [/#list]

    [/@cms_channel_list]

  • 滚动资讯:

  • [@cms_content_liststyleList='2-1'titLen='16'count='9'rollCols='3'rollDisplayHeight='20'rollLineHeight='20'rollSpeed='20'rollSleepTime='100'rollRows='1'dateFormat='MM-dd'datePosition='3'dateClass='red'channelOption='1'tpl='2'/]

    [@cms_channel_list]

    [#listtag_listasc]

    [@cms_channel_listparentId=c.id]

    [#listtag_listassub]

  • ${sub.name}
  • [/#list]

    [/@cms_channel_list]

    [/#list]

    [/@cms_channel_list]

    1.7文章显示所在栏目:

    [栏目名称]

    [@cms_content_listchannelId='2'orderBy='4'count='6'titLen='20'descLen='40'append='...'channelOption='1']

    [#listtag_listasa]

  • [${a.ctgName}]

    [@text_cuts=a.titlelen=titLenappend=append/]

  • [/#list]

    [/@cms_content_list]

    titLen='20'标题长度

    ${a.ctgUrl}新闻所在栏目的地址

    ${a.ctgName}新闻所在栏目的名字

    1.8常用标签

    1.8.1常用tags

    即定义的一些关键字,可以通过点击这些关键字查询到相关新闻。

    首先要在系统设置Tag管理处添加tag常用标签,比如添加反邪教

    之后再添加文章时,”Tag标签处”填写反邪教。

    [@cms_tag_listcount='8']

    [#listtag_listastag]

    ${tag.name}

    [#iftag_has_next]|

    [/#if]

    [/#list]

    [/@cms_tag_list]

    1.8.2标签详情页

    500px;">

    [@cms_content_pagetagId=tag.idcount='10'descLen='100'append='...']

    “${tag.name}”Tag标签共有${tag_list?

    size}条相关资讯:

    [#listtag_pagination.listass]

    [${s.ctgName}]${s.title}

    [@text_cuts=s.descriptionlen=descLenappend=append/]

    来源:

    }"target="_blank">${s.origin!

    '本站原创'}  浏览次数:

    ${s.views}次  发布时间:

    ${s.releaseDate}

    [/#list]

    [@cms_paginationsysPage='1'/]

    [/@cms_content_page]

    1.9图片友情链接

    [@cms_content_listtypeId=2count=5titLen=10channelId=45854channelOption="1"siteId=1936]

    [#listtag_listasa]

    site.defImg}"width="180"height="45"alt=""/>

    [#if(a_index+1)%5!

    =0&&a_index!

    =tag_list?

    size]

     

    [/#if]

    [/#list][/@cms_content_list]

    1.10首页栏目页中新闻列表时间标签

    ${a.date?

    string(dateFormat)}

    1.11首页序号变化

    [#if(a_index+1)%2==0&&a_index!

    =tag_list?

    size]

    1.12首页头条

    [@cm

    展开阅读全文
    相关资源
    猜你喜欢
    相关搜索
    资源标签

    当前位置:首页 > 医药卫生 > 基础医学

    copyright@ 2008-2023 冰点文库 网站版权所有

    经营许可证编号:鄂ICP备19020893号-2