rails:2463
From: makoto kobori <kobori@c...>
Date: Sat, 24 Nov 2007 10:29:56 +0900
Subject: [rails:2463] Re: ¥Ð¥¤¥Ê¥ê¤Î²èÁü¥Ç¡¼¥¿¤ò HTML ¾å¤Ëɽ¼¨¤¹¤ëÊýË¡
¤³¤Ü¤ê¤Ç¤¹ ¤¢¤ê¤¬¤È¤¦¤´¤¶¤¤¤Þ¤¹¡£¤½¤á¤¨¤ÀÍÍ¡£ >¡¥¢¥Ã¥×¥í¡¼¥É²èÌ̤ǥ桼¥¶¤¬jpeg¤òupload¤¹¤ë¡£ >¢³Îǧ²èÌ̤ǥ¢¥Ã¥×¥í¡¼¥É¤µ¤ì¤¿²èÁü¤ò³Îǧ >££Ä£ÂÅÐÏ¿ ¢¤ÇFileIO¤òµ¤¤Ë¤·¤Æ¡¢²¾£Ä£ÂÅÐÏ¿¤ä¡¢¥Õ¥¡¥¤¥ëÊݸ¤ò¤ä¤á¤è¤¦¤È»×¤Ã¤Æ¤Þ¤·¤¿¤¬¡¢ session¤Ç¥Õ¥¡¥¤¥ë£É£Ï¤¬È¯À¸¤¹¤ë¤ó¤Ç¤¹¤Í¡£¤Ê¤é¤Ð¡¢ ²¾£Ä£ÂÅÐÏ¿¤·¤Æ¤â¡¢¤¢¤Þ¤êÊѤï¤é¤Ê¤¤¤«¤Ê¡¢¤È»×¤¤¤Þ¤·¤¿¡£ ¤½¤ì¤Ç¥È¥é¥Ö¥ë¤âÈò¤±¤é¤ì¤ë¤Ê¤é¤Ð¡¦¡¦ ¤¢¤ê¤¬¤È¤¦¤´¤¶¤¤¤Þ¤·¤¿¡£ someeda ¤µ¤ó¤Ï½ñ¤¤Þ¤·¤¿: > ¤½¤á¤¨¤À¡¢¤Ç¤¹¡£ > > > >> ¤³¤³¤Ç¼ÁÌä¤Ï¡¢²èÁü¤¬É½¼¨¤µ¤ì¤ë¤â¤Î¤Î¡¢session¤Ç >> Ãͤò°ú¤ÅϤ¹¤Î¤¬¡¢¶¯°ú¤Êµ¤¤¬¤·¤Æ¤Ê¤é¤Ê¤¤¤Î¤Ç¤¹¡£ >> ¤â¤¦¾¯¤·¥¹¥Þ¡¼¥È¤Ê¤ä¤êÊý¤Ï¤Ê¤¤¤â¤Î¤Ç¤·¤ç¤¦¤«¡£ >> > > Îɤ¯¸«¤ë¤Î¤Ï¥Õ¥¡¥¤¥ë¤È¤·¤Æ¥µ¡¼¥Ð¤ËÊݸ¤¹¤ë¤«¡¢DB¤ËÅÐÏ¿¤·¤Æ¤·¤Þ¤¦¤«¤Ç¤¹¡£ > Í×·ï¤Ë¤â¤è¤ê¤Þ¤¹¤¬²¿¤â¹Í¤¨¤Ê¤¤¤Ê¤é¡¢¤È¤ê¤¢¤¨¤ºDB¤«¤Ê¡© > > ¾®ËÙ¤µ¤ó¤ÎÍͤËsession¤Ë²èÁü¤òÆɤ߹þ¤à¤Î¤â¡¢¾ì¹ç¤Ë¤è¤Ã¤Æ¤Ï > °¤¯¤Ê¤¤¤«¤â¤·¤ì¤Þ¤»¤ó¡£ > ¤½¤Î¾ì¹çsession¤¬¤É¤³¤ËÊݸ¤µ¤ì¤ë¤Î¤«°Õ¼±¤·¤Æ¤«¤é·è¤á¤¿¤¤½ê¤Ç¤¹¡£ > > > >> session¤Ç¡¢@pic¤Þ¤ë¤´¤È»ØÄꤷ¤¿¤é¡¢ >> ¡ÖWe're sorry, but something went wrong.¡× >> ¤È½Ð¤Æ¤·¤Þ¤¤¤Þ¤·¤¿¡£¹½Â¤ÂΤÏsession¤ÇÅϤ»¤Ê¤¤¡© >> ¼ÂÂÖ¤Ïcookie¤À¤«¤éÅϤ»¤Ê¤¤¤È¤¤¤¦¤³¤È¤Ç¤·¤ç¤¦¤«¡£ >> > > @pic¤¬¥Õ¥¡¥¤¥ë¥ª¥Ö¥¸¥§¥¯¥È¤ò´Þ¤ó¤Ç¤¤¤ë¤«¤é¤Ç¤¹¡£ > session¤ÏRuby¤ÎMarshal.dump¤ò»È¤¦¤Î¤Ç¡¢Marshal.dump¤ÎÀ©¸Â¤Ë±Æ¶Á¤µ¤ì¤Þ¤¹¡£ > http://www.ruby-lang.org/ja/man/?cmd=view;name=Marshal > > ¤Ç¤¤¿¤é¥È¥é¥Ö¥ë¤òÈò¤±¤ë¤¿¤á¡¢Ã±½ã¤Êʸ»úÎó¤ä¿ôÃͰʳ°¤Ï > session¤Ë¤¤¤ì¤Ê¤¤Êý¤¬ÌµÆñ¤Ç¤·¤ç¤¦¤Í¡£ > > > cookie¤Ï¤É¤Îsession¥Ç¡¼¥¿¤ò»È¤¦¤Ù¤¤«¡¢Rails¤¬¼±Ê̤¹¤ë¤¿¤á»È¤Ã¤Æ¤¤¤Þ¤¹¡£ > session¤Ë²¿¤òÅÐÏ¿¤·¤Æ¤â¡¢cookie¤ËľÀܥǡ¼¥¿¤¬ÅÐÏ¿¤µ¤ì¤¿¤ê¤Ï¤·¤Þ¤»¤ó¡£ > session¤Ï¥µ¡¼¥Ð¦¤ËÊݸ¤µ¤ì¤Þ¤¹¡£ > > > > > On Nov 23, 2007 10:06 AM, makoto kobori <kobori@c...> wrote: > >> ¤Ï¤¸¤á¤Þ¤·¤Æ¡£¾®Ë٤ȿ½¤·¤Þ¤¹¡£ >> >> ºòÆü°ã¤¦¥á¥¢¥É¤ÇÁ÷¤Ã¤¿¤Î¤Ç¤¹¤¬¤¦¤Þ¤¯ÇÛÁ÷¤µ¤ì¤Æ¤Ê¤¤¤ß¤¿¤¤¤Ê¤Î¤Ç >> ¥á¥¢¥É¤òÊѤ¨¤ÆÅÐÏ¿¤µ¤»¤Æ¤¤¤¿¤À¤¤Þ¤·¤¿¡£ >> >> ²áµî¥í¥°¤Ë¤â¤¢¤ê¤Þ¤¹¤¬¡¢¥Ð¥¤¥Ê¥ê¤Î²èÁü¥Ç¡¼¥¿¤ò£È£Ô£Í£Ì¾å >> ¤Ëɽ¼¨¤µ¤»¤ëÊýË¡¤Ç¼ÁÌä¤Ç¤¹¡£ >> >> ¶ñÂÎŪ¤Ë¤Ï >> ¡¥¢¥Ã¥×¥í¡¼¥É²èÌ̤ǥ桼¥¶¤¬jpeg¤òupload¤¹¤ë¡£ >> ¢³Îǧ²èÌ̤ǥ¢¥Ã¥×¥í¡¼¥É¤µ¤ì¤¿²èÁü¤ò³Îǧ >> ££Ä£ÂÅÐÏ¿ >> >> ¤È¤¤¤¦Î®¤ì¤òºî¤ê¤¿¤¤¤Î¤Ç¤¹¡£ >> >> ¼ÂÁõ¤Ï >> ¡ <%= file_field "file", "picture" %> >> ¤Ç¥Ó¥å¡¼¤òºî¤Ã¤Æ¥¢¥¯¥·¥ç¥ó¤ò¸Æ¤Ó½Ð¤·¤Þ¤¹¡£ >> >> ¢¸Æ¤Ó½Ð¤·¤¿¥¢¥¯¥·¥ç¥ó¤Ï°Ê²¼¡£session¤Ç²èÁü¤Î¥Ç¡¼¥¿¤ò >> °ú¤ÅϤ·¤Þ¤¹¡£ >> ------------------------------------------ >> @pic=params[:file]['picture'] >> session[:pic1_name]=@pic.original_filename >> session[:pic1_ct] = @pic.content_type >> session[:pic1_data] = @pic.read >> ------------------------------------------ >> >> ¤³¤Î¥¢¥¯¥·¥ç¥ó¤ËÂбþ¤¹¤ë¥Ó¥å¡¼¤¬°Ê²¼ >> ------------------------------------------ >> <h1>Upload#view</h1> >> >> title:<%= @title %><br> >> >> <%=image_tag(url_for(:action=> 'draw',:extension=>'.jpg')) >> %> >> >> ------------------------------------------ >> >> url_for¤Ç¸Æ¤Ó½Ð¤·¤Æ¤¤¤ë¥¢¥¯¥·¥ç¥ódraw¤¬°Ê²¼¤Ç¤¹¡£ >> >> ------------------------------------------ >> send_data session[:pic1_data], >> :filename => session[:pic1_name], >> :type => session[:pic1_ct], >> :disposition => 'inline' >> ------------------------------------------ >> >> ¤³¤³¤Ç¼ÁÌä¤Ï¡¢²èÁü¤¬É½¼¨¤µ¤ì¤ë¤â¤Î¤Î¡¢session¤Ç >> Ãͤò°ú¤ÅϤ¹¤Î¤¬¡¢¶¯°ú¤Êµ¤¤¬¤·¤Æ¤Ê¤é¤Ê¤¤¤Î¤Ç¤¹¡£ >> ¤â¤¦¾¯¤·¥¹¥Þ¡¼¥È¤Ê¤ä¤êÊý¤Ï¤Ê¤¤¤â¤Î¤Ç¤·¤ç¤¦¤«¡£ >> >> session¤Ç¡¢@pic¤Þ¤ë¤´¤È»ØÄꤷ¤¿¤é¡¢ >> ¡ÖWe're sorry, but something went wrong.¡× >> ¤È½Ð¤Æ¤·¤Þ¤¤¤Þ¤·¤¿¡£¹½Â¤ÂΤÏsession¤ÇÅϤ»¤Ê¤¤¡© >> ¼ÂÂÖ¤Ïcookie¤À¤«¤éÅϤ»¤Ê¤¤¤È¤¤¤¦¤³¤È¤Ç¤·¤ç¤¦¤«¡£ >> >> ²¿¤«¤è¤¤¥¢¥É¥Ð¥¤¥¹¤¬¤´¤¶¤¤¤Þ¤·¤¿¤é¡¢¤´»ØƳ¤ª´ê¤¤¤·¤Þ¤¹¡£ >> >> >> -- >> ML: rails@r... >> »È¤¤Êý: http://QuickML.com/ >> >> > > > > -- ML: rails@r... »È¤¤Êý: http://QuickML.com/
2460 2007-11-23 02:06 [kobori@c... ] ¥Ð¥¤¥Ê¥ê¤Î²èÁü¥Ç¡¼¥¿¤ò HTML ¾å¤Ëɽ¼¨¤¹¤ëÊýË¡ 2462 2007-11-23 09:16 ¨±[someeda@g... ] -> 2463 2007-11-24 02:29 ¡¡¨±[kobori@c... ]