サンプルはこちら→ http://srz-zumix.github.io/slide/kancolle/#/
css は github から取得できます。ご自由にお使い下さい。
https://github.com/srz-zumix/slide
https://github.com/srz-zumix/slide/tree/gh-pages/reveal.js/css/theme/kancolle.css
1 |
<!-- .element: class="fragment" --> |
1 |
<!-- .element: class="sample" --> |
1 |
<!-- .element: style="font-color: red;" --> |
1 2 3 4 5 6 |
<?xml version="1.0" encoding="UTF-8"?> <Response> <Gather timeout="10" finishOnKey="*"> <Say>Please enter your pin number and then press star.</Say> </Gather> </Response> |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
<?php require 'twilio-php/Services/Twilio.php' ; $response = new Services_Twilio_Twiml(); if ( isset( $_REQUEST [ 'Digits' ]) ) { $input = $_REQUEST [ 'Digits' ]; switch ( $input ) { case '9' : $response ->say( 'さようなら' , array ( 'language' => 'ja-jp' )); break ; default : $gather = $response ->gather( array ( 'numDigits' => 1, 'timeout' => '10' )); $gather ->say( $input . 'を押したな' , array ( 'language' => 'ja-jp' )); break ; } } else { $gather = $response ->gather( array ( 'numDigits' => 1, 'timeout' => '10' )); $gather ->say( 'なんかボタン押して。' , array ( 'language' => 'ja-jp' )); } print $response ; |
require 'twilio-php/Services/Twilio.php';こちらのファイルは、Twilio のライブラリーです。本家サイトよりダウンロードしたものを、アップロードしています。
if( isset($_REQUEST['Digits']) ) { ... } else { // ここ }そこで、Gather が処理され Digits パラメータ付きで同じ URLが叩かれます。
VisualStudio - AppVeyorでVisual C++プロジェクトのCI環境 - Qiita