[wordpress插件] DGE_SlideshowDGE_Slideshow

wordpress 插件 文章 2020-04-16 15:10 1177 0 全屏看文

AI助手支持GPT4.0

评分
0
描述

The plugin takes an image source (e.g. RSS feed or web page), passes

该插件获取图片来源(例如RSS feed或网页),并通过

it through XSLT via the

通过
通过XSLT

DGE_InlineRSS

DGE_InlineRSS

plugin, then uses javascript and css in the client to do the actual

插件,然后在客户端中使用javascript和CSS进行实际的操作

slideshow.

幻灯片。

Because of the use of XSLT, it’s fairly flexible, allowing new image

由于使用了XSLT,它相当灵活,允许添加新图像

sources to be made available quickly.

来源,以便迅速提供。

It’s still under development, but working nicely on Firefox 1.5, 2.0,

它仍在开发中,但是可以在Firefox 1.5、2.0上很好地工作,

IE 6 (Win) and 7. Please feel free to submit bugs and suggest features

IE 6(Win)和IE7。请随时提交错误并建议功能

by posting questions etc on the

通过在
上发布问题等

home page.

主页

Requirements

要求

    • Javascript.
    • JavaScript。

    • DGE_InlineRSS

    • DGE_InlineRSS

      plugin version 0.93 or greater.

    • 插件版本0.93或更高版本。

    • Only tested with WordPress 2.0 and 2.1.

    • 仅在WordPress 2.0和2.1上进行过测试。

      I don’t know if it’ll work

      我不知道是否行得通

      with earlier versions.

    • 使用早期版本。

    • PHP 5.
    • PHP 5。

    Examples

    示例

    The latest stable version with various applications of the slideshow

    具有幻灯片应用程序的最新稳定版本

    is here.

    此处

    The latest trunk is up and (probably) running

    最新的中继已启动并且(可能)正在运行

    here.

    此处

    Usage

    用法

    You can invoke a slideshow by either placing a specially formatted

    您可以通过放置特殊格式的幻灯片来调用幻灯片

    string into any page or post, or from your theme templates with a call

    字符串插入任何页面或帖子,或通过调用从主题模板中输入字符串

    to DGE_SlideShow function.

    DGE_SlideShow 函数。

    For both methods, the arguments are the

    对于这两种方法,参数都是

    same, but the call is different.

    相同,但通话方式不同。

    Both methods of invokation require:

    两种调用方法都需要:

    * a unique id

    *唯一ID

    * a url to fetch

    *要提取的网址

    * options

    *选项

    The id must be unique for each slideshow, and must be a valid

    每个幻灯片的ID必须是唯一的,并且必须是有效的

    javascript variable name, with the exception that it may start with a

    javascript变量名称,但可以以
    开头

    number.

    数。

    So it must not contain spaces or dashes, for example.

    因此,例如,不得包含空格或破折号。

    Filter method

    过滤方法

    When you activate the plugin, it installs a content filter into

    激活插件时,它会在其中安装内容过滤器

    wordpress.

    WordPress的。

    This filter looks for strings beginning with !slideshow!,

    此过滤器查找以!slideshow!
    开头的字符串

    followed by the 2 required parameters, and a list of options.

    然后是2个必需参数和一个选项列表。

    Each of

    每个

    these parts of the filtered string must be separated by an exclamation

    过滤后的字符串的这些部分必须用感叹号分隔。

    mark.

    标记。

    Options must be separated by a semi-colon.

    选项必须用分号分隔。

    If you want to

    如果你想

    include more than one slideshow in succession, make sure they are

    连续包含多个幻灯片,请确保它们是

    defined on a new line for each call.

    在每次通话的新行中定义。

    Here’s the syntax:

    语法如下:

    !slideshow!![!;...]!

     !slideshow! [!;  ...]!

    Here’s a few examples:

    以下是一些示例:

    !slideshow!ss1!http://beta.zooomr.com/bluenote/feeds:rssecent/!

     <代码>!slideshow!ss1!http://beta.zooomr.com/bluenote/feeds:rss / recent /!

    !slideshow!ss2!http://beta.zooomr.com/bluenote/feeds:rssecent/!limit=5!

    !slideshow!ss2!http://beta.zooomr.com/bluenote/feeds:rss / recent /!limit = 5!

    !slideshow!ss3!http://beta.zooomr.com/bluenote/feeds:rssecent/!limit=5;reverse!

    !slideshow!ss3!http://beta.zooomr.com/bluenote/feeds:rss / recent /!limit = 5;反向!

    From php (your theme templates)

    来自php(您的主题模板)

    The DGE_SlideShow function takes three parameters.

    DGE_SlideShow 函数具有三个参数。

    The first is the

    首先是

    unique id for your slideshow, followed by the url of the desired feed,

    幻灯片的唯一ID,后跟所需Feed的网址,

    followed by an array of optional arguments.

    然后是可选参数数组。

    The function returns a

    该函数返回一个

    string with the necessary javascript and html to set up the slideshow,

    字符串以及必要的javascript和html来设置幻灯片,

    so just echo it.

    所以只需 echo

    For example:

    例如:

    // From version 0.3 and above

      //从0.3版及更高版本开始

    echo DGE_SlideShow('ss1', 'http://beta.zooomr.com/bluenote/feeds:rssecent/', array('limit'=>5,'reverse'=>1));

    Options

    echo DGE_SlideShow('ss1','http://beta.zooomr.com/bluenote/feeds:rssecent/',array('limit'=> 5,'reverse'=> 1));

    选项

    limit

    限制

      • Limits the number of images extracted from the feed.

      • 限制从提要中提取的图像数量。

        Default is 0,

        默认值为0,

        implying no limit, or everything in the feed.

      • 表示没有限制,或供稿中的所有内容。

      preset

      预设

        • Applies the options defined in the named preset, before overriding

        • 在覆盖之前应用命名的预设中定义的选项

          them with any other options passed.

        • 它们以及其他任何通过的选项。

        reverse

        反向

          • This option doesn’t need any value.

          • 此选项不需要任何值。

            Just by being present, it tells

            只是在场,就告诉了

            the plugin to reverse the order of the images in the feed.

          • 插件以反转提要中图像的顺序。

          timeout

          超时

            • Specify the time in minutes before the cached html is refreshed.

            • 以分钟为单位指定刷新缓存的html之前的时间。

              Set

              设置

              the default in the options pane.

              选项窗格中的默认值。

              It is 1 hour by default.

            • 默认为1小时。

            xslt

            xslt

              • Specify a particular xsl translation file
              • 指定特定的xsl转换文件

              html

              html

                • Assume input url is HTML, rather than XML.

                • 假设输入URL是HTML,而不是XML。

                  (As of v0.392)

                • (从v0.392开始)

                Presets

                预设

                On the slideshow options page, you can set up presets to save you

                在幻灯片选项页面上,您可以设置预设来保存您

                typing the same options in for different slideshow calls.

                在不同的幻灯片播放中键入相同的选项。

                Just give

                只要给

                the preset a name in the left-hand field, and fill in the right-hand

                在左侧字段中预设一个名称,然后填写右侧

                field with the desired options in the same format as the filter

                所需选项的字段,其格式与过滤器相同

                call.

                呼叫。

                That is, separate each option with a semi-colon.

                也就是说,用分号分隔每个选项。

                For example, the name of your preset might be preset1, and you want

                例如,您的预设名称可能是 preset1 ,而您想要

                to always reverse the feed, and have a timeout of only 1 minute.

                始终调换Feed,并且只有1分钟的超时时间。

                Fill

                填写

                in the left-hand field with preset1, and the right hand field with
                    

                在左侧字段中使用 preset1 ,在右侧字段中使用
                    

                reverse;timeout=1.

                向后;超时= 1。

                Another example would be to add a shortcut for Zooomr favourites.

                另一个示例是为Zooomr的收藏夹添加快捷方式。

                Put
                    


                    

                zooomrfaves as the name, and xslt=dge-slideshow/xsl/zooomrfaves.xsl

                Zooomrfaves作为名称,并 xslt = dge-slideshow / xsl / zooomrfaves.xsl

                in the value field, again omitting the quotes.

                在值字段中,再次省略引号。

                You could then invoke a

                然后,您可以调用

                slideshow of a Zooomr set with:

                Zooomr的幻灯片设置:

                !slideshow!zfaves!http://www.zooomr.com/photos/davee/favorites/!preset=zooomrfaves!

                License

                 !slideshow!zfaves!http://www.zooomr.com/photos/davee/favorites/!preset = zooomrfaves!

                许可证

                This work is licensed under a Creative Commons

                该作品已获得知识共享
                的许可

                Attribution-Noncommercial-Share Alike 2.5 License.

                署名-非商业性-相同方式共享2.5许可。

                History

                历史

                Full changelog here

                此处完整的更改日志

                changes in 0.4

                0.4的变化

                  • Bug fixes, mostly for IE.
                  • 错误修复,主要针对IE。

                  • Added a menu bar for navigation etc.
                  • 添加了用于导航等的菜单栏。

                  • Choose number of thumbnails via parameters.
                  • 通过参数选择缩略图的数量。

                  • Zooomr mark III compatibility fixes.
                  • Zoomr mark III兼容性修复程序。

                  • Full-screen mode.
                  • 全屏模式。

                  • Updated options page for specifying defaults.
                  • 更新的选项页面,用于指定默认值。

                  • Simplified XSL, and reorganised XSL files.
                  • 简化的XSL和重新组织的XSL文件。

                  • Structural changes under the hood to separate behaviour from content.
                  • 内部进行结构更改以将行为与内容分开。

                  • Easier to write new data sources, with introduction of data handlers.
                  • 通过引入数据处理程序,更容易编写新的数据源。

                  changes in 0.3

                  0.3的变化

                    • General clean-up and some bug fixes.
                    • 常规清理和一些错误修复。

                    • New xslt parameter to use custom XSL transformations.
                    • 新的 xslt 参数以使用自定义XSL转换。

                    • Cleaned up, modularised XSL files.
                    • 已清理的模块化XSL文件。

                    • New XSL files for Zooomr SmartSets, Zooomr favourites, and Flickr photosets.
                    • 用于Zooomr SmartSet,Zooomr收藏夹和Flickr照片集的新XSL文件。

                    changes in 0.2

                    0.2的变化

                      • Optionally reverse the order of images in the feed.
                      • (可选)反转Feed中图像的顺序。

                      • Security enhancements.
                      • 安全性增强。

                      • Indicates which images are still loading in the background (modifiable with CSS)
                      • 指示哪些图像仍在后台加载(可通过CSS修改)

                      • Admin panel for setting defaults and defining presets.
                      • 用于设置默认值和定义预设的管理面板。

                      • Presets allow quick changing of settings across several slideshows.
                      • 通过预设,可以在多个幻灯片中快速更改设置。

                      • New options to influence image size, and skip default css rules.
                      • 新选项可影响图像大小,并跳过默认的CSS规则。

                      0.1

                      0.1

                        • Flickr or Zoomr feeds
                        • Flickr或Zoomr提要

                        • Displays thumbnails of images in the feed.
                        • 显示供稿中图像的缩略图。

                        • Background loading of images for visible thumbnails.
                        • 在后台加载可见缩略图的图像。

                        • Caches xsl translation of feed, with configurable refresh period.
                        • 使用可配置的刷新周期来缓存feed的xsl翻译。

                        • Customisable look&feel via CSS.
                        • 可通过CSS自定义外观。

                        Plans

                        计划

                        Before we reach 0.5

                        在达到0.5之前

                          • auto filters to select a preset when source matches particular regex.
                          • 当源与特定正则表达式匹配时,自动过滤以选择预设。

                          • show image title somewhere
                          • 在某处显示图片标题

                          • Event handler to allow changing slides with left and right arrow keys.
                          • 事件处理程序,允许使用左右箭头键更改幻灯片。

                          • Optionally display position in sequence and/or total images.
                          • (可选)按顺序和/或总图像显示位置。

                          After 0.5

                          0.5之后

                            • set up inlinerss settings like XSLT path automatically
                            • 自动设置内联设置,例如XSLT路径

                            • warn if cache directory isn’t set up properly.
                            • 警告如果缓存目录设置不正确。

                            • abstraction of the back end so we don’t rely on DGE_InlineRSS calls.
                            • 抽象了后端,因此我们不依赖DGE_InlineRSS调用。

                            • auto generation of slideshow id
                            • 自动生成幻灯片ID

                            • Next/previous 5 or some sort of paging
                            • 下一个/上一个5个或某些分页

                            • Optionally use flickr or zooomr api for speed
                            • 可以选择使用flickr或zooomr api来提高速度

                            • Fading transitions
                            • 渐变过渡

                            • Pull multiple feeds into one slideshow
                            • 将多个供稿放入一个幻灯片中

安装步骤

    1. Install and activate at least version 0.93 of

    2. 安装并激活至少0.93的版本

      DGE_InlineRSS.

    3. DGE_InlineRSS

    4. Make sure inlinerss’ cache directory is set up properly.

    5. 确保inlinerss的缓存目录设置正确。

      This

      这个

      plugin uses its settings.

    6. 插件使用其设置。

    7. Add wp-content/plugins to the inlinerss XSLT path

    8. wp-content / plugins 添加到线性 XSLT路径

      setting.

      设置。

      This plugin’s xslt won’t be found otherwise.

    9. 否则将找不到此插件的xslt。

    10. Upload this plugin to the /wp-content/plugins/, making sure it

    11. 将此插件上传到 / wp-content / plugins / 中,并确保它

      is all contained within a sub-folder called dge-slideshow.

    12. 全部包含在名为 dge-slideshow 的子文件夹中。

    13. Activate the plugin from your wordpress admin menu.
    14. 从您的wordpress管理菜单中激活插件。

    15. See the usage instructions below for how to actually get a

    16. 有关如何实际获取商品的信息,请参见下面的使用说明

      slideshow up and running.

    17. 幻灯片放映并运行。

下载地址
https://downloads.wordpress.org/plugin/dge-slideshow.0.4.zip
-EOF-

AI助手支持GPT4.0