2014-01-01から1年間の記事一覧
PHPにはDirectoryIteratorという便利な方法があるっぽい。 $path = dirname(__FILE__); $dir = new DirectoryIterator($path); foreach ($dir as $file) { $file = mb_convert_encoding($file, "UTF-8", "auto"); echo $file . "<br>"; } だがこれだと「.」と「.…
getID3ってのを使えばできる。 インストール ubuntu最高や sudo apt-get install php-getid3 これで/usr/share/php-getid3にインストールされる。 サンプル analyze($filename); getid3_lib::CopyTagsToComments($fileInfo); …
PHPに一切頼らずJavascriptのみでもできるんだね。。。 必要なもの jquery.js(今回は2.1.0) https://oauth.googlecode.com/svn/code/javascript/sha1.js https://oauth.googlecode.com/svn/code/javascript/oauth.js var options = { method: "GET", apiURL:…
ChromeでGithubのJavascriptファイルのURLを直接書いて実行させようとしたらエラー Refused to execute script from 'https://raw.github.com/path/to/js.js' because its MIME type ('text/plain') is not executable, and strict MIME type checking is en…
@echo off echo Windows8.1専用 私的チューニングを行います pause sc config WSearch start= disabled :Windows Error Reporting Service sc config WerSvc start= disabled sc config Themes start= disabled :Security Center sc config wscsvc start= di…
home.html <section aria-label="Main content" role="main"> <div id="sampleListTemplate" data-win-control="WinJS.Binding.Template"> <div class="name-box"> 氏名:<span data-win-bind="textContent: name"></span> 年齢:<span data-win-bind="textContent: age"></span> </div> </div> </section>
前提 プロジェクトの新規作成で「ナビゲーションアプリケーション」を選択 ボタンをクリックして~を実現したい場合 home.html <body> <div class="fragment homepage"> <header aria-label="Header content" role="banner"> <button data-win-control="WinJS.UI.BackButton"></button> <h1 class="titlearea win-type-ellipsis"> </h1></header></div></body>
例えば「book」って投げたら「books」で返したり、「box」で投げたら「boxes」で返ってくるようなメソッド。 そもそも複数形の命名規則って? ここが一番手こずった。今まで感覚でやってたしググっても上位のサイトが結構間違ってる。 基本的には語尾に -s …
ServersMan@VPSを申し込んでしまった。プランは一番安いEntryコースってやつ。月額490円。さて、早速セットアップしますか 最初はrootでログインできる。パスワードはメールに記載されてる。 rootのパスワード変更 passwd 新しいユーザーを作成 sudo adduser…
MVCモデルの概念を漫画で解説してみる | hijiriworld Web やはりお前らのMVCは間違っている PHPerのMVCの一体どこが間違っていたのか - MugeSoの日記 RedLine Magazine : PHP宿題 MVC の勉強 RedLine Magazine : PHP修行 MVC復習/改善の巻 コントローラが肥…
別名、秘密の設定とも呼ばれているツイッターするやつのもう一つの顔である「隠し機能」。 com.suruyatu2.Activity.setting.HiddePreference まぁ秘密なんだから仕方ないね。
目的 mp3垂れ流しで聴きたい 環境・使うアプリケーション Ubuntu Server 14.04 Icecast 2.3.3(ストリーミングサーバー) IceS 0.4(Icecastに曲を送り続ける) IceSの最新版は2.0.2だがライセンス上の問題でmp3を扱えないようなので旧バージョンを使う。 Icec…
ffmpegとかlame扱うときによく起こる現象 error while loading shared libraries: libmp3lame.so.0: cannot open shared object file: No such file or directory 原因はlibmp3lame.so.0の場所。「/usr/lib/libmp3lame.so.0」ではなく「/usr/local/lib/libmp…
HDDの状態を教えてくれる有名なCrystalDiskInfo。ふと外付けHDDってどの位稼働してるんだろうと気になって見てみたらなんと、 「注意」 (つд⊂)ゴシゴシ 「注意」 ( ゚д゚) RAW値曰くまだ1なので大丈夫そうですが、確実に死に近づいているのは事実。 CrystalDisk…
必要最低限、これだけ覚えておけば・・・!ったやつだけ載せてる。そんな全部書いたとこで使わなきゃ意味ないんだしさ。 見出し 行頭で「#」+半角スペース。HTMLでいう<h>タグに相当。H6まで可。 # ほげほげ ## ほげほげ ### ほげほげ ほげほげ ほげほげ ほげ</h>…
毎回忘れるんだよね、頻繁に使ってないからか バックアップ mysqldump -u root -p -x --all-databases --default-character-set=binary > hoge.dat インポート mysql -u root -p --default-character-set=binary < hoge.dat
@echo off start wmplayer.exe /play "http://itori.animenfo.com:443/"マイクロソフト公式サイトによるとWMPには以下の様な起動オプションがあるとのこと。 /open : ファイルを開きますが、自動的に再生しません。 /play : プレーヤーの起動直後にファイル…
前々から作らなきゃ・・・とは思っていた。CDブートの時代は終わりだぜ!!! 特にUSBブートによるWindowsPEの起動はやったことなかったし。今回ぶち込んだOSは以下 Windows PE(Macrium Reflectリカバリ専用) Puppy Linux4.3.1日本語版 Lubuntu 13.10 GParte…