<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>ミヤビッチの穴</title>
	<atom:link href="http://hole.sugutsukaeru.jp/feed" rel="self" type="application/rss+xml" />
	<link>http://hole.sugutsukaeru.jp</link>
	<description>Perl, CGI, JavaScript - Perl プログラマの頭の中</description>
	<lastBuildDate>Tue, 15 May 2012 03:42:55 +0000</lastBuildDate>
	<language>ja</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>Facebook の facebookexternalhit が非公開URLにアクセスしているっぽい件</title>
		<link>http://hole.sugutsukaeru.jp/archives/215</link>
		<comments>http://hole.sugutsukaeru.jp/archives/215#comments</comments>
		<pubDate>Tue, 15 May 2012 03:37:59 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[解説]]></category>
		<category><![CDATA[facebook]]></category>

		<guid isPermaLink="false">http://hole.sugutsukaeru.jp/?p=215</guid>
		<description><![CDATA[今日（2012年5月15日）Webサーバログを見ていて気付いたが、Facebookのボット（？）facebookexternalhit が非公開URLにアクセスして来ている。 公開準備中の草稿ページに加え、および恐ろしいことに社内インターナルサイトのウェブアプリケーションのURLが含まれている。 このようなお行儀の悪い振る舞いは、2012年4月27日が最初。 以下のようにサイトには説明があるので、とりあえず質問メールを送ってみた。様子見。 Facebookサイトでの説明 サーバーのログにFacebookが記録されているのはなぜですか？ Facebookでは、ユーザーが他のユーザーに対して、面白いコンテンツを含んだリンクなどを送信することができます。Facebookでは一時的に特定の画像やリンク先を表示することによってホームページのタイトルや動画にタグされたものを表示できます。このシステムはユーザーがリンクを提供したときのみ情報を検索します。もしかしたら、他のユーザーがあなたのホームページからその他のユーザーにリンクを送ったからかもしれません。もし質問などがあればlegal@facebook.comまで連絡してください。 アクセスログ（一部伏字） 1.   69.171.224.6 - - [27/Apr/2012:21:56:09 +0900] "GET /cgi/xxxxxxx/edit.html?data_id=### HTTP/1.1" 401 1289 "-" "facebookexternalhit/1.1 (+http://www.facebook.com/externalhit_uatext.php)" 2.   66.220.146.245 - - [08/May/2012:14:55:00 +0900] "GET /support/276/ HTTP/1.1" 404 3753 "-" "facebookexternalhit/1.1 (+http://www.facebook.com/externalhit_uatext.php)" 3.   66.220.149.246 - &#8230; <a href="http://hole.sugutsukaeru.jp/archives/215">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
		<wfw:commentRss>http://hole.sugutsukaeru.jp/archives/215/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>.htaccess ファイルで mod_rewrite の設定をする時の注意点</title>
		<link>http://hole.sugutsukaeru.jp/archives/187</link>
		<comments>http://hole.sugutsukaeru.jp/archives/187#comments</comments>
		<pubDate>Mon, 16 Apr 2012 05:20:43 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[解説]]></category>
		<category><![CDATA[開発]]></category>
		<category><![CDATA[.htaccess]]></category>
		<category><![CDATA[Apache]]></category>
		<category><![CDATA[mod_rewrite]]></category>

		<guid isPermaLink="false">http://hole.sugutsukaeru.jp/?p=187</guid>
		<description><![CDATA[Apache の mod_rewrite の設定は、サーバの設定ファイル（httpd.conf）内で指定する場合と .htaccess ファイル（または &#60;Directory&#62;コンテキスト）で指定する場合で少し違う点がある。 先日 Yahoo 知恵袋で質問に回答した時に、設定ファイルを見ていただけでは気づかず、検証せずに回答して失敗しました。ごめんなさい。 教えてもらった設定が動かないとか、いつもやっている筈の書き方がどうもうまく行かないという場合は、これらの違いにハマっている可能性があります。 書き換え処理が繰り返される .htaccess ファイルでURLの書き換えを行うと、１回一連の書き換えが終わった後、もう一度書き換え設定を上から順に適用し、書き換えの必要がないかをチェックする。書き換える必要が無くなるか、またはループしすぎてエラーになるまでこれが続く。 これは、[L] フラグを指定しても、外部へのリダイレクト、つまり [R] フラグと一緒に指定していない限り起こる。 Apache ドキュメントのフラグの設定のところにその説明がある。要点としては、.htaccess で指定した場合処理が繰り返されるから、適当に RewriteCond などで条件を入れるように注意してね、という事。 If you are using RewriteRule in either .htaccess files or in &#60;Directory&#62; sections, it is important to &#8230; <a href="http://hole.sugutsukaeru.jp/archives/187">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
		<wfw:commentRss>http://hole.sugutsukaeru.jp/archives/187/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>PostgreSQL のクエリーパフォーマンスが where 条件内に副問合せ or 関数を直接指定で劇的に違う件</title>
		<link>http://hole.sugutsukaeru.jp/archives/177</link>
		<comments>http://hole.sugutsukaeru.jp/archives/177#comments</comments>
		<pubDate>Tue, 27 Mar 2012 06:25:13 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[開発]]></category>
		<category><![CDATA[PostgreSQL]]></category>

		<guid isPermaLink="false">http://hole.sugutsukaeru.jp/?p=177</guid>
		<description><![CDATA[PostgreSQL 8.4 で where 条件の指定を副問合せにするか関数の値を直接指定するかでパフォーマンスが劇的に違ったという話。 PostgreSQL 8.4 でまず複雑なSQLを一つの関数にまとめる。 create or replace function getid_func(text) RETURNS integer AS $PROC$ select id from table where (複雑な条件) order by id desc limit 1 ; $PROC$ LANGUAGE SQL ; 次に、この関数を使って、実際に値を取得する。 パターンA：副問合せ select * from table &#8230; <a href="http://hole.sugutsukaeru.jp/archives/177">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
		<wfw:commentRss>http://hole.sugutsukaeru.jp/archives/177/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>iPad/iPhone から画像/ファイルをアップロードする方法</title>
		<link>http://hole.sugutsukaeru.jp/archives/145</link>
		<comments>http://hole.sugutsukaeru.jp/archives/145#comments</comments>
		<pubDate>Mon, 12 Mar 2012 08:38:47 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[画像]]></category>
		<category><![CDATA[解説]]></category>
		<category><![CDATA[iPad]]></category>
		<category><![CDATA[iPhone]]></category>
		<category><![CDATA[アップロード]]></category>

		<guid isPermaLink="false">http://hole.sugutsukaeru.jp/?p=145</guid>
		<description><![CDATA[iPad/iPhone の場合、Webフォームに付けた &#60;input type=&#8221;file&#8221; /&#62; フィールドがグレーアウトされてしまってファイルアップロードができない。これは iOS の方針だとかで、デフォルトでインストールされている Safari の他、Opera や iLunascape、Sleipnir などでも同じ現象になる。 しばらく方法を探していて、画像なら PickUP というネイティブプラグインを使う方法がある事を見つけたのだが、 （日本語での参考記事：Picup を利用して Rails アプリに iPhone / iPad から画像をアップロードする） 画像以外に対応できない。 うっかり開発者のサーバにテストでアップすると画像が消せない。 という問題があり、特に2番の方は恐ろしくお客様などにはご紹介できないので、別の方法を探していた。 ら、ありました。 Special Thanks to ブログ記事：How To Fix iPhone/iPad Mobile Safari Greyed out and &#8230; <a href="http://hole.sugutsukaeru.jp/archives/145">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
		<wfw:commentRss>http://hole.sugutsukaeru.jp/archives/145/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>最近の CentOS の less で EUC-JP を表示させる</title>
		<link>http://hole.sugutsukaeru.jp/archives/131</link>
		<comments>http://hole.sugutsukaeru.jp/archives/131#comments</comments>
		<pubDate>Thu, 05 Jan 2012 02:27:21 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[開発]]></category>
		<category><![CDATA[CentOS]]></category>
		<category><![CDATA[less]]></category>
		<category><![CDATA[nkf]]></category>
		<category><![CDATA[文字コード]]></category>

		<guid isPermaLink="false">http://hole.sugutsukaeru.jp/?p=131</guid>
		<description><![CDATA[最近契約したレンタルサーバ（CentOS）のless（ページャ）は、文字コード指定 LESSCHARSET として utf-8 以外の日本語用マルチバイトエンコーディングを受け付けてくれないらしい。オウ。 私は老人であるので諸事情によりコンソールは EUC-JP になっている。変えてもいいけど色々面倒くさい。「yum search jless」しても出てこない。うーむ。としばらく悩んだが、以下のエイリアスで解決。 alias jless "nkf -e &#124; less" nkf すばらしい。]]></description>
		<wfw:commentRss>http://hole.sugutsukaeru.jp/archives/131/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Chrome の Error 324 (net::ERR_EMPTY_RESPONSE) について少し詳しく調べた【自サバでは解決追記】</title>
		<link>http://hole.sugutsukaeru.jp/archives/130</link>
		<comments>http://hole.sugutsukaeru.jp/archives/130#comments</comments>
		<pubDate>Sun, 18 Dec 2011 08:35:44 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[解説]]></category>
		<category><![CDATA[chrome]]></category>
		<category><![CDATA[cpx]]></category>
		<category><![CDATA[deflate]]></category>
		<category><![CDATA[ssl]]></category>

		<guid isPermaLink="false">http://hole.sugutsukaeru.jp/?p=130</guid>
		<description><![CDATA[自社サイト「すぐ使えるCGI」http://sugutsukaeru.jp/ では、Chrome でアクセスすると SSL（https）になった時に以下のエラーで表示ができなくなってしまう。 2011年の1月頃から発生し、サーバを引越ししてもクライアントマシンを変更してもやはり同じ問題が出る。お客さまからも問い合わせいただく。 データを受信していません サーバーからデータが送信されないためウェブページを読み込むことができません。 ヒント: このウェブページを後で読み込んでください。 エラー 324 (net::ERR_EMPTY_RESPONSE): サーバーはデータを送信せずに接続を切断しました。 Chrome がバージョンアップし「SSL False Start」という通信高速化技術の実装とともに起こったと思うのだが、詳細は不明。 英語のエラーメッセージ 「Error 324 (net::ERR_EMPTY_RESPONSE): The server closed the connection without sending any data.」で検索すると、2011年末になっても問題が発生している事が分かる。 サイトには以下のように案内しているのだが、どうもかなり機会ロスをしているようなので解決方法が無いか調べてみた。 サイトへの案内： Chrome をお使いの方へ【アクセスできない場合】 ちなみに、Chromeのバージョンアップにより上のページで紹介している設定の変更による問題回避はできなくなっている。 いくつか分かった事 SSL証明書の問題ではない 同じSSL証明書ファイルをほぼ同様の Apache 環境に入れてみるとテスト環境ではうまくいくので、今回の場合はSSL証明書やサーバのバージョンが問題では無い。 &#8230; <a href="http://hole.sugutsukaeru.jp/archives/130">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
		<wfw:commentRss>http://hole.sugutsukaeru.jp/archives/130/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>MySQL のダンプをローカルホストにファイルを作成せずに直接リモートホストに保存する</title>
		<link>http://hole.sugutsukaeru.jp/archives/129</link>
		<comments>http://hole.sugutsukaeru.jp/archives/129#comments</comments>
		<pubDate>Mon, 28 Nov 2011 11:04:13 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[管理ツール]]></category>
		<category><![CDATA[mysql]]></category>

		<guid isPermaLink="false">http://hole.sugutsukaeru.jp/?p=129</guid>
		<description><![CDATA[ホスト入替えなどの際に直接リモートホストにDBのダンプを書き出す方法。 リモートホストからローカルのDBに接続してダンプするという選択肢もありますが、ここではローカルユーザでDBに接続し、ダンプファイルを転送する方法を紹介しています。 予めssh用のキーファイルを設定しておき 「 ssh REMOTEUSERNAME@remote.host.name 」がパスワード入力無しでリモートホストにログインできるようにしておきます。 /usr/bin/mysqldump \ --opt DBNAME --user=UNAME --password=PASS \ &#124; gzip -c &#124; ssh REMOTEUSERNAME@remote.host.name "zcat &#62; /path/to/save/on/remotehost/dump.sql" 定期バックアップなどの際に、圧縮したまま保存する場合は以下のような感じで。 /usr/bin/mysqldump \ --opt DBNAME --user=UNAME --password=PASS \ &#124; gzip -c &#124; ssh REMOTEUSERNAME@remote.host.name "cat &#62; /path/to/save/dump.sql.gz"]]></description>
		<wfw:commentRss>http://hole.sugutsukaeru.jp/archives/129/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Windows 7 から LAN上の Samba 2.2.7 にアクセスできた件</title>
		<link>http://hole.sugutsukaeru.jp/archives/128</link>
		<comments>http://hole.sugutsukaeru.jp/archives/128#comments</comments>
		<pubDate>Thu, 15 Sep 2011 02:39:34 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[解説]]></category>
		<category><![CDATA[samba]]></category>
		<category><![CDATA[window7]]></category>

		<guid isPermaLink="false">http://hole.sugutsukaeru.jp/?p=128</guid>
		<description><![CDATA[Sambaのサイトによると「Windows 7 を Samba ドメインに参加させるためには、Sambaを3.3.5以降（もしくは3.2.12以降）にバージョンアップし、Windows 7 側のレジストリを以下のように設定する必要があります。」とのことだったのだが、バージョンアップしなくても設定変更でアクセスできた件。 （旧い Samba バージョンアップしろヨという話はひとまずおいておいて&#8230;。） ただし、いわゆる 「Windowsドメイン」 にログオンしているというわけではないのかも？ 必要だった変更 「ローカルポリシー」～「セキュリティオプション」～「ネットワークセキュリティ：LAN Manager認証レベル」の項目を「LM と NTLM 応答を送信する」に設定。 変更手順 Windows 7 のデフォルト左下のスタートメニュー をクリックすると一番下に現れる検索ボックスに「セキュリティ」と打ち込むと、検索結果として「ローカルセキュリティポリシー」というメニューが表示される。それをつつくと、設定画面に移動できる。 （Vista は無視していたら Windows7 変わりすぎていてかなり分からない&#8230;　ひー。） 参考にした情報 Windows7 + OpenVPN + Samba 設定メモ 感謝！ 「LAN Manager認証レベル」項目について Windows7 のヘルプによると、この項目の設定は以下の通り。 &#8230; <a href="http://hole.sugutsukaeru.jp/archives/128">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
		<wfw:commentRss>http://hole.sugutsukaeru.jp/archives/128/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Visualforce &lt;apex:tabPanel&gt; と ｊQuery との衝突の解消</title>
		<link>http://hole.sugutsukaeru.jp/archives/127</link>
		<comments>http://hole.sugutsukaeru.jp/archives/127#comments</comments>
		<pubDate>Sun, 14 Aug 2011 02:37:14 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[コードサンプル]]></category>
		<category><![CDATA[開発]]></category>
		<category><![CDATA[salesforce.com]]></category>
		<category><![CDATA[Visualforce]]></category>

		<guid isPermaLink="false">http://hole.sugutsukaeru.jp/?p=127</guid>
		<description><![CDATA[salesforce.com の Visualforce でタブ表示をする &#60;apex:tabPanel&#62; は、ｊQuery と相性が悪いようです。ｊQuery を読み込んでいるページで &#60;apex:tabPanel&#62; を使うと、タブの移動ができなくなります。 この問題は ｊQuery の衝突回避メソッドで解決できました。 &#60;apex:page&#62; &#60;apex:includeScript value="{!URLFOR($Resource.jquery, 'jquery_min.js')}"/&#62; &#60;script type="text/javascript"&#62; var j$ = jQuery.noConflict(); //残りのJSコードは $ の代わりに j$ の表記で書く &#60;/script&#62; &#60;apex:tabPanel switchType="client" selectedTab="name1" id="theTabPanel"&#62; &#60;apex:tab label="One" name="name1" id="tabOne"&#62;content for tab one&#60;/apex:tab&#62; &#8230; <a href="http://hole.sugutsukaeru.jp/archives/127">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
		<wfw:commentRss>http://hole.sugutsukaeru.jp/archives/127/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Perl から Google Translate API を使う</title>
		<link>http://hole.sugutsukaeru.jp/archives/126</link>
		<comments>http://hole.sugutsukaeru.jp/archives/126#comments</comments>
		<pubDate>Thu, 11 Aug 2011 04:53:35 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[コードサンプル]]></category>
		<category><![CDATA[開発]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[Perl]]></category>

		<guid isPermaLink="false">http://hole.sugutsukaeru.jp/?p=126</guid>
		<description><![CDATA[Google Labs の閉鎖により Google Translate API が 2011年12月から使えなくなってしまうという事なので、その前にとりあえず機械翻訳しておきたいものをがつがつ取るためにモジュール作成。 しかし課金を受けずに使うと、割とすぐに利用上限に達してしまう。おまけに1日の区切りがどこで付くのかが分からず翌日の昼を過ぎても上限がクリアされない&#8230;。ぽちぽちやろう。 参考リソース Google Translate API Developer&#8217;s Guide モジュール（パッケージ） ポイントは、そこそこの文章を翻訳する時はGETだと文字数オーバーしてしまうのでPOSTで送信することと、その際、GETとして扱ってくれという指示をする ｈｔｔｐ ヘッダ「X-HTTP-Method-Override」を送信する事。 package Google::Translate::Translator; use strict;use warnings; use utf8;use Encode qw(encode_utf8); use URI::Escape;use HTTP::Request;use LWP::UserAgent;use JSON; &#35;許可されたオプションour @Options = qw(targetkeysourcetranslator_urlformat); sub new {&#160;&#160;&#160;&#160;my &#8230; <a href="http://hole.sugutsukaeru.jp/archives/126">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
		<wfw:commentRss>http://hole.sugutsukaeru.jp/archives/126/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

