Title: Ashtabula
Author: mark l chaves
Published: <strong>2020 年 8 月 22 日</strong>
Last modified: 2022 年 12 月 18 日

---

搜索插件

![](https://ps.w.org/ashtabula/assets/banner-772x250.jpg?rev=2367113)

**该插件尚未通过WordPress的最新3个主要版本进行测试**。 当与较新版本的WordPress一起
使用时，可能不再受到维护或支持，并且可能会存在兼容性问题。

![](https://ps.w.org/ashtabula/assets/icon-256x256.png?rev=2367113)

# Ashtabula

 作者：[mark l chaves](https://profiles.wordpress.org/mlchaves/)

[下载](https://downloads.wordpress.org/plugin/ashtabula.1.0.0.zip)

 * [详情](https://cn.wordpress.org/plugins/ashtabula/#description)
 * [评价](https://cn.wordpress.org/plugins/ashtabula/#reviews)
 *  [安装](https://cn.wordpress.org/plugins/ashtabula/#installation)
 * [开发进展](https://cn.wordpress.org/plugins/ashtabula/#developers)

 [支持](https://wordpress.org/support/plugin/ashtabula/)

## 描述

This plugin allows you to use of the popular [Swiper.js](https://swiperjs.com/) 
library in WordPress.

This is a minimalist plugin that is for displaying responsive cards in a slide.

 * On a large screen device, the slide will show a horizontal card (image on the
   left and text on the right).
 * On a small device, the slide becomes a stacked card with the image on the top
   and text on the bottom.

See the screengrabs below to get a visual or visit the [live demo](https://streetphotography.blog/ashtabula-swiper-slider/).

**Note**: You should be comfortable with HTML and CSS to use this plugin.

### Usage

 1. Use the [demo HTML file](https://github.com/marklchaves/ashtabula/blob/master/ashtabula-demo.html)
    as a starter template. Add this HTML to a HTML or code block/element to your page
    or post.
 2. To add the images, use the example CSS below as a template. Add the CSS to your**
    Appearance** > **Customize** > **Additional CSS** or your child theme’s `style.
    css` file.

CSS example to specify the background image for the responsive card in a slide.

    ```
    /**
     * Swiper Slider Plugin Custom Styles
     */

    #my-swiper-slide-1 {
     background-image: url(mybgimg-1.png);
    }
    #my-swiper-slide-2 {
     background-image: url(mybgimg-2.png);
    }
    #my-swiper-slide-3 {
     background-image: url(mybgimg-3.png);
    }
    ```

### Credits

Powered by [Swiper.js](https://swiperjs.com/).

## 屏幕截图

 * [[
 * Example slider card on large devices.
 * [[
 * Example slider card on small devices.

## 安装

 1. Upload the contents of plugin zip file to the `/wp-content/plugins/ashtabula` directory,
    or install the plugin through the WordPress plugins page directly.
 2. Activate the plugin through the ‘Plugins’ page.

## 常见问题

### How can I change the Swiper.js settings?

You can override the `ashtabula.js` file. Here’s an example.

Add this to your child theme’s functions.php file.

    ```
    /** Override Swiper Slider Plugin JS */
    function override_ssp_js()
    {
        wp_dequeue_script('ashtabula');
        wp_enqueue_script('swiper-slider-custom-js', get_stylesheet_directory_uri().'/js/swiper-slider-custom.js', '', '1.0.0', true);
    }
    add_action('wp_enqueue_scripts', 'override_ssp_js', 100);
    ```

Create this file: `/js/swiper-slider-custom.js`. Add this code to the file. It will
override the default plugin settings for Swiper.js.

    ```
    /**
     * Make the slides:
     * 1. Slide up instead of 
     * to the right.
     * 2. Loop instead of rewind.
     * 3. Speed up to 3 seconds.
     */
    (function () {
      let swiper = new Swiper(".swiper-container", {
        autoplay: {
          delay: 3000,
        },
        direction: "vertical",
        loop: true,
      });
    })();
    ```

## 评价

此插件暂无评价。

## 贡献者及开发者

「Ashtabula」是开源软件。 以下人员对此插件做出了贡献。

贡献者

 *   [ mark l chaves ](https://profiles.wordpress.org/mlchaves/)

[帮助将「Ashtabula」翻译成简体中文。](https://translate.wordpress.org/projects/wp-plugins/ashtabula)

### 对开发感兴趣吗?

您可以[浏览代码](https://plugins.trac.wordpress.org/browser/ashtabula/)，查看[SVN仓库](https://plugins.svn.wordpress.org/ashtabula/)，
或通过[RSS](https://plugins.trac.wordpress.org/log/ashtabula/?limit=100&mode=stop_on_copy&format=rss)
订阅[开发日志](https://plugins.trac.wordpress.org/log/ashtabula/)。

## 更新日志

#### 1.0.0

 * First release. Tested on the Twenty Twenty and GeneratePress themes.

## 额外信息

 *  版本 **1.0.0**
 *  最后更新：**3 年前**
 *  活跃安装数量 **不到10**
 *  WordPress 版本 ** 5.3.2 或更高版本 **
 *  已测试的最高版本为 **6.1.10**
 *  PHP 版本 ** 7.2 或更高版本 **
 *  语言
 * [English (US)](https://wordpress.org/plugins/ashtabula/)
 * 标签
 * [responsive](https://cn.wordpress.org/plugins/tags/responsive/)[slider](https://cn.wordpress.org/plugins/tags/slider/)
   [swiper](https://cn.wordpress.org/plugins/tags/swiper/)
 *  [高级视图](https://cn.wordpress.org/plugins/ashtabula/advanced/)

## 评级

尚未提交反馈。

[Your review](https://wordpress.org/support/plugin/ashtabula/reviews/#new-post)

[查看全部评论](https://wordpress.org/support/plugin/ashtabula/reviews/)

## 贡献者

 *   [ mark l chaves ](https://profiles.wordpress.org/mlchaves/)

## 支持

有话要说吗？是否需要帮助？

 [查看支持论坛](https://wordpress.org/support/plugin/ashtabula/)

## 捐助

您愿意支持这个插件的发展吗?

 [ 捐助此插件 ](https://ko-fi.com/marklchaves)