WordPressのヘッダーにFlashを埋め込もうとしたが表示されなかった件
4月 11, 2007
DreamweaverでFlashファイルを挿入して、プレビューするが真っ白のまま。IEでは「ムービーがロードできません」と表示される。
Re: ムービーがロードできません というエラー
http://www.flash-jp.com/modules/newbb/viewtopic.php?topic_id=5432&forum=8
Re: 外部テキストランダム読み込みのニュースティッカー
http://www.flash-jp.com/modules/newbb/viewtopic.php?topic_id=5426&forum=11&post_id=28266#forumpost28266
上記サイトのおかげで解決。
絶対パスでswfファイルを指定することで表示できた。
<embed src=”<?php bloginfo(‘template_directory’); ?>/images/wave.swf” quality=”high” pluginspage=”http://www.macromedia.com/go/getflashplayer” type=”application/x-shockwave-flash” width=”600″ height=”36″></embed>
ワードプレステーマ
2月 17, 2007
やさしい色使いがとてもきれいなテーマ。GPLライセンス。
WordPress Themes » Beccary
http://beccary.com/goodies/wordpress-themes/
マークアップ方法の説明があるなど、デモサイトがまた分かりやすい。
Themes by Beccary
http://themes.beccary.com/
洗練された美しさ
A theme a day – If..Else Log
http://ifelse.co.uk/archives/2006/02/21/a-theme-a-day/
これも好き!現在4テーマ。ページ下部のPublic Downloadsより。関係ないけどfaviconがかわいい。
WordPress Foliage Mod
http://5thirtyone.com/foliagemod/
Update: Widgetized October Special WordPress theme
http://5thirtyone.com/archives/703
WordPress 5ThirtyOne v2.0
http://5thirtyone.com/5thirtyonev2/
sandboxなど。シンプルで美しいテーマ 。
Themes · plaintxt.org
http://www.plaintxt.org/themes/
Portfolioサイトがまたかっこいい。木のシルエット。
Derek Punsalan…is
http://is.derekpunsalan.com/
どれも存在感のあるデザイン。ノンコマーシャルオンリー。
Nuwen.Com » WordPress Themes
http://www.nuwen.com/media/wordpress-themes
シンプルなテーマ
oriol.f2o.org » temas
http://oriol.f2o.org/category/temas
とにかくたくさんあります。 クリエーティブコモンズ Attribution 2.5 ライセンス
Kaushal Sheth » WordPress Themes
http://www.kaushalsheth.com/themes
グッドデザインテーマ80選
80 WordPress Themes | Dr. Web Weblog
http://www.drweb.de/weblog/weblog/?p=767
オフィシャルサイトのィーチャードテーマ
WordPress › Extend » Themes
http://wordpress.org/extend/themes/
オフィシャルテーマビューワ
Theme viewer
http://themes.wordpress.net/
アーカイブページで特定カテゴリーを非表示にする
1月 24, 2007
<?php
//非表示にするカテゴリーのIDを配列に。
$exclude = array(1,2);
//The Loop
if (have_posts()) : while (have_posts()) : the_post(); ?>
//非表示カテゴリーの投稿はループをスキップ
foreach(get_the_category() as $cat){
if(in_array($cat->cat_ID, $exclude)) {
continue 2;
}
}
?>
<?php the_title(); ?>
<?php the_time(‘m.d.Y’); ?>
<?php the_content(); ?>
<?php endwhile; else: ?>
<p><?php _e(‘Sorry, no posts matched your criteria.’); ?></p>
<?php endif; ?>
もっとスマートなやり方がありそうな気がする・・・
The Loopにカウンタ
1月 2, 2007
画像を格子状に並べたい場合などに、0,1,2,0,1,2・・・と規則的なクラス名をつける。
while文に
<?php if(have_posts()) : query_posts(‘cat=1′); ?>
<?php $i=0; while(have_posts()) : the_post(); ?>
<div class=”cell<?php echo $i%3; ?>“>
</div>
<?php $i++; endwhile; else: ?>
<p><?php _e(‘Sorry, no posts matched your criteria.’); ?></p>
<?php endif; ?>
foreeach文に
<?php
$posts = get_posts(‘category=1′);
$i=0;
foreach($posts as $post) :
setup_postdata($post);
?>
<div class=”cell<?php echo $i%3; ?>”>
</div>
<?php $i++; endforeach; ?>
<!–nextpage–>とthe_content()
1月 2, 2007
投稿記事中に<!–nextpage–>を挿入してページ分割すると、サイドバーに表示しているthe_content()の内容まで投稿記事と一緒になってしまった。
the_title()は影響なし。クエリーのないように関わらず、the_content()の内容が上書きされている模様。
print_rで$postsの内容を確認すると、post_contentは適正(?)なので、サイドバーのコードを以下のように修正。
修正前 <?php the_content(); ?>
修正後 <?php echo $post->post_content; ?>