承接 tjournal/newrphus 相关项目开发

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

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

tjournal/newrphus

最新稳定版本:0.3.0

Composer 安装命令:

composer require tjournal/newrphus

包简介

Newrphus — misprints reporting engine

README 文档

README

Let users send misprints from your website to Slack.

License Latest Stable Version

Library contains PHP back-end library and Javascript front-end file. You should use both of them to make misprint reporter works.

How it works

When user selects text on a page and presses Ctrl+Enter, the Newrphus sends POST request to url. You can also include userId parameter to track users. Right after the keypress event, it calls callback function, where you can tell user that report was sent.

How to use

  1. Create new Incoming webhook in Slack.

  2. Install PHP library with Composer.

  3. Create backend handler for JS Ajax call.

    $newrphus = new TJ\Newrphus();
    $reviewer->setSlackSettings([
        'endpoint' => 'https://hooks.slack.com/services/ABCDE/QWERTY',
        'channel' => '#misprints'
    ]);
    $reviewer->report($_POST['misprintText'], $_POST['misprintUrl']);

    If you want to customize Slack message, see example.php.

  4. Include js to the page, where you want to track misprints.

    <script src="js/newrphus.js"></script>
    <script>
      newrphus.init({
        url: 'example.php',
        userId: 12345,
        callback: function() {
          alert('Misprint sent');
        }
      });
    </script>
  5. Tell users to select text and press Ctrl+Enter to send report.

Installing via Composer

composer.phar require tjournal/newrphus

Then include Composer's autoloader:

require 'vendor/autoload.php';

统计信息

  • 总下载量: 47.34k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 15
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 15
  • Watchers: 3
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-06-09

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固