2009年12月01日

<fieldset>をCSSで

印刷時 <fieldset>〜</fieldset> を使っている箇所がページをまたぐと枠線が崩れたり中身が欠けたりするバグがあるで、<div>を使ってCSSで再現した。


■HTML

<div class="sub-category">
  <div class="sub-category-title">
    Size
  </div>
  <div class="sub-category-body">
    Width:<input type="text" value="100" size="4" />< br />
    Height:<input type="text" value="100" size="4" />
  </div>
</div>

■CSS

.sub-category {
  position: relative;  /* for ie6,7 */
  border: 1px solid #cccccc;
  zoom: 1;  /* for ie6,7 */
}
.sub-category-title {
  position: absolute;  /* for ie6,7 */
  float: left;
  margin: -0.5em 0 0 0.5em;
  padding: 0 2px;
  background-color: #ffffff;
  font-weight: bold;
}

.sub-category-body {
clear: both;
}

2009年05月30日

Flash 3日目







2009年05月28日

はじめてのFlash

とりあえず未経験者が60分で作ったもの。
恥を忍んで記録。







2009年03月16日

iPhone ホームアイコンの設定

<link rel="apple-touch-icon" href="アイコン画像パス(pngでOK)" />

2009年02月24日

Amazonのセール品を表示するブックマークレット

Amazon Sale

javascript:(function(){var num=prompt("Ticket Number");if(num){window.location.href=location.href+"&pct-off="+num+"-";}})();;


1. Amazon.co.jpの検索エリアにて、セレクトボックスからジャンルを選ぶ
2. キーワードは空欄で[Go]を押下
3. 表示された画面でブックマークレット起動
4. ダイアログに検索したい値引き率を入力(ex.50)
5. 50%以上OFFの商品が表示されます

2008年11月21日

Firefoxバージョン振分け用 CSS hack

Firefox 1.0以降

.hoge, x:-moz-any-link {
.....
}


Firefox 1.5以降

.hoge, x:-moz-read-only {
.....
}


Firefox 3.0 以降

.hoge, x:-moz-broken {
.....
}

2008年08月26日

印刷がうまくいかないときのCSS

position: relative;
width: auto;
height: auto;
overflow-y: visible;
overflow-x: visible;

あやしい親ブロックに * で適用させてシラミつぶし。

2007年11月01日

text-indent: -1em

※ああああああああああああああああああああああああああああああああああああああああああああああああああああああ

    ↓

※ああああああああああああああああああああああああああああああああああああああああああああああああああああああ

.hoge {
  text-indent: -1em;
  margin-left: 1em;
}


Thanx!! http://dekoboko.org

2007年10月05日

Firefoxでinput type="file"

指定無し

<input type="file">

size="30"

<input type="file" size="30"/>

width:300px

<input type="file" style="width:300px"/>

size="30" width:300px

<input type="file" size="30" style="width:300px"/>

Firefoxにはstyleでのwidth指定が反映されないので、IEと揃えたい場合は「size」を使う。



2007年10月03日

Firefox多重起動

※事前にfirefoxが立ち上がっていない状態にしておく

$ firefox -profilemanager

profilemanagerでprofile作成する。
作成したらfirefoxを起動させずにprofilemanagerを終了。


それぞれのprofileでfirefoxを起動。

$ firefox -P [profile name] -no-remote

# defaultのprofile name = default

2007年07月16日

ウインドウリサイズ用ブックマークレット

1024×768

javascript:void(resizeTo(1024,768));


現在のウインドウサイズを知りたいとき

javascript:alert(window.outerWidth + %22×%22 + window.outerHeight);

Colorzilla on Ubuntu

以下の手順で、Colorzillaのスポイトが使えない問題と、Firebugが起動しない問題が解消。


1.) Colorzillaがインストールされているなら、削除しておく。

2.) http://www.mozilla.com/firefox/から、Firefox(バイナリのtarball)をダウンロード。

3.) Firefoxを閉じる。

4.)


$ tar xzvf firefox-2.0.*.tar.gz -C /tmp/
$ sudo cp /tmp/firefox/libxpcom* /usr/lib/firefox/

6.) Firefoxを再起動して、Colorzillaをインストール。

#http://ubuntuforums.org/showthread.php?t=451901&highlight=colorzilla

FizzBuzz (JavaScript)

1から100までの数をプリントするプログラムを書け。ただし3の倍数のときは数の代わりに「Fizz」と、5の倍数のときは「Buzz」とプリントし、3と5両方の倍数の場合には「FizzBuzz」とプリントすること。

<html>
<head>
<title>FizzBuzz</title>
<script type="text/javascript">
<!--
function fizzbuzz() {

  for (var i=1; i<=100; i++) {

    if (i%(3*5) == 0) {
      document.write('FizzBuzz ');
    }else if (i%(3) == 0) {
      document.write('Fizz ');
    }else if (i%(5) == 0) {
      document.write('Buzz ');
    }else {
      document.write(i + ' ');
    }
  }

}
//-->
</script>
</head>
<body>
<script type="text/javascript">
  fizzbuzz();
</script>
</body>
</html>

2007年07月09日

nvidiaドライバのセットアップ

[システム]-[システム管理]-[制限付きドライバの管理]-[NVIDIAの高性能グラフィックドライバ]
有効にする。

再起動して、[制限付きドライバを有効にするにはここをクリック]。

2007年07月02日

Ubuntu 解像度の変更

/etc/X11/xorg.conf


Section "Monitor"
HorizSync 1.0-10000.0
VertRefresh 1.0-10000.0


Section "Screen"
DefaultDepth 24
SubSection "Display"
Depth 1
Modes "1600x1200" "1400x1050" "1280x1024" "1024x768" "800x600" "640x480"
EndSubSection
SubSection "Display"
Depth 4
Modes "1600x1200" "1400x1050" "1280x1024" "1024x768" "800x600" "640x480"
EndSubSection
SubSection "Display"
Depth 8
Modes "1600x1200" "1400x1050" "1280x1024" "1024x768" "800x600" "640x480"
EndSubSection
SubSection "Display"
Depth 15
Modes "1600x1200" "1400x1050" "1280x1024" "1024x768" "800x600" "640x480"
EndSubSection
SubSection "Display"
Depth 16
Modes "1600x1200" "1400x1050" "1280x1024" "1024x768" "800x600" "640x480"
EndSubSection
SubSection "Display"
Depth 24
Modes "1600x1200" "1400x1050" "1280x1024" "1024x768" "800x600" "640x480"
EndSubSection

2007年05月30日

Microsoft IME スタンダードのプロパティ

IME>ツール>プロパティ

全般>入力設定>スペースの入力を「常に半角」

2007年05月10日

自作 wii センサーバー



USB携帯充電器 (99円ショップ)
赤外線LED×2 (千石電商)
抵抗 100Ω
配線用モール (東急ハンズ)







2007年04月25日

MTでエントリー画像にドロップシャドウ

CSS

.shadow {
  margin: 10px 10px 0 5px;
  background: url(./images/shadow.png) right bottom;
  float: left;
}

.shadow .discription {
  position: relative;
  left: -5px;
  top: -5px;
  padding: 10px 10px 20px 10px;
  background: #f9f9f9;
  border: 1px solid #999999;
  font-size: 80%;
}
html>/**/body .shadow .discription {
  left: -7px;
  top: -7px;
}

.shadow .discription img {
  margin-bottom: 15px;
}


lib\MT\App\CMS.pm

elsif ($q->param('include')) {
        if ($thumb) {
            return <<"HTML";
<a href="$url"><div class="shadow"><div class="discription"><img alt="$fname" src="$thumb" width="$thumb_width" height="$thumb_height" /></a><br /></div></div><br clear="all">
HTML
        } else {
            return <<"HTML";
<div class="shadow"><div class="discription"><img alt="$fname" src="$url" width="$width" height="$height" /><br /></div></div><br clear="all">
HTML
        }
    }

Ubuntuステッカー

thx 2 Ubuntu Au !!

2007年04月21日

Mozilla Party JP 8.0


Mozzilla Goods

2007年04月17日

beryl拡張:エメラルドテーマ

$ sudo apt-get install emerald-themes emerald-themes-extra

念願のberyl

$ sudo gedit /etc/apt/sources.list



deb http://download.tuxfamily.org/3v1deb edgy beryl-svn
deb-src http://download.tuxfamily.org/3v1deb edgy beryl-svn

$ wget http://download.tuxfamily.org/3v1deb/DD800CD9.gpg -O- | sudo apt-key add -
$ sudo apt-get update
$ sudo apt-get install beryl

$ beryl-manager

自動起動するプログラムを設定

システム>設定>セッション>自動起動するプログラム

2007年04月11日

Background Flicker (IE6)

html { filter: expression(document.execCommand("BackgroundImageCache", false, true)); }

or

try { document.execCommand("BackgroundImageCache", false, true); } catch(e) {}

2007年04月10日

センタリング

Firefox:センタリングしたい要素に margin:0 auto;
IE:センタリングしたい要素の"親"要素に text-align:center;

=> センタリングしたい要素の"親"要素に margin:0 auto; text-align:center;

※子要素もセンタリングされてしまうので text-align:left;
※Firefox,Opera等で常にスクロールバーを表示させるには html { height: 100%; margin-bottom: 1px; }

2007年04月01日

GR DIGITAL

2007年03月26日

+1


Happybirthday to me !!

2007年03月25日

可愛いエコバッグ

ROO-shopper
http://www.superplanning.co.jp/rootote/rooshopper/

2007年03月23日

半角英数の強制改行

word-wrap: break-word or normal
word-break: break-all (?)

.htaccessファイルを隠す

cgi実行ファイルとして扱う

AddHandler cgi-script htaccess


全てのホストからの接続を拒否

<Files ~ "^\.ht">
    order allow,deny
    deny from all
    satisfy all
</Files>

特殊文字

&quot;"
&amp;&
&lt;<
&gt;>
&nbsp;space
&copy;©

オリジナル404

.htaccess

ErrorDocument 404 http://hogehoge/err/404.shtml
ErrorDocument 500 http://hogehoge/err/500.shtml
ErrorDocument 403 http://hogehoge/err/403.shtml

ロボット避け

<meta name="robots" content="noindex,nofollow">

ベーシック認証

.htaccess

AuthUserFile /home/hoge/.htpasswd
AuthGroupFile /dev/null
AuthName "Please enter your ID and password"
AuthType Basic
require valid-user


アスキーモードでアップロード

続きを読む "ベーシック認証" »

2007年03月20日

Cygwin インストール

http://www.cygwin.com/
「Install or update」から setup.exe をダウンロード

「Net」「X11」を "Default" → "Install"


?必要?
・ Base
・ Devel/gcc
・ Devel/gdb
・ Devel/make
・ Devel/gettext-devel

2007年03月19日

携帯電話エミュレータ

Docomo
iモードHTMLシミュレータ
iモードHTMLシミュレータII

au
Openwave® SDK 6.2K
Openwave® SDK 3.3.1J

softbank
ウェブコンテンツヴューア

2007年03月17日

Eclipseに最新のJREを追加

ウインドウ>設定>Java>インストール済みのJRE

[追加]からJREの追加

JREのホーム・ディレクトリー
→ C:\Program Files\Java\jre1.5.0_11


2007年03月02日

ヘテロクロミア・ミクル


「対象年齢:15歳以上」だそうです。

2007年02月25日

DSでyoutube動画を再生

1. FLV Splitterffdshowをインストール


   - AX(またはDLL)ファイルのインストール
      - システムフォルダ [ C:\WINDOWS\system32 ] にAXファイルをコピーします。
      - 「ファイル名を指定して実行」。
         - インストール: "regsvr32 FLVSplitter.ax"
         - アンインストール: "regsvr32 -u FLVSplitter.ax"
      - 「FLVSplitter.ax の Dll(Un)RegisterServer は成功しました」のダイアログ→「OK」。


2. youtube動画をダウンロード


3. moonshell10_dpgtools.zip をダウンロード
   http://mdxonline.dyndns.org/


4. moonshell16_with_dpgtools121\dpgtools121\dpgenc.exe を起動

2007年02月24日

youtube動画をダウンロード

ブックマークレット

2007年02月22日

DS Linux


http://dslinux.org/
Downloadsから「dslinux.nds」をDL。


画像:# ls bin してるとこ。

2007年02月15日

Ubuntu イースターエッグ

1.

sudo apt-get moo


2.
アプリケーションの実行で

free the fish

2007年02月13日

GRUBの設定

fuga@hoge:/~$ sudo gedit /boot/grub/menu.lst

OSを並び替える。

2007年02月12日

UbuntuにWindowsのパーティションをマウント

  • ntfs-3gのインストール
    1. sources.list(sudo gedit /etc/apt/sources.list)に追加
      #The mount is done like the partition of Windows. deb http://givre.cabspace.com/ubuntu/ edgy main deb http://ntfs-3g.sitesweetsite.info/ubuntu/ edgy main deb http://flomertens.keo.in/ubuntu/ edgy main

  • GPGkeyをインポート

    1. wget http://flomertens.keo.in/ubuntu/givre_key.asc -O- | sudo apt-key add -

  • アップデート

    1. sudo apt-get update

  • ntfs-3gのインストール

    1. sudo apt-get install ntfs-3g

  • ntfs-3gの設定


    1. sudo fdisk -lで利用可能なパーティションを確認して
      NTFS(/dev/hda1)

  • fstabのバックアップ

    1. sudo cp /etc/fstab /etc/fstab.bak

  • マウントするディレクトリの作成

    1. sudo mkdir /media/windows

  • fstabファイルを編集


    1. fstabファイル(sudo gedit /etc/fstab)の最終行に
      /dev/hda1 /media/ ntfs-3g defaults,ja_JP.utf8 0 0

      ※タブ区切りで追加する。

  • アンマウント、マウント


    1. sudo umount -a
      sudo mount -a

2007年02月11日

ソフトのインストール

fuga@hoge:/~$ sudo apt-get install ソフト名

ex.

fuga@hoge:/~$ sudo apt-get install emacs


入れるべきソフト


  • emacs
  • Amarok
  • Skype
  • gFTP

Caps Lock を Ctrl に (Ubuntu)

システム>設定>キーボード>レイアウトのオプション>Ctrl key position>Make CapsLock an additional Ctrl.

2007年02月10日

スーパーユーザ

fuga@hoge:~$ sudo su
Password:

ソフトを最新にアップデート

アプリケーション>アクセサリ>GNOME端末

fuga@hoge:/~$ sudo apt-get update
fuga@hoge:/~$ sudo apt-get upgrade

UbuntuでShift+space

DefaultだとShift+spaceで日本語入力機能のオン・オフになっているので、
Shift+spaceで半角スペースを出すため。

Anthy 右クリック>SCIMを設定>全体設定>[ホットキー]SCIM開始からShift+spaceを削除

Anthy 右クリック>設定更新

UbuntuでWi-Fi

システム>システム管理>ネットワークの管理>「無線LAN接続」選択>プロパティ










[レ]この接続を有効にする
無線LANの設定
 ネットワーク名 [ ]
 パスワードタイプ [プレーンテキスト(ASCll)]
 ネットワークパスワード [ ]
接続の設定
 設定の種類 [DHCP]

2007年02月09日

Windows Messengerのアンインストール

ファイル名を指定して実行
RunDll32 advpack.dll,LaunchINFSection %windir%\INF\msmsgs.inf,BLC.Remove

2007年01月27日

Caps Lock を Ctrl に (windows)

Caps Lock ↔ Ctrl

Windows Registry Editor Version 5.00

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,03,00,00,00,1d,00,3a,00,3a,00,1d,00,\
00,00,00,00


Caps Lock → Ctrl

REGEDIT4

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,02,00,00,00,1d,00,3a,00,00,00,00,00

2007年01月26日

ファンクションキー

F5orCtrl + r:更新
F6orCtrl + u:ひらがな
F7orCtrl + i:全角カタカナ
F8orCtrl + o:半角カタカナ
F9orCtrl + p:全角英数字
F10orCtrl + t:半角英数字

2007年01月25日

日本語キーボードから英語キーボード

USBキーボードを接続
ファイル名を指定して実行 - 「regedit」
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\i8042prt\Parameters
LayerDriver : JPN KBD106.DLL → KBD101.DLL
OverridekeyboardIdentifier : PCAT_106KEY → PCAT_101KEY
OS再起動

2007年01月24日

Meadow(Emacs)コマンド - bookmark

C-x r m: ブックマーク登録
C-x r b: setしたwordでjump
C-x r l: ブックマークの一覧表示
1: 一覧表示からjump

2007年01月22日

Thumbs.dbを作らない

フォルダオプション>表示>縮小版をキャッシュしない

2007年01月21日

Meadow インストール(Netinstaller形式)

http://www.meadowy.org/meadow/netinstall/

ダウンロード>Meadow 2.10>setup.exeバイナリ>setup-ja.exe

Meadow\dot.emacs.ja → .emacs

2007年01月10日

jspでHello World

C:\Program Files\Apache Software Foundation\Tomcat 5.5\webapps\xxx\helloworld.jsp

<html>
<head>
<title>Hello World!</title>
</head>
<body>
<%
String hello = "Hello World!";
out.println(hello);
%>
</body>
</html>


http://localhost:8080/xxx/helloworld.jsp

2007年01月05日

Krispy Kreme Doughnuts

1時間待ち

http://www.krispykreme.jp/

2006年12月29日

Tomcat インストール

Tomcat
http://tomcat.apache.org/index.html
# Windows Service Installer をDL

Eclipse Tomcatプラグイン
http://www.sysdeo.com/eclipse/tomcatplugin からDL
com.sysdeo.eclipse.tomcat を eclipse/plugins/にコピー
メニューの ウインドウ>設定
・Tomcatバージョン
・Tomcatホーム
・コンテキスト宣言モード server.xml
・設定ファイル conf/server.xml
ウィンドウ>パースペクティブのカスタマイズ
・Javaとtomcatにチェック

http://localhost:8080/

続きを読む "Tomcat インストール" »

2006年12月21日

Opensky2.0


2006年12月19日

Xrea に MT導入

15行目
CGIPath http://www.xxx.com/xxx/

21行目
# StaticWebPath http://www.example.com/mt-static

27~32行目
##### MYSQL #####
ObjectDriver DBI::mysql
Database データベース名
DBUser ユーザー名
DBPassword データベースパスワード
DBHost localhost

34行目以下削除

2006年12月18日

height: expression();

height: expression(ここにJavaScript):

min-heightとmax-heightをIEで実現。

height:expression(document.body.clientHeight < 100? "100px" : document.body.clientHeight > 500? "500px" : "auto");


document.body.clientHeight < 100? "100px" ------ 100pxより小さいとき 100px
document.body.clientHeight > 500? "500px" ------ 500pxより大きいとき 500px
"auto" ------ その他 自動

2006年08月10日

Peek a boo bug

回避策:floatの親要素にwidth or height要素を指定する。

 1  |  2  |  3  |  4  |  5  |  6  |  7  |  8  |  9  |  10  |  11  |  12  |  13  | All pages

カテゴリー

アーカイブ

Mozilla Firefox ブラウザ無料ダウンロード