nginx で SSL 設定をするのは、スゴイ簡単です。 サーバ証明書と秘密鍵がすでにあるなら、/etc/nginx/nginx.conf に以下の設定を追加するだけでおっけ。 server { : listen 443 default ssl; ssl on; # サーバ証明書(サーバ証明書に中間CA証明書を連結したもの) ssl_certificate /usr/local/nginx/conf/cert.pem; # 秘密鍵 ssl_certificate_key /usr/local/nginx/conf/cert.key; : } via. HttpSslModule サーバ証明書を持ってなくて、とりあえずオレオレ証明書を作成したい場合は以下のようにして作りましょう。 $ cd /usr/local/nginx/conf $ openssl genrsa -des3 -out s
「いますぐ実践! Linux システム管理」はこちらです。 メルマガの解除、バックナンバーなども、以下からどうぞ。 https://www.usupi.org/sysad/ (まぐまぐ ID:149633) その他、作者に関するページは、概ね以下にございます。 https://www.usupi.org/kuri/ (まぐまぐ ID:126454) http://usupi.seesaa.net/ (栗日記ブログ) https://twitter.com/kuriking/ (twitter) https://facebook.com/kuriking3 (facebook) https://jp.pinterest.com/kuriking/pinterest) https://www.instagram.com/kuri_king_/ (instagram) [バックナンバーのトップへ
「いますぐ実践! Linux システム管理」はこちらです。 メルマガの解除、バックナンバーなども、以下からどうぞ。 https://www.usupi.org/sysad/ (まぐまぐ ID:149633) その他、作者に関するページは、概ね以下にございます。 https://www.usupi.org/kuri/ (まぐまぐ ID:126454) http://usupi.seesaa.net/ (栗日記ブログ) https://twitter.com/kuriking/ (twitter) https://facebook.com/kuriking3 (facebook) https://jp.pinterest.com/kuriking/pinterest) https://www.instagram.com/kuri_king_/ (instagram) [バックナンバーのトップへ
「text-indent:-9999px;」や「display:none;」でテキストをウィンドウ外に飛ばしたり非表示にして、代わりに背景画像を表示させる手法を「画像置換(Image Replacement)」というが、これには重大な欠陥があって、最近では使用が推奨されていない。 h5{ width:150px; height:50px; background:url('ir_test.gif') no-repeat; text-indent:-9999px; } <h5>SITE TITLE</h5> h5{ width:150px; height:50px; background:url('ir_test.gif') no-repeat; } h5 span{ display:none; } <h5><span>SITE TITLE</span></h5> 上記のようなCSSだと「CS
画像をロードする時のロード画面ってなにげに分からないなーと思い調べてメモ。 基本的な流れとして下記のようにしてみた。 読み込む画像のURL ローディング画像を最初は透明にしておいてフェードインさせる jQueryでimg要素を作成して初期は透明にしてattr()でsrc属性で読み込む 画像を表示させるところにappendメソッドで追加する loadメソッドで読みこんだ後の処理として、ローディング画像をfadeOutさせてその後に、img要素をfadeInさせる ということで下記に一気にメモっとく $(document).ready(function(){ //初期設定 var url="images/1.jpg"; loadimg(); /* 画像読み込み関数 ----------------------------------*/ function loadimg(){ $("div#l
Also see Rails 3 Remote Links and Forms Part 2: Data-type (with jQuery). Spoiler Alert: If you like magic, stop reading. The Rails 3 UJS driver (rails.js), which powers the remote links, forms, and inputs, is not very magical when you know how it works. This article uses the jQuery UJS driver, though the Prototype UJS driver does the same thing. UJS, by the way, stands for "Unobtrusive JavaScript"
The following is an aimless journey through a degenerate form of Ruby, in an effort to learn a bit more about functional programming, simplicity, and API design. Suppose that the only way we have to organize code in Ruby is to make lambdas, and the only way we have to structure data are arrays: square = ->(x) { x * x } square.(4) # => 16 person = ["Dave",:male] print_person = ->((name,gender)) { p
Rubyには大量のメソッドがあります。次のコードでRuby1.9.3に含まれるメソッド数を数えたら単純合計で1659個、ユニーク数(同名を1と数えて)で937個と出力されました。 all_methods = ObjectSpace.each_object(Module).flat_map do |c| c.methods(false) + c.instance_methods(false) end.reject { |m| "#{m}".start_with? '_deprecated' } all_methods.size # => 1659 methods = all_methods.uniq methods.size # => 937 つまりRubyには、937個もの異なる名前のメソッドがあるのです。各メソッド名は、その動作や機能を端的に表現したものでなければならないので、その一つ一
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く