承接 timvermaercke/craft-whitepapers 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

timvermaercke/craft-whitepapers

最新稳定版本:1.0.0

Composer 安装命令:

composer require timvermaercke/craft-whitepapers

包简介

Let users download whitepapers (or any other secure file) after they drop their email address

README 文档

README

Let your users download whitepapers (or other files), but not before leaving their email address.

The plugin also provides a Field Type, to link a whitepaper to an entry and it provides CSV exports per whitepaper as well!

Screenshots

Frontend (example implementation)

Code Example implementation

The above is an example of an implementation of this plugin

Admin

Overview

Admin Overview

Detail

Admin Detail

Requirements

This plugin requires Craft CMS 4.0.0 or later

Installation

To install the plugin, follow these instructions.

  1. Open your terminal and go to your Craft project:

     cd /path/to/project
    
  2. Then tell Composer to load the plugin:

     composer require timvermaercke/craft-whitepaper
    
  3. In the Control Panel, go to Settings → Plugins and click the “Install” button for Test.

Brought to you by Tim Vermaercke

How to use

Create a Whitepaper object in /admin/whitepapers first.

Then you can add the following snippet to your templates:

<form action="/actions/whitepapers/public/download-whitepaper" method="post">
    {{ csrfInput() }}
    {{ hiddenInput('whitepaperId', 1) }}

    <label for="email">Email</label>
    <input type="email" id="email" name="email" />

    <input type="submit" value="Download" />
</form>

You can also create a field in Craft and use the custom field "Whitepaper", eg. in a Globals Set:

Create a field:

Settings - create a field

Create a globals set

Settings - create a globals set

Fill out the globals set:

Globals

Use the value in your templates:

{# will output the selected whitepaper id #}
{{ settings.fieldWhitepaper }}

统计信息

  • 总下载量: 2
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 3
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2022-07-20

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固