简体   繁体   English

将旋转滑块添加到Kentico 7

[英]Adding a Revolution Slider to Kentico 7

我正在尝试使用Kentico 7将使用JavaScript jquery.themepunch.revolution和jquery.themepunch.plugins.min的自定义横幅滑块放入我的网站中。如何在我的主页上进行该处理?

Your first step would be to decide what information you wanted to show. 您的第一步是确定您想要显示的信息。 Typically, this will be a collection documents (images) in your content tree. 通常,这将是内容树中的一个收集文档(图像)。 Once you have your collection, you will use a transformation to decide the layout for each item you want to display. 有了收藏集后,您将使用转换来确定要显示的每个项目的布局。

http://devnet.kentico.com/docs/7_0/controls/cmsrepeater_overview.htm http://devnet.kentico.com/docs/7_0/controls/cmsrepeater_overview.htm

For you JS, you will need to include the appropriate libraries on the page. 对于JS,您需要在页面上包括适当的库。 You can do this in the Master Page (if you want it on all pages), using the JS web part (which is good for a single page that needs it), or even on a Page Template level (if you had many pages that need the functionality and all use the same template). 您可以在母版页(如果需要在所有页面上使用)上进行此操作,可以使用JS Web部件(这对于需要它的单个页面非常有用),甚至可以在页面模板级别(如果您有很多页面需要这样做)需要功能,并且都使用相同的模板)。

Once you have the JS in place, you will need update your transformation to have the proper layout to match the JS library. 放置好JS之后,您将需要更新转换以具有正确的布局以匹配JS库。 Typically with sliders, each "image" will need a specific tag or attribute. 通常,使用滑块时,每个“图像”都需要一个特定的标签或属性。 You can easily add this to the transformation you use to display the content. 您可以轻松地将此添加到用于显示内容的转换中。

While Version 7 is pretty old (3+ years), you can still find a lot of documentation and info in the Developer's Guide here: 虽然版本7相当旧(超过3年),但是您仍然可以在此处的开发人员指南中找到很多文档和信息:

http://devnet.kentico.com/docs/7_0/devguide/index.html http://devnet.kentico.com/docs/7_0/devguide/index.html

If you have multiple banners with a background image, text content, and link, you might want to consider using a custom document type. 如果您有多个带有背景图像,文本内容和链接的横幅,则可能要考虑使用自定义文档类型。 That would make it easier to manage the content. 这样可以更轻松地管理内容。 Then as Bryan suggested, you would create the transformations and display the data using a repeater. 然后按照Bryan的建议,您将创建转换并使用中继器显示数据。

Kentico Documentation: Creating custom document types Kentico文档: 创建自定义文档类型

Blog: Working with javascript carousel sliders in Kentico 博客: 在Kentico中使用javascript轮播滑块

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM