<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
		xmlns:xhtml="http://www.w3.org/1999/xhtml"
>

<channel>
	<title>プレゼン資料</title>
	<atom:link href="http://presen.php-web.net/feed/" rel="self" type="application/rss+xml" />
	<link>http://presen.php-web.net</link>
	<description>Just another WordPress site</description>
	<lastBuildDate>Sat, 04 Dec 2010 12:41:36 +0000</lastBuildDate>
	<language>ja</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3</generator>
<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://presen.php-web.net/feed/" />
		<item>
		<title>プラグイン作成の参考になる</title>
		<link>http://presen.php-web.net/2010/written-code/</link>
		<comments>http://presen.php-web.net/2010/written-code/#comments</comments>
		<pubDate>Fri, 22 Oct 2010 04:55:12 +0000</pubDate>
		<dc:creator>presenadmin</dc:creator>
				<category><![CDATA[BuddyPress カスタマイズ]]></category>

		<guid isPermaLink="false">http://presen.php-web.net/?p=228</guid>
		<description><![CDATA[WordPress は関数ベース Codex の解説も関数ベース オブジェクト指向の公式情報が少ない Subscribe2 はオブジェクト指向 オブジェクト指向でプラグインを書くときの参考になる フックで array(&#038; &#8230; <a href="http://presen.php-web.net/2010/written-code/">続きを読む <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<ul>
<li>WordPress は関数ベース</li>
<ul>
<li>Codex の解説も関数ベース</li>
<li>オブジェクト指向の公式情報が少ない</li>
</ul>
<li>Subscribe2 はオブジェクト指向</li>
<ul>
<li>オブジェクト指向でプラグインを書くときの参考になる</li>
<li>フックで array(&#038;$this, &#8216;メソッド&#8217;)</li>
</ul>
</ul>
<p><span id="more-228"></span><br />
実例を元に学習できるので、プラグイン作成／開発の勉強がしやすい。</p>
<p>その結果として、より良いものが作成しやすい。</p>
]]></content:encoded>
			<wfw:commentRss>http://presen.php-web.net/2010/written-code/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://presen.php-web.net/2010/written-code/" />
	</item>
		<item>
		<title>ソースを読んで理解する</title>
		<link>http://presen.php-web.net/2010/reading-sourcecode/</link>
		<comments>http://presen.php-web.net/2010/reading-sourcecode/#comments</comments>
		<pubDate>Fri, 22 Oct 2010 04:51:26 +0000</pubDate>
		<dc:creator>presenadmin</dc:creator>
				<category><![CDATA[BuddyPress カスタマイズ]]></category>

		<guid isPermaLink="false">http://presen.php-web.net/?p=227</guid>
		<description><![CDATA[BP:独自の登録処理を行っている 登録処理にフックするプラグインは動作しない BP:様々なフックが用意されている プラグインのフック場所を書き換えれば動作する バディプレスプラグインのソースコードを読むと、独自処理を行っ &#8230; <a href="http://presen.php-web.net/2010/reading-sourcecode/">続きを読む <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<ul>
<li>BP:独自の登録処理を行っている</li>
<ul>
<li>登録処理にフックするプラグインは動作しない</li>
</ul>
<li>BP:様々なフックが用意されている</li>
<ul>
<li>プラグインのフック場所を書き換えれば動作する</li>
</ul>
</ul>
<p><span id="more-227"></span><br />
バディプレスプラグインのソースコードを読むと、独自処理を行っていることが分かる。同時に、様々なフックが用意されていることも分かる。</p>
<p>プラグインのフックする場所をバディプレス対応にすれば良いことが分かる。</p>
<p>ソースが公開されているので、プログラムの動作が理解しやすい。お客さんの要望に応じて、きめ細かくカスタマイズ可能なので、顧客満足度にも貢献する。</p>
]]></content:encoded>
			<wfw:commentRss>http://presen.php-web.net/2010/reading-sourcecode/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://presen.php-web.net/2010/reading-sourcecode/" />
	</item>
		<item>
		<title>中身が公開されている</title>
		<link>http://presen.php-web.net/2010/open-sourcecode/</link>
		<comments>http://presen.php-web.net/2010/open-sourcecode/#comments</comments>
		<pubDate>Fri, 22 Oct 2010 04:48:23 +0000</pubDate>
		<dc:creator>presenadmin</dc:creator>
				<category><![CDATA[BuddyPress カスタマイズ]]></category>

		<guid isPermaLink="false">http://presen.php-web.net/?p=226</guid>
		<description><![CDATA[動作を理解し、納得して使用できる 自由にカスタマイズできる プラグイン作成の参考になる プラグインのソースコードが公開されているのが、大きなメリットである。 プラグインのソースを読むことで、プラグインの動作を理解した上で &#8230; <a href="http://presen.php-web.net/2010/open-sourcecode/">続きを読む <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<ul>
<li>動作を理解し、納得して使用できる</li>
<li>自由にカスタマイズできる</li>
<li>プラグイン作成の参考になる</li>
</ul>
<p><span id="more-226"></span><br />
プラグインのソースコードが公開されているのが、大きなメリットである。</p>
<p>プラグインのソースを読むことで、プラグインの動作を理解した上で使用できる。</p>
<p>ソースが公開されているので、自由にカスタマイズ可能。元のプラグインに機能を追加したり、別のプラグインと併用可能にしたりできる。顧客の要望に応じたきめ細かい対応ができる。</p>
<p>既存のプラグインのソースを読むことで、自分でプラグインを作成するときに参考になる。</p>
]]></content:encoded>
			<wfw:commentRss>http://presen.php-web.net/2010/open-sourcecode/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://presen.php-web.net/2010/open-sourcecode/" />
	</item>
		<item>
		<title>プラグイン本体は改変しない</title>
		<link>http://presen.php-web.net/2010/no-core-change/</link>
		<comments>http://presen.php-web.net/2010/no-core-change/#comments</comments>
		<pubDate>Thu, 21 Oct 2010 18:55:20 +0000</pubDate>
		<dc:creator>presenadmin</dc:creator>
				<category><![CDATA[BuddyPress カスタマイズ]]></category>

		<guid isPermaLink="false">http://presen.php-web.net/?p=229</guid>
		<description><![CDATA[functions.php に書く if ( class_exists(&#8216;s2class&#8217;) &#038;&#038; $mysubscribe2 instanceof s2class ) { a &#8230; <a href="http://presen.php-web.net/2010/no-core-change/">続きを読む <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<ul>
<li>functions.php に書く</li>
</ul>
<p>if ( class_exists(&#8216;s2class&#8217;) &#038;&#038; $mysubscribe2 instanceof s2class ) {<br />
add_action(&#8216;bp_custom_profile_edit_fields&#8217;, array(&#038;$mysubscribe2, &#8216;register_form&#8217;));<br />
}<br />
<span id="more-229"></span></p>
<p>プラグイン本体は書き換えないようにすると、プラグインアップデート時に楽（大幅に仕様変更があった時は別）</p>
<p>Subscribe2 プラグインはオブジェクト指向。カスタマイズしやすいように記述されている。オブジェクト指向で書かれていないプラグインだと大変かもしれない。</p>
<p>上記の例では、まず、Subscribe2 のクラス<code>s2class</code>が存在するか、および<code>$mysubscribe2</code>がそのインスタンスか、をチェックしている。チェックを通った場合は、アクションフックを追加している。</p>
]]></content:encoded>
			<wfw:commentRss>http://presen.php-web.net/2010/no-core-change/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://presen.php-web.net/2010/no-core-change/" />
	</item>
		<item>
		<title>フック書き換え</title>
		<link>http://presen.php-web.net/2010/hook-customize/</link>
		<comments>http://presen.php-web.net/2010/hook-customize/#comments</comments>
		<pubDate>Thu, 21 Oct 2010 15:48:56 +0000</pubDate>
		<dc:creator>presenadmin</dc:creator>
				<category><![CDATA[BuddyPress カスタマイズ]]></category>

		<guid isPermaLink="false">http://presen.php-web.net/?p=225</guid>
		<description><![CDATA[s2class->register_form WPのフック：register_form BPのフック：bp_custom_profile_edit_fields サブスクライブがフックしている場所をワードプレス、バディプ &#8230; <a href="http://presen.php-web.net/2010/hook-customize/">続きを読む <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<ul>
<li>s2class->register_form</li>
<li>WPのフック：register_form</li>
<li>BPのフック：bp_custom_profile_edit_fields</li>
</ul>
<p><span id="more-225"></span></p>
<hr />
<p>サブスクライブがフックしている場所をワードプレス、バディプレスのソースを調べて探す。</p>
<p>ワードプレスでは、wp-login.php の <code>register_form</code>。バディプレスでは、register.php の<code>bp_custom_profile_edit_fields</code></p>
<p>subscribe2.php のアクションフックの部分を書き換えれると、BuddyPress の登録画面でメルマガ登録可能になる。</p>
]]></content:encoded>
			<wfw:commentRss>http://presen.php-web.net/2010/hook-customize/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://presen.php-web.net/2010/hook-customize/" />
	</item>
		<item>
		<title>Subscribe2</title>
		<link>http://presen.php-web.net/2010/subscribe2/</link>
		<comments>http://presen.php-web.net/2010/subscribe2/#comments</comments>
		<pubDate>Thu, 21 Oct 2010 15:43:50 +0000</pubDate>
		<dc:creator>presenadmin</dc:creator>
				<category><![CDATA[BuddyPress カスタマイズ]]></category>

		<guid isPermaLink="false">http://presen.php-web.net/?p=222</guid>
		<description><![CDATA[メルマガプラグイン ユーザー登録にフック WPとBPで異なる サブスクライブをそのままインストールした場合、バディプレスのユーザー登録にフックしていないので、バディプレスの登録画面で「メルマガ登録」を一緒にはできない。  &#8230; <a href="http://presen.php-web.net/2010/subscribe2/">続きを読む <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<ul>
<li>メルマガプラグイン</li>
<li>ユーザー登録にフック</li>
<li>WPとBPで異なる</li>
</ul>
<p><span id="more-222"></span><br />
<a href="http://presen.php-web.net/wp-content/uploads/2010/10/bp.png" rel="lightbox[222]"><img src="http://presen.php-web.net/wp-content/uploads/2010/10/bp-180x180.png" alt="" title="bp" width="180" height="180" class="alignnone size-thumbnail wp-image-223" /></a><a href="http://presen.php-web.net/wp-content/uploads/2010/10/bp2.png" rel="lightbox[222]"><img src="http://presen.php-web.net/wp-content/uploads/2010/10/bp2-180x180.png" alt="" title="bp2" width="180" height="180" class="alignnone size-thumbnail wp-image-224" /></a></p>
<hr />
サブスクライブをそのままインストールした場合、バディプレスのユーザー登録にフックしていないので、バディプレスの登録画面で「メルマガ登録」を一緒にはできない。</p>
<p>フックを BuddyPress に対応させる(プラグインをカスタマイズする)</p>
]]></content:encoded>
			<wfw:commentRss>http://presen.php-web.net/2010/subscribe2/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://presen.php-web.net/2010/subscribe2/" />
	</item>
		<item>
		<title>BuddyPress の構造</title>
		<link>http://presen.php-web.net/2010/buddypress-structure/</link>
		<comments>http://presen.php-web.net/2010/buddypress-structure/#comments</comments>
		<pubDate>Sun, 20 Jun 2010 08:21:56 +0000</pubDate>
		<dc:creator>presenadmin</dc:creator>
				<category><![CDATA[BuddyPress カスタマイズ]]></category>

		<guid isPermaLink="false">http://presen.php-web.net/?p=221</guid>
		<description><![CDATA[機能毎にフォルダ分け BP 対応テーマを利用する BP 独自のフック多数 bp-activity, bp-blogs, bp-core, bp-forums, bp-friends, bp-groups, bp-mess &#8230; <a href="http://presen.php-web.net/2010/buddypress-structure/">続きを読む <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<ul>
<li>機能毎にフォルダ分け</li>
<li>BP 対応テーマを利用する</li>
<li>BP 独自のフック多数</li>
</ul>
<p><span id="more-221"></span><br />
bp-activity, bp-blogs, bp-core, bp-forums, bp-friends, bp-groups, bp-messages, bp-xprofile にフォルダ分けされている。テンプレート関数やフィルターフックを探しやすい。</p>
<p>テーマは bp-themes にデフォルトが用意されている。別のテーマをインストールするときは、BuddyPress 対応かどうかを確認しておく。対応テーマだと、グループや登録メンバーの一覧ページなどが用意されている。</p>
<p>BuddyPress 自体はプラグインだが、BuddyPress にはたくさんのフックが用意されている(テーマファイルを見ると良く分かる)。通常の WP 用プラグインの、フック箇所を書き換えることで、BuddyPress 対応にできる。</p>
]]></content:encoded>
			<wfw:commentRss>http://presen.php-web.net/2010/buddypress-structure/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://presen.php-web.net/2010/buddypress-structure/" />
	</item>
		<item>
		<title>PHP で自由に拡張</title>
		<link>http://presen.php-web.net/2010/php-customize/</link>
		<comments>http://presen.php-web.net/2010/php-customize/#comments</comments>
		<pubDate>Thu, 17 Jun 2010 21:00:12 +0000</pubDate>
		<dc:creator>presenadmin</dc:creator>
				<category><![CDATA[BuddyPress カスタマイズ]]></category>

		<guid isPermaLink="false">http://presen.php-web.net/?p=219</guid>
		<description><![CDATA[例：5日以内の記事に新着 if (get_the_date(&#8216;Ymd&#8217;) > date(&#8216;Ymd&#8217;,strtotime(&#8216;-5 day&#8217;))) ec &#8230; <a href="http://presen.php-web.net/2010/php-customize/">続きを読む <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<ul>
<li>例：5日以内の記事に新着</li>
<li>if (get_the_date(&#8216;Ymd&#8217;) > date(&#8216;Ymd&#8217;,strtotime(&#8216;-5 day&#8217;)))<br />
echo &#8220;新着&#8221; ;</li>
<li>オリジナル関数が作成可能</li>
</ul>
<p><span id="more-219"></span><br />
上の例では、「5日以内に書いた記事」に「新着」を表示する。get_the_date を get_the_modified_date に変更すれば、「5日以内に更新した記事」という条件になる。</p>
<p>WordPress 本体の機能は、他のツールと比較して多いほうではない(上の例は、高機能な CMS なら管理画面から設定可能かもしれない)。しかしながら、テンプレートタグとして用意されているものを使う、という選択肢だけでなく、テンプレートタグが用意されていなくても、PHP で自由に拡張することができる。また PHP を利用する方法は、WordPress だけでなく、PHP を利用するツールをカスタマイズする時にも役立つ、一般性の高い方法である。</p>
<p>良く使うものは、functions.php でオリジナル関数を定義可能。</p>
]]></content:encoded>
			<wfw:commentRss>http://presen.php-web.net/2010/php-customize/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://presen.php-web.net/2010/php-customize/" />
	</item>
		<item>
		<title>bp_関数</title>
		<link>http://presen.php-web.net/2010/bp-functions/</link>
		<comments>http://presen.php-web.net/2010/bp-functions/#comments</comments>
		<pubDate>Mon, 14 Jun 2010 22:45:45 +0000</pubDate>
		<dc:creator>presenadmin</dc:creator>
				<category><![CDATA[BuddyPress カスタマイズ]]></category>

		<guid isPermaLink="false">http://presen.php-web.net/?p=218</guid>
		<description><![CDATA[目的別に整理されている テンプレートタグは bp_ で始まる ウィジェットは BP_ で始まる bp-activity, bp-blogs, bp-core, bp-forums, bp-groups, bp-messa &#8230; <a href="http://presen.php-web.net/2010/bp-functions/">続きを読む <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<ul>
<li>目的別に整理されている</li>
<li>テンプレートタグは bp_ で始まる</li>
<li>ウィジェットは BP_ で始まる</li>
</ul>
<p><span id="more-218"></span><br />
bp-activity, bp-blogs, bp-core, bp-forums, bp-groups, bp-messages, bp-xprofile というフォルダに分けられており、テンプレートタグ、フィルター、ウィジェット等が整理されている。</p>
<p>WordPress 本体は雑然としているが、BuddyPress はテンプレートタグは bp_ 、ウィジェットは BP_ と整頓されている。ソースを読むことで、カスタマイズ方法を学ぶことが容易。</p>
]]></content:encoded>
			<wfw:commentRss>http://presen.php-web.net/2010/bp-functions/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://presen.php-web.net/2010/bp-functions/" />
	</item>
		<item>
		<title>PHPを学ぶ(BuddyPress カスタマイズ)</title>
		<link>http://presen.php-web.net/2010/buddypress-php/</link>
		<comments>http://presen.php-web.net/2010/buddypress-php/#comments</comments>
		<pubDate>Sun, 13 Jun 2010 10:57:57 +0000</pubDate>
		<dc:creator>presenadmin</dc:creator>
				<category><![CDATA[BuddyPress カスタマイズ]]></category>

		<guid isPermaLink="false">http://presen.php-web.net/?p=217</guid>
		<description><![CDATA[PHP の特色：HTML と混在可能 WP/BP のテンプレートも同様 PHP の関数が利用可能 PHP の特色として、HTML と混在した記述が可能(これには賛否両論あるが)。 WordPress/BuddyPress &#8230; <a href="http://presen.php-web.net/2010/buddypress-php/">続きを読む <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<ul>
<li>PHP の特色：HTML と混在可能</li>
<li>WP/BP  のテンプレートも同様</li>
<li>PHP の関数が利用可能</li>
</ul>
<p><span id="more-217"></span><br />
PHP の特色として、HTML と混在した記述が可能(これには賛否両論あるが)。</p>
<p>WordPress/BuddyPress のテンプレートも、PHP の特色を受け継いで、PHP と HTML が利用できるようになっている。このため、PHP の関数をテンプレートで利用することができる。</p>
<p>特定のツールでしか使用できないテンプレートタグを多用するよりも、PHP 機能を利用したほうが汎用性がある。</p>
<p>オリジナルテンプレートタグも、PHP をなるべく利用するようにしている。例えば、WP の投稿の日付は、the_date() で表示するが、これは PHP で現在の日付を表示する関数 date() に the_ を追加すれば良い。また引数で日付の表示形式を設定できるが、PHP に元からある date() と同じ引数が利用可能(記憶の負担が軽減できる)。</p>
]]></content:encoded>
			<wfw:commentRss>http://presen.php-web.net/2010/buddypress-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	<xhtml:link rel="alternate" media="handheld" type="text/html" href="http://presen.php-web.net/2010/buddypress-php/" />
	</item>
	</channel>
</rss>

