70 lines
4.1 KiB
Markdown
70 lines
4.1 KiB
Markdown
---
|
|
title: WiLiKi で youtube 動画を表示するマクロ
|
|
author: kazu634
|
|
date: 2010-04-25
|
|
url: /2010/04/25/_1518/
|
|
wordtwit_post_info:
|
|
- 'O:8:"stdClass":13:{s:6:"manual";b:0;s:11:"tweet_times";i:1;s:5:"delay";i:0;s:7:"enabled";i:1;s:10:"separation";s:2:"60";s:7:"version";s:3:"3.7";s:14:"tweet_template";b:0;s:6:"status";i:2;s:6:"result";a:0:{}s:13:"tweet_counter";i:2;s:13:"tweet_log_ids";a:1:{i:0;i:5239;}s:9:"hash_tags";a:0:{}s:8:"accounts";a:1:{i:0;s:7:"kazu634";}}'
|
|
categories:
|
|
- gauche
|
|
|
|
---
|
|
<div class="section">
|
|
<p>
|
|
作成しました。簡単にできちゃった。
|
|
</p>
|
|
|
|
<h4>
|
|
ソース
|
|
</h4>
|
|
|
|
<pre class="syntax-highlight">
|
|
<span class="synComment">;; youtube module</span>
|
|
<span class="synComment">;; [[$$youtube id]]</span>
|
|
<span class="synSpecial">(</span>select-module wiliki.macro<span class="synSpecial">)</span>
|
|
<span class="synSpecial">(</span>use wiliki<span class="synSpecial">)</span>
|
|
<span class="synSpecial">(</span>use wiliki.macro<span class="synSpecial">)</span>
|
|
<span class="synSpecial">(</span>define-reader-macro <span class="synSpecial">(</span>youtube id<span class="synSpecial">)</span>
|
|
<span class="synPreProc">`(</span><span class="synSpecial">(</span>center
|
|
<span class="synSpecial">(</span>object
|
|
<span class="synSpecial">(</span>@
|
|
<span class="synSpecial">(</span>width <span class="synConstant">"660"</span><span class="synSpecial">)</span>
|
|
<span class="synSpecial">(</span>height <span class="synConstant">"525"</span><span class="synSpecial">))</span>
|
|
<span class="synSpecial">(</span>param
|
|
<span class="synSpecial">(</span>@
|
|
<span class="synSpecial">(</span>name <span class="synConstant">"movie"</span><span class="synSpecial">)</span>
|
|
<span class="synSpecial">(</span>value
|
|
,<span class="synSpecial">(</span>string-append
|
|
<span class="synConstant">"http://www.youtube.com/v/"</span>
|
|
id
|
|
<span class="synConstant">"&hl=ja_JP&fs=1&rel=0&border=1"</span><span class="synSpecial">))))</span>
|
|
<span class="synSpecial">(</span>param
|
|
<span class="synSpecial">(</span>@
|
|
<span class="synSpecial">(</span>name <span class="synConstant">"allowFullScreen"</span><span class="synSpecial">)</span>
|
|
<span class="synSpecial">(</span>value <span class="synConstant">"true"</span><span class="synSpecial">)))</span>
|
|
<span class="synSpecial">(</span>param
|
|
<span class="synSpecial">(</span>@
|
|
<span class="synSpecial">(</span>name <span class="synConstant">"allowscriptaccess"</span><span class="synSpecial">)</span>
|
|
<span class="synSpecial">(</span>value <span class="synConstant">"always"</span><span class="synSpecial">)))</span>
|
|
<span class="synSpecial">(</span>embed
|
|
<span class="synSpecial">(</span>@
|
|
<span class="synSpecial">(</span>src
|
|
,<span class="synSpecial">(</span>string-append
|
|
<span class="synConstant">"http://www.youtube.com/v/"</span>
|
|
id
|
|
<span class="synConstant">"&hl=ja_JP&fs=1&rel=0&border=1"</span><span class="synSpecial">))</span>
|
|
<span class="synSpecial">(</span><span class="synStatement">type</span> <span class="synConstant">"application/x-shockwave-flash"</span><span class="synSpecial">)</span>
|
|
<span class="synSpecial">(</span>allowscriptaccess <span class="synConstant">"always"</span><span class="synSpecial">)</span>
|
|
<span class="synSpecial">(</span>allowfullscreen <span class="synConstant">"true"</span><span class="synSpecial">)</span>
|
|
<span class="synSpecial">(</span>width <span class="synConstant">"660"</span><span class="synSpecial">)</span>
|
|
<span class="synSpecial">(</span>height <span class="synConstant">"525"</span><span class="synSpecial">)))))</span><span class="synPreProc">)</span><span class="synSpecial">)</span>
|
|
</pre>
|
|
|
|
<h4>
|
|
実行例
|
|
</h4>
|
|
|
|
<p>
|
|
「<a href="http://simoom634.sakura.ne.jp/wiliki/wiliki.cgi?WiLiKi%3aYoutube%E3%83%9E%E3%82%AF%E3%83%AD" onclick="__gaTracker('send', 'event', 'outbound-article', 'http://simoom634.sakura.ne.jp/wiliki/wiliki.cgi?WiLiKi%3aYoutube%E3%83%9E%E3%82%AF%E3%83%AD', 'no title');" target="_blank">no title</a>」をご覧ください。
|
|
</p>
|
|
</div> |