<?xml version="1.0" encoding="utf-8" ?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
<channel>
<title>YOUのブログ</title>
<link>https://ameblo.jp/sushimachine/</link>
<atom:link href="https://rssblog.ameba.jp/sushimachine/rss20.xml" rel="self" type="application/rss+xml" />
<atom:link rel="hub" href="http://pubsubhubbub.appspot.com" />
<description>料理・健康・仕事を中心にどうでもいいことを垂れ流す日記です。</description>
<language>ja</language>
<item>
<title>awkで一行目が無視される。</title>
<description>
<![CDATA[ awkで1列目だけ出す処理。<br>1行目だけ整形されずに出てきた。なんで？<br><br>悪）awk '{FS=","} {print $1}' INFILENAME &gt; OUTFILENAME<br><br>と思ったら、BEGIN句を書いたら解消した。<br><br>良）awk 'BEGIN {FS=","} {print $1}' INFILENAME &gt; OUTFILENAME<br><br>まぁどっちにしても何で1行目が無視されたか分からんので、<br>知っている方いたらコメントください。<br>
]]>
</description>
<link>https://ameblo.jp/sushimachine/entry-10940633958.html</link>
<pubDate>Fri, 01 Jul 2011 23:50:18 +0900</pubDate>
</item>
<item>
<title>シェルスクリプト内の変数をawkで使用する。</title>
<description>
<![CDATA[ 一回''の外に出してあげるんだって。<br><br>例）awk ' BEGIN {FS=","} if($1==' $HENSU ')print $0}' $INFILENAME &gt; $OUTFILENAME<br><br>つーかawkってコマンドじゃなくてプログラミング言語なんだってね。<br>
]]>
</description>
<link>https://ameblo.jp/sushimachine/entry-10940627196.html</link>
<pubDate>Fri, 01 Jul 2011 23:44:33 +0900</pubDate>
</item>
<item>
<title>[CAKEPHP]コントロールからDBにUPDATE</title>
<description>
<![CDATA[ やっとコントロールからDBにUPDATEができた。<br><br><br>  function vote($id = null) {<br>    if (!$id) {<br>      $this-&gt;flash(sprintf(__('Invalid member', true)), array('action' =&gt; 'index'));<br>    }<br><br>    $data=$this-&gt;Member-&gt;findById( $id );<br>    if ($this-&gt;Member-&gt;saveField('votepoint' , ( $data["Member"]["votepoint"]+1 ))) {<br>      $this-&gt;flash(__('Member voted', true), array('action' =&gt; 'index'));<br>    }<br>    $this-&gt;flash(__('Member was not voted', true), array('action' =&gt; 'index'));<br>    $this-&gt;redirect(array('action' =&gt; 'index'));<br>  }<br><br>○IDをキーにデータを1件検索<br>$data=$this-&gt;Member-&gt;findById( $id );<br><br>○フィールドを指定してデータをUPDATE<br>if ($this-&gt;Member-&gt;saveField('votepoint' , ( $data["Member"]["votepoint"]+1 ))) {<br><br>いじょ
]]>
</description>
<link>https://ameblo.jp/sushimachine/entry-10904185505.html</link>
<pubDate>Fri, 27 May 2011 00:05:45 +0900</pubDate>
</item>
<item>
<title>[javascript]form action=&quot;#&quot;</title>
<description>
<![CDATA[ javascriptを１から勉強してみよう月間。<br><br>イベントハンドラによく書かれている<br><br>form action="#"について<br><br><a href="http://oshiete.goo.ne.jp/qa/1195603.html" target="_blank"></a><br><br>action書かなきゃいけないルールのようなので、仕方なく書くけど、<br>ほかのページに飛ばないようにしてるってことですね。<br><br>
]]>
</description>
<link>https://ameblo.jp/sushimachine/entry-10871573326.html</link>
<pubDate>Sun, 24 Apr 2011 23:36:33 +0900</pubDate>
</item>
<item>
<title>[CAKEPHP]リリース後いきなり動かない！</title>
<description>
<![CDATA[ 作成したサイトをサーバーにリリースしたところ、いきなり動かない。<br><br>原因と対策を備忘録的に。<br><br>①致命的なエラー<br>Fatal error: CakePHP core could not be found. Check the value of CAKE_CORE_INCLUDE_PATH in APP/webroot/index.php. It should point to the directory containing your /cake core directory and your /vendors root directory. in xxxxxxxxxxxxxxxxxxxxxxxxxx/mac/app/webroot/index.php on line 77<br><br>こんなん出た。CakePHPの大事なところが見えませんよ。<br>APP/webroot/index.php　の　CAKE_CORE_INCLUDE_PATH　を調べてね。とのこと。<br><br>原因<br>Windowsでbakeしたためこんなんなってた。<br>define('CAKE_CORE_INCLUDE_PATH', DS . 'home'. DS .'users'. DS .'x'. DS .'xxxxxxxxxxxxxx'. DS .'web'. DS .'mac' );<br><br><br>対策　こうやって解決！！<br>define('CAKE_CORE_INCLUDE_PATH', ROOT);<br><br><br>②Sqlite3が使えない！（no log）<br><br>原因<br>　デバッグ環境にはあるDBOファイルを格納し忘れていた。<br><br>対策　こうやって解決！！<br>mac\cake\libs\model\datasources\dbo\dbo_sqlite3.phpを格納。<br><br><br>これでとりあえず動き始めたヾ(＠^▽^＠)ﾉ
]]>
</description>
<link>https://ameblo.jp/sushimachine/entry-10868500049.html</link>
<pubDate>Thu, 21 Apr 2011 22:21:26 +0900</pubDate>
</item>
<item>
<title>[CAKEPHP]データのサニタイズを行う。</title>
<description>
<![CDATA[ サニタイズの方法 <br><br>CakePHPにはサニタイズ用のライブラリが用意されている。<br>利用するにはControllerのアクション内で<br>function xxxAction(){<br>    App::import('Sanitize');<br>    $text1 = $this-&gt;params['post']['text1'];<br>    $this-&gt;set("text1", Sanitize::stripAll($text1));<br>}<br>として利用する。<br><br>App::import('Sanitize');<br>でライブラリを読み込み、<br>Sanitize::stripAll($text1)<br>で値をサニタイズしている。<br><br>http://wiki.livedoor.jp/tech5963/d/%A5%B5%A5%CB%A5%BF%A5%A4%A5%BA<br><br>
]]>
</description>
<link>https://ameblo.jp/sushimachine/entry-10865882822.html</link>
<pubDate>Tue, 19 Apr 2011 02:14:31 +0900</pubDate>
</item>
<item>
<title>[jQuery]topupでyoutubeをポップアップする。</title>
<description>
<![CDATA[ なんだかよくわからないがサンプルの真似でムリくり動かした。<br>要調査だけど、情報少なすぎ、、、英語の勉強でもするかなぁ。<br><br>youtubeのURL<br>http://www.youtube.com/watch?v=9XTDLxcem1k&amp;feature=player_embedded<br><br>topupで動くURL<br>http://www.youtube.com/v/9XTDLxcem1k&amp;hl=nl&amp;fs=1&amp;rel=0&amp;hd=1&amp;autoplay=1<br><br>
]]>
</description>
<link>https://ameblo.jp/sushimachine/entry-10864311983.html</link>
<pubDate>Sun, 17 Apr 2011 16:28:00 +0900</pubDate>
</item>
<item>
<title>[sqlite 3]カラムを追加する。</title>
<description>
<![CDATA[ --2011/04/17 add start<br>--sqlite3 では、この操作は、“ALTER TABLE ... ADD COLUMN ...”という SQL で一発で操作できるようになりました。<br>--ただし、この SQL を実行したデータベースファイルは、VACUUM を実行するまで、3.1.3 以前のバージョンからそのデータベースファイルを<br>--読み込むことができないという問題があるので、ただちに VACUUM を実行しておいたほうがよいでしょう。<br><br>参考　→　http://www.dbonline.jp/sqlite/table/index2.html<br><br>SELECT * FROM SQLITE_MASTER where name = 'events';<br><br>BEGIN TRANSACTION;<br><br>ALTER TABLE events ADD COLUMN picture VARCHAR(255);<br>VACUUM;<br><br>SELECT * FROM SQLITE_MASTER where name = 'events';<br><br>COMMIT;<br><br>--2011/04/17 add delete<br><br><br>TRANSACTIONの宣言とかあることも初めて知ったし。<br>
]]>
</description>
<link>https://ameblo.jp/sushimachine/entry-10863989142.html</link>
<pubDate>Sun, 17 Apr 2011 09:12:25 +0900</pubDate>
</item>
<item>
<title>[CAKEPHP]ver1.2ではfindALL()が非推奨</title>
<description>
<![CDATA[ かわりにこう書く。<br>find('all',null,'Hoge.id DESC') ;<br>
]]>
</description>
<link>https://ameblo.jp/sushimachine/entry-10863838936.html</link>
<pubDate>Sun, 17 Apr 2011 01:06:06 +0900</pubDate>
</item>
<item>
<title>[CAKEPHP]他のテンプレートファイルを読み込む elements</title>
<description>
<![CDATA[ 他のテンプレートファイルを読み込む<br><br>配置先<br>/app/view/elements/hoge.ctp<br><br>viewで以下のように呼び出す。<br>echo \$this-&gt;element('hoge');
]]>
</description>
<link>https://ameblo.jp/sushimachine/entry-10862851862.html</link>
<pubDate>Sat, 16 Apr 2011 00:56:30 +0900</pubDate>
</item>
</channel>
</rss>
