<?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/"
	>

<channel>
	<title>Texto.de - Mein WordPress Magazin &#187; WP-CMS</title>
	<atom:link href="http://www.texto.de/category/wp-cms/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.texto.de</link>
	<description>Tutorials zu  WordPress als Blog, WordPress als CMS, WP SEO tauglich machen - einfach ein WP Nachschlagewerk</description>
	<lastBuildDate>Tue, 31 Jan 2012 22:41:38 +0000</lastBuildDate>
	<language>de</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>WordPress als CMS  Mitgliederverwaltung und Community Features &#8211; für Vereine &amp; Co</title>
		<link>http://www.texto.de/wordpress-cms-mitgliederverwaltung-community-features-1287/</link>
		<comments>http://www.texto.de/wordpress-cms-mitgliederverwaltung-community-features-1287/#comments</comments>
		<pubDate>Sat, 01 Oct 2011 19:16:14 +0000</pubDate>
		<dc:creator>texto</dc:creator>
				<category><![CDATA[WP-CMS]]></category>
		<category><![CDATA[User-Verwaltung]]></category>
		<category><![CDATA[wordpress-cms]]></category>
		<category><![CDATA[wordpress-plugins]]></category>

		<guid isPermaLink="false">http://www.texto.de/?p=1287</guid>
		<description><![CDATA[WordPress als CMS für Vereine und alle die eine Community haben wollen.   Mitgliederverwaltung und Community Features.  Hier stelle ich WordPress Plugins vor, die beides ermöglichen. ]]></description>
			<content:encoded><![CDATA[<dl class="left" style="width:260px;">
<dt>&nbsp;</dt>
<dd><img  src="http://www.texto.de/wp-images/1011/wordpress-community-plugins.jpg" alt="WordPress Community" width="250" height="181" /></dd>
</dl>
<p><span class="caplize">I</span>n letzter Zeit wurde ich wieder sehr oft gefragt, ob es eigene WordPress Themes für Vereine gäbe. Als ich dann nachhakte kam raus, man sucht eigentlich nach <strong>Mitgliederverwaltung</strong> und /oder<strong> Community Features</strong>.   Nun ich begab mich auf die Pluginsuche, testete alle Plugins zumindest mal grob auch auf WP 3.3.</p>
<p>Außerdem bin ich mir sicher, dass auch nicht-Vereine, die Community Plugins und Member Plugins von WordPress brauchen könnten&#8230;wollen..damit spekulieren. </p>
<p><strong>WordPress Themes</strong> für diese Community Plugins braucht man keine eigenen. Entweder nutzen sie das vorhanden Theme oder bieten die Möglichkeit das eigene WordPress Theme automatisch so zu verändern, dass alles funktioniert. </p>
<p>Du findest hier zuerst einige Plugins, die der <a href="http://www.texto.de/wordpress-cms-mitgliederverwaltung-community-features-1287/#mitgliederverwaltung" title="Sprunglink zu den Mitgliederverwaltungs Plugins"><strong>Mitgliederverwaltung</strong></a> dienen. Also wer darf was wo machen, wer darf was wo sehen und natürlich INFO wie man die Mitglieder Profile anpassen kann. </p>
<p>Anschließend bringe ich drei WordPress Community Plugins &#8211; <a href="http://www.texto.de/wordpress-cms-mitgliederverwaltung-community-features-1287/#buddypress" title="Sprunglink zu BuddyPress"><strong>BuddyPress</strong> </a>- <a href="http://www.texto.de/wordpress-cms-mitgliederverwaltung-community-features-1287/#symposium" title="Sprunglink zu WP Symposium Social Network"><strong>WP Symposium Social Network</strong></a> &#8211; <a href="http://www.texto.de/wordpress-cms-mitgliederverwaltung-community-features-1287/#mingle" title="Sprunglink zu Mingle"><strong>Mingle</strong></a>. Was sie anbieten, was sie nicht anbieten und wo Du sie auch testend erleben kannst. </p>
<p>Abschließend ein paar <a href="http://www.texto.de/wordpress-cms-mitgliederverwaltung-community-features-1287/#tipps" title="Sprunglink zu Tipps">Tipps</a> von mir wie man das für sich richtige Community Plugin testet, worauf man bei Zusatzmodulen achten sollte  etc. </p>
<p><span id="more-1287"></span></p>
<h3>Mitglieder Verwaltung<a id="mitgliederverwaltung"></a></h3>
<p>WordPress bringt als Standard fünf Benutzerrollen. Was diese können und dürfen findest Du in dem Artikel von mir. => <a href="http://www.texto.de/usermanagement-wordpress-grundlagen-886/" title="User Management in WP">Usermanagement in WP</a>. </p>
<p><strong>Members</strong></p>
<p>Download auf wordpress.org =><a href="http://wordpress.org/extend/plugins/members/" title="Members Plugin">Members</a></p>
<blockquote><p>a) Role Manager: Allows you to edit, create, and delete roles as well as capabilities for these roles.<br />
    b) Content Permissions: Gives you control over which users (by role) ..<br />
&#8230;  u.v.m</p>
<p><cite> Plugin Autor <a href="http://profiles.wordpress.org/users/greenshady/" title="Justin Tadlock">Justin Tadlock</a></cite></p></blockquote>
<p><strong>Member Wishlist</strong></p>
<p> Download  => <a href="http://member.wishlistproducts.com/" title="Member Wishlist">Member Wishlist</a></p>
<p>Dieses Member Plugin dürfte kaum einen Wunsch offen lassen. Ich sag dürfte, weil es ist kostenpflichtig und ich habe es nicht im Einsatz. Was ich nicht fand, war ob es auch in Deutsch erhältlich ist. </p>
<p>Ich habe es hier in der Liste, weil es mit &#8220;Mingle&#8221; einem Community Plugin, das ich auch vorstelle kompatibel ist. </p>
<p><strong>RoleScoper</strong></p>
<p>Download auf wordpress.org => <a href="http://wordpress.org/extend/plugins/role-scoper/" title="RoleScoper">RoleScoper </a></p>
<p>Das Plugin kann soviel, dass ich nur einen Ausschnitt der Features bringe:</p>
<blockquote><p>&#8230;&#8230;..<br />
Supports custom Post Types and Taxonomies (when defined using WP schema ..<br />
Extensive WP-mu support</p>
<p><cite>Plugin Autor K<a href="http://profiles.wordpress.org/users/kevinB/" title="Autor von Role Scoper">evin  B </a></cite></p></blockquote>
<p><strong>Userprofile ergänzen verbessern etc </strong></p>
<p><a href="http://www.texto.de/autoren-und-ihre-profilseite-in-wp-1216/" title="Autoren und ihre Profilseite">Autoren und ihre Profilseite</a>, erst kürzlich schrieb ich darüber.</p>
<hr />
<p><img src="http://www.texto.de/wp-images/2011/10/buddypress-logo.gif" alt="" title="buddypress-logo" width="150" height="34" class="alignleft  size-full wp-image-1291" /><br />
<h3>BuddyPress<a id="buddypress"></a></h3>
<p>Download an wordpress.org => <a href="http://wordpress.org/extend/plugins/buddypress/" title="BuddyPress">BuddyPress </a></p>
<blockquote><p>Social networking in a box. Build a social network for your company, school, sports team or niche community all based on the power and flexibility of WordPress.</p>
<p>BuddyPress ist ein weiters Service der <cite> WP Community </cite>
</p></blockquote>
<p>Live erleben kannst Du BuddyPress<a href="http://buddypress.org/" title="BuddyPress"> hier </a>-Useraccount ist der von wordpress.org.</p>
<p>BuddyPress ist kostenfrei, Support ebenfalls. Es ist immer in Deutsch erhältlich, ob auch jedes Plugin sofort in Deutsch da ist, ist bei der Menge für mich unüberprüfbar <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' />    BuddyPress bietet soviel, dass es aufzuzählen schwierig ist.</p>
<p>Bevor Du wahllos BuddyPress Plugins auswählst oder 10000Listen über die besten BuddyPress Plugins liest, überlege bitte einfach was Du haben magst und dann suche gezielt danach. </p>
<p>Was mir geholfen hat kann bei Deiner Community völlig fehl am Platz sein und umgekehrt. </p>
<p><b>Plugins für BuddyPress </b>findet man<a href="http://wordpress.org/extend/plugins/search.php?q=BuddyPress" title="BuddyPress Plugins"> wordpress.org</a> und unter <a href="http://buddypress.org/extend/plugins/" title="BuddyPress Extend">BuddyPress extend</a>. </p>
<p><b>Supportforum:</b>  im deutschen WP gibts auch das <a href="http://forum.wordpress-deutschland.org/buddypress/" title="BuddyPress">BuddyPress Hilfeforum.</a>.</p>
<p><b>Mitgliederverwaltung </b>dazu gibts ein <a href="http://wordpress.org/extend/plugins/private-buddypress/" title="Privat BuddyPress">eigenes Plugin</a>.</p>
<p><b>Sprachdatei</b>: Diese kann  bei David  Decker  <small>[ <del>Becker</del>]</small> <a href="http://deckerweb.de/material/sprachdateien/wordpress-plugins/#buddypress" title="Sprachdatei">Sprachdatei BBPress  Du und Sie Version</a> heruntergeladen werden. </p>
<hr />
<p><img src="http://www.texto.de/wp-images/2011/10/wp-symposium.png" alt="" title="wp-symposium" width="128" height="122" class="alignleft  size-full wp-image-1289" /><br />
<h3>WP Symposium Social Network<a id="symposium"></a></h3>
<p>Download auf wordpress.org. <a href="http://wordpress.org/extend/plugins/wp-symposium/" title="Social Plugin">WP Symposium Social Network</a></p>
<p>was es verspricht:</p>
<blockquote><p>WP Symposium turns a WordPress website into a Social Network! It is a suite of WordPress plugins including forum, activity (similar to Facebook wall), member directory, private mail, notification bar, chat windows, chat room, profile page, social widgets, activity alerts, RSS activity feeds and support for other plugins such as Groups, Events, Gallery, Facebook Connect and Mobile support!</p>
<p><cite>Plugin Autor: <a href="http://webtechnologysolutions.co.uk/" title="Simon Goodchild">Simon Goodchild</a> </cite></p></blockquote>
<p>Dann gibts das Wiki: <a href="http://www.wpswiki.com/index.php?title=Main_Page" title="Wiki zum Symposium Plugin">WP Symposium Wiki</a>. Mit einer wirklich einfachen Erklärung wie man es das <a href="http://www.wpswiki.com/index.php?title=Setting_up_for_the_first_time" title="Setting up the first time">erste Mal installiert</a>. </p>
<p>Live ansehen und miterleben was es alles kann man man hier in der &#8220;<a href="http://www.wpsymposium.com/" title="Social Community mit Symposium">offiziellen WP Symposium Social Community</a>&#8220;.</p>
<p><b>WP Symposium   mit TwentyTen </b>kann man sich   <a href="http://demo.webtechnologysolutions.co.uk/" title="TwentyTen und Symposium">hier</a> live ansehen. </p>
<p>Das Plugin ist kostenfrei und wer mehr haben möchte, vor allem mehr Support der muss sich bei der offiziellen Seite registrieren und dort gibts zwei Bezahl-Mitgliedschaften, die unterschiedliche Goodies anbieten. </p>
<p><b>Entwickler</b> können sich hier ein Bild der zukünftigen Sachen machen oder Bugs melden. <a href="https://wpsymposium-trac.sourcerepo.com/wpsymposium_trac" title="Trac von WP Symposium">Trac </a></p>
<p><strong>WP Symposium ist eine Ansammlung an Plugins</strong></p>
<p>WP Symposium Forum, WP Symposium Mail, WP Symposium Members Directory, WP Symposium Panel, WP Symposium Profile, WP Symposium Widgets, WP Symposium Social Network &#8230;  und man sollte mal alle aktiveren</p>
<p>In WP 3.3 nightlybuild-dort teste ich grad alle, erscheinen dann alle Optionen gleich unter dem &#8220;Artikel&#8221; Menü. </p>
<p><b>WP Symposium bietet eigne Templates</b></p>
<p>diese kann man im Adminbereich modifizieren. zb den Link zur Pluginseite rausnehmen.</p>
<p><b>Sprachdatei</b> Im Ordner wp-symposium/lang.  Herunterladen kann man Deutsch <a href="http://crowdin.net/project/symposium" title="Sprachdatei Deutsch">hier</a>. Man muss sich anmelden. </p>
<hr />
<p><img src="http://www.texto.de/wp-images/2011/10/mingle_128.png" alt="" title="mingle_128" width="128" height="128" class="alignleft size-full wp-image-1288" /><br />
<h3>Mingle <a id="mingle"></a></h3>
<p>Das Plugin liegt auch auf WordPress.org <a href="http://wordpress.org/extend/plugins/mingle/" title="Mingle Plugin">Mingle Plugin</a> genauso wie alle ZusatzPlugins, die es dafür gibt.</p>
<blockquote><p>Verspricht den einfachsten Weg eine Community für den Verein oder  wie fb oder ähnliches zu gründen.<br />
<cite>Plugin Autor   <a href="http://blairwilliams.com/" title="Blair Williams Pretty Links und Mingle">Blair Williams</a></cite></p></blockquote>
<p>Live ansehen und miterleben wie Mingle funktioniert kann man <a href="http://wpmingle.com/" title="Mingle Community">hier</a>.<br />
ZusatzPlugins für Mingle gibts auch: => <a href="http://wpmingle.com/mingle-plugins/" title="Mingle Plugins">Mingle Module </a>.</p>
<p>Dies gibt wirklich einen guten Einblick was das Plugin kann und was es nicht kann. Ausprobieren, empfehl ich auf alle Fälle.</p>
<p>Noch gibts keine &#8220;PRO-Version&#8221;, also noch ist alles kostenfrei.<br />
Die weitere Entwicklung hängt vermutlich von der Mingle-Community ab, die weltweit noch relativ klein ist. [Downloads: 71,072]</p>
<p><b>Sprachdatei</b>: im Ordner mingle/i18n liegen die Sprachdateien.</p>
<p><b>Mingle ist sicher nicht compatibel</b> </p>
<p>Wer WP Multisites nutzt kann Mingle nicht nutzen. Siehe <a href="http://wpmingle.com/forum/mingle-plugin-forums-group2/support-forum1/mingle-not-compatible-with-wp-3-1-thread649.0/" title="Mingle not compatible with WP Multisite">hier</a>. </p>
<hr />
<h3>Allgemeine Hinweise zu den Community Plugins<a id="tipps"></a></h3>
<p><b>Seiten </b><br />
Fast jedes braucht eigene Seiten, damit es arbeiten kann. Alle, die das brauchen geben dazu gute Auskunft auf der PluginSeite.</p>
<p><b>zum Testen an sich</b><br />
Immer nur ein Community Plugin aktiv haben, sonst gibts Chaos.</p>
<p>Wer mehrere solcher Plugins ausprobiert, sollte für jedes diese Seiten neu machen und den Pluginnamen in den Seitentitel geben, sonst verliert man den Überblick beim Testen. Für den Produktiveinsatz dann andere Seiten erstellen. </p>
<p class="eingerueckt">Man testet so ein Plugin indem man es wirklich von A-Z mal nutzt. Als Admin sieht man andere Sachen wie wenn man sich als Benutzer registriert. Entweder hat man Freunde, die einem da helfen oder man arbeitet mit vielen Browsern, sonst muss man sich ständig aus und einloggen. </p>
<p><b>Deaktivieren </b><br />
Mag man diese Community nicht mehr kann man fast alle Plugins einfach deaktivieren. Die User werden nicht automatisch gelöscht.<br />
Dies ist ein großes Plus, weil man könnt ja von Plugin A auf Plugin B wechseln wollen und tät sonst seine ganzen Mitglieder verlieren.</p>
<p><b>Bezahlanbieter</b><br />
Hat man <b>Bezahlcontent</b> so ist sehr oft nur Paypal im Angebot, manche bieten auch die Möglichkeit andere Bezahlsysteme zu integrieren, doch meist ist dies kostenpflichtig, so man es nicht selbst machen kann. </p>
<p><b>Performance</b></p>
<p>Fast alle Community Plugins brauchen wp_head, sprich sie fügen meist eine irre Anzahl an .js scripts in den html Header. Den Sinn dieser Aktion versteh ich nicht, es ist aber so&#8230;. </p>
<p><b>Up To Date</b></p>
<p>Wie bei jeder Software. Regelmäßig aktualisieren. Zusatzmodule /Plugins nur installieren, wenn auch dabei steht, dass sie mit der verwendeten Software arbeiten.  Schauen, ob die Plugin Autoren auch Support geben und wie alt der ist .. </p>
<h3>Weitere Member Community Plugins </h3>
<p>Wenn Du eines kennst &#8211;  dass du auch verwendest &#8211;  dann bitte schreib es als Kommentare, ich kontrollier auch den Spamordner-versprochen.  </p>
<div class="sign">Ich freu mich,wenn was dabei war.<img src="http://www.texto.de/wp-images/smilies/icon_confused.gif" alt="Kaffeetrinkender Smilie" width="27" height="21" /></div>
<hr /><small>Copyright &copy; 2011<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. Original article:  <a href="http://www.texto.de/wordpress-cms-mitgliederverwaltung-community-features-1287/" >texto.de</a> (Digital Fingerprint:  textoakamts[texto.de])</small><hr />]]></content:encoded>
			<wfw:commentRss>http://www.texto.de/wordpress-cms-mitgliederverwaltung-community-features-1287/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>eigene Quicktags  auch  WP 3.3 sicher</title>
		<link>http://www.texto.de/eigene-quicktags-auch-wp-3-3-sicher-1276/</link>
		<comments>http://www.texto.de/eigene-quicktags-auch-wp-3-3-sicher-1276/#comments</comments>
		<pubDate>Tue, 27 Sep 2011 17:05:25 +0000</pubDate>
		<dc:creator>texto</dc:creator>
				<category><![CDATA[WP-CMS]]></category>
		<category><![CDATA[Content-Präsentation]]></category>
		<category><![CDATA[Editor]]></category>
		<category><![CDATA[shortcodes]]></category>

		<guid isPermaLink="false">http://www.texto.de/?p=1276</guid>
		<description><![CDATA[Wer in WP mit dem HTML Editor arbeitet hat sehr oft eigene Quicktags. Hier eine Methode wie Du diese ohne Plugin erstellen kannst. ]]></description>
			<content:encoded><![CDATA[<dl class="left" style="width:330px;">
<dt> &nbsp;</dt>
<dd><img src="http://www.texto.de/wp-images/0911/quicktags-wordpress.png" alt=" Quicktags in WP selbst erstellen" width="312" height="278" /></dd>
</dl>
<p><span class="caplize">V</span>iele arbeiten mit dem HTML Editor und machten sich eigene Quicktags. Man kann dazu das Plugin vom Frank nehmen ADD-Quicktags, oder aber man entscheidet sich für eine Lösung ohne Plugin.  </p>
<p>Dazu brauchts einen Eintrag in die functions.php, eine custom-quicktags.js Datei und darin natürlich Deine Quicktags.</p>
<p>Auf die Idee brachte mich Scribu als ich nach Lösungen für die Quicktags im kommenden WP 3.3. suchte. <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' />  Und wie immer, ich bin mir sicher es gibt viele Möglichkeiten ohne Plugin, doch ich zeige eben mal eine davon. </p>
<p>Hilfreich ist dabei <a href="http://codex.wordpress.org/Function_Reference/wp_enqueue_script" title="wo enqueue script">wp enqueue script</a>, für alle, die sich näher damit beschäftigen wollen.</p>
<p><span id="more-1276"></span></p>
<h3>Die Quicktags in den Adminbereich holen</h3>
<p>In die <strong>functions.php</strong>:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">//credits to scibu for the idea</span>
<span style="color: #000000; font-weight: bold;">function</span> mts_custom_quicktags<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	wp_enqueue_script<span style="color: #009900;">&#40;</span>
		<span style="color: #0000ff;">'mts_custom_quicktags'</span><span style="color: #339933;">,</span>
		get_template_directory_uri<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'/inc/custom-quicktags.js'</span><span style="color: #339933;">,</span>
		<span style="color: #990000;">array</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'quicktags'</span> <span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
add_action<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'admin_print_scripts'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'mts_custom_quicktags'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p>Diese Funktion teilt WP mit, dass es im Themeordner &#8220;inc&#8221; eine Datei namens <strong>custom-quicktags.js</strong> gibt und es diese bittschön nutzen sollte.</p>
<p>Wenn Du Deine custom-quicktags.js in einen anderen Themeordner gibst, dann den Pfad anpassen.</p>
<h3>Wie erstellt man nun eigene Quicktags</h3>
<p>Ich erstelle die Datei custom-quicktags.js  und darin gab ich meine Quicktags an, zb so:</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;">edButtons[edButtons.length] = new edButton( 'ueberschrifth3', 
'h3', 
'<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">h3</span>&gt;</span>', '<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">h3</span>&gt;</span>', '' );</pre></div></div>

<p>ueberschrifth3  ist die ID des neuen Buttons, h3  der Text auf dem Button und dann eben was er machen sollte.</p>
<p>Auch mein Kaffeesmilie <img src="http://www.texto.de/wp-images/smilies/icon_confused.gif" alt="Kaffeetrinkender Smilie" width="27" height="21" /> wird mir als Quicktag geliefert   und zwar so</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;">edButtons[edButtons.length] = new edButton( 'kaffeesmilie', 
'kaffeesmilie', 
'<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">img</span> <span style="color: #000066;">src</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://www.texto.de/wp-images/smilies/icon_confused.gif&quot;</span> <span style="color: #000066;">alt</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;Kaffeetrinkender Smilie&quot;</span> <span style="color: #000066;">width</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;27&quot;</span> <span style="color: #000066;">height</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;21&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span>', '', '' );</pre></div></div>

<p>Magst Du einen vorhandenen Quicktag überschreiben musst Du dessen ID wissen und dann einfach Deine Angaben in dieser custom-quicktags.js dazu machen. </p>
<div class="sign">Viel Spaß! <img src="http://www.texto.de/wp-images/smilies/icon_confused.gif" alt="Kaffeetrinkender Smilie" width="27" height="21" /></div>
<hr /><small>Copyright &copy; 2011<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. Original article:  <a href="http://www.texto.de/eigene-quicktags-auch-wp-3-3-sicher-1276/" >texto.de</a> (Digital Fingerprint:  textoakamts[texto.de])</small><hr />]]></content:encoded>
			<wfw:commentRss>http://www.texto.de/eigene-quicktags-auch-wp-3-3-sicher-1276/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
		</item>
		<item>
		<title>[simple]  Artikel in Zeitungs-Spalten aufteilen</title>
		<link>http://www.texto.de/simple-artikel-in-zeitungs-spalten-aufteilen-1274/</link>
		<comments>http://www.texto.de/simple-artikel-in-zeitungs-spalten-aufteilen-1274/#comments</comments>
		<pubDate>Mon, 26 Sep 2011 19:26:54 +0000</pubDate>
		<dc:creator>texto</dc:creator>
				<category><![CDATA[WP-CMS]]></category>
		<category><![CDATA[Content-Präsentation]]></category>
		<category><![CDATA[shortcodes]]></category>

		<guid isPermaLink="false">http://www.texto.de/?p=1274</guid>
		<description><![CDATA[Den ganzen Artikel von WordPress  oder Teile des Artikels in Spalten aufteilen. Ganz einfach mit Shortcodes als Hilfe. ]]></description>
			<content:encoded><![CDATA[<dl class="left" style="width:360px;">
<dt> &nbsp;</dt>
<dd><img src="http://www.texto.de/wp-images/0911/text-spalten-wordpress.jpg" alt=" Text in Spalten aufteilen-Zeitungsspalten in WP" width="350" height="193" /></dd>
</dl>
<p><span class="caplize">M</span>ag man immer oder nur hie und da den Inhalt eines Artikels in Spalten aufteilen- so wie Zeitungsspalten &#8211;  so gibts deren sicher viele Möglichkeiten. Eine davon mag ich hier aufzeigen.  Ich kam auf die Idee als ich die Tage sehr viele <strong>Shortcodes </strong>geschrieben habe. Shortcodes sind für dies insofern nützlich, weil man den Output einfach in der <strong>functions.php</strong> ändert und schon passen sich die vorhandenen Spalten an das etwaig neue WP Thema an.  Hat man nämlich das für die Spalten nötige html direkt in den Artikel geschrieben wird eine spätere Anpassung an ein anderes Theme sehr kompliziert. </p>
<p>Diese Shortcodes kann man  entweder als Quicktags oder mit dem WP Plugin TinyMCE Advanced zur Verfügung stellen.</p>
<h3>Ein Spalten Text Beispiel </h3>

<div class="column normal">Du erstellst zuerst die Shortcodes in der functions.php. Dann fügst Du das nötige CSS in die style.css. </p>
<p>Wie Du eigene Quicktags erstellen kannst, werde ich in einen der kommenden Artikel hier zeigen, daher wäre es günstig das <a href="http://www.texto.de/feed/" title="mein RSS Feed hier ">Feed</a> ins ABO zu nehmen. So Du dies noch nicht gemacht hast.</div>


<div class="column last">Hast Du Quicktags markierst Du den ganzen Text, der in die erste Spalte sollte und klickst auf den Button &#8220;column&#8221;. Danach markierst Du den restlichen Text und klickst auf den Button &#8220;column_last&#8221;. Nun speicherst Du den Artikel und siehst Dir in der Vorschau an, ob die Spalten so aussehen wie Du sie haben magst. Wenn nicht jongliere mit dem Text ein wenig <img src='http://www.texto.de/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' />  </div>
<br class="clear" />
<p><span id="more-1274"></span></p>
<h3>Shortcodes in die functions.php</h3>
<p>Öffen die functions.php Deines Themes und dort wo Du es wiederfindest gib folgenden Code hinein.</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">&nbsp;
<span style="color: #666666; font-style: italic;">//content columns</span>
<span style="color: #000000; font-weight: bold;">function</span> column<span style="color: #009900;">&#40;</span><span style="color: #000088;">$atts</span><span style="color: #339933;">,</span> <span style="color: #000088;">$content</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">null</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #b1b100;">return</span> <span style="color: #0000ff;">'
&lt;div class=&quot;column normal&quot;&gt;'</span><span style="color: #339933;">.</span><span style="color: #000088;">$content</span><span style="color: #339933;">.</span><span style="color: #0000ff;">'&lt;/div&gt;
'</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
add_shortcode<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'column'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'column'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">function</span> column_last<span style="color: #009900;">&#40;</span><span style="color: #000088;">$atts</span><span style="color: #339933;">,</span> <span style="color: #000088;">$content</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">null</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	<span style="color: #b1b100;">return</span> <span style="color: #0000ff;">'
&lt;div class=&quot;column last&quot;&gt;'</span><span style="color: #339933;">.</span><span style="color: #000088;">$content</span><span style="color: #339933;">.</span><span style="color: #0000ff;">'&lt;/div&gt;
&lt;br class=&quot;clear&quot; /&gt;'</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
add_shortcode<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'column_last'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'column_last'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p>Nun gibts zwei neue Shortcodes in Deinem WP. [column] Dein Text&#8230;.  [/column]  und für die zweite Spalte  [column_last] Der andere Text [/column_last]</p>
<h3>das HTML der Shortcodes </h3>
<p>Es ist oben ersichtlich, doch der Vollständigkeit halber hier nochmals extra:</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;">&nbsp;
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;column normal&quot;</span>&gt;</span>  Erste Spalte <span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;column last&quot;</span>&gt;</span> Zweite Spalte <span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">br</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;clear&quot;</span> <span style="color: #66cc66;">/</span>&gt;</span></pre></div></div>

<p>Das zusätzliche MarkUp mag nicht die absolut perfekteste HTML Schule sein, doch es ist Crossbrowser sicher. Und unabhängig davon, Du kannst dieses HTML  Deinen Bedürfnissen anpassen. </p>
<p>Änderst Du also irgendwann Dein Theme kannst Du diese Shortcodes wieder in dessen functions.php schreiben und dort den HTML Output anpassen.  Das ist das fantastische an Shortcodes. </p>
<p>Auf das CSS   nicht vergessen. </p>
<h3>das CSS für diese Spalten</h3>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;"><span style="color: #6666ff;">.column</span><span style="color: #00AA00;">,</span> <span style="color: #6666ff;">.column-last</span> <span style="color: #00AA00;">&#123;</span><span style="color: #000000; font-weight: bold;">float</span><span style="color: #00AA00;">:</span><span style="color: #000000; font-weight: bold;">left</span><span style="color: #00AA00;">;</span>width<span style="color: #00AA00;">:</span><span style="color: #933;">47%</span><span style="color: #00AA00;">;</span><span style="color: #00AA00;">&#125;</span>
.<span style="color: #993333;">normal</span><span style="color: #00AA00;">&#123;</span><span style="color: #000000; font-weight: bold;">margin</span><span style="color: #00AA00;">:</span><span style="color: #933;">10px</span>  <span style="color: #933;">2%</span> <span style="color: #933;">10px</span> <span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span> <span style="color: #00AA00;">&#125;</span>
<span style="color: #6666ff;">.last</span> <span style="color: #00AA00;">&#123;</span><span style="color: #000000; font-weight: bold;">margin</span><span style="color: #00AA00;">:</span><span style="color: #933;">10px</span>  <span style="color: #cc66cc;">0</span> <span style="color: #933;">10px</span> <span style="color: #cc66cc;">0</span><span style="color: #00AA00;">;</span><span style="color: #00AA00;">&#125;</span>
.<span style="color: #000000; font-weight: bold;">clear</span><span style="color: #00AA00;">&#123;</span><span style="color: #000000; font-weight: bold;">clear</span><span style="color: #00AA00;">:</span><span style="color: #993333;">both</span><span style="color: #00AA00;">;</span><span style="color: #00AA00;">&#125;</span></pre></div></div>

<p>Du kannst auf diese Art natürlich auch 3-oder 4spaltiges Zeitungslayout in einem Artikel erstellen. </p>
<p>Ich wünsch viel Spaß beim Erkennen der Möglichkeiten, beim Nutzen und Erobern der Shortcodes für Dich.</p>
<div class="sign"><img src="http://www.texto.de/wp-images/smilies/icon_confused.gif" alt="Kaffeetrinkender Smilie" width="27" height="21" /></div>
<hr /><small>Copyright &copy; 2011<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. Original article:  <a href="http://www.texto.de/simple-artikel-in-zeitungs-spalten-aufteilen-1274/" >texto.de</a> (Digital Fingerprint:  textoakamts[texto.de])</small><hr />]]></content:encoded>
			<wfw:commentRss>http://www.texto.de/simple-artikel-in-zeitungs-spalten-aufteilen-1274/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Praxis: Sidebar für eine bestimmte Kategorie</title>
		<link>http://www.texto.de/praxis-sidebar-fuer-eine-bestimmte-kategorie-1264/</link>
		<comments>http://www.texto.de/praxis-sidebar-fuer-eine-bestimmte-kategorie-1264/#comments</comments>
		<pubDate>Wed, 21 Sep 2011 23:21:21 +0000</pubDate>
		<dc:creator>texto</dc:creator>
				<category><![CDATA[WP-CMS]]></category>
		<category><![CDATA[sidebar]]></category>
		<category><![CDATA[template]]></category>
		<category><![CDATA[WordPress Theme]]></category>

		<guid isPermaLink="false">http://www.texto.de/?p=1264</guid>
		<description><![CDATA[Eine Sidebar mit ganz eigenen Widgets  für eine ganz bestimmte Kategorie. Wie geht man dabei in WordPress   vor, was sollte man beachten. ]]></description>
			<content:encoded><![CDATA[<dl class="left" style="width:260px;">
<dt>&nbsp;</dt>
<dd><img  src="http://www.texto.de/wp-images/wordpress-cms-komplexe-projekte.jpg" alt="WP  Praxis eine Sidebar für eine Kategorie" width="250" height="250" /></dd>
</dl>
<p><span class="caplize">W</span>ie geht man vor, um für eine bestimmte Kategorie eine anders gestaltete/aufgebaute (auch mit Widgets bestückte) Sidebar aufzurufen? &#8211; Dies wurde ich per E-mail gefragt.  Ich zeige hier in diesem Artikel einen Weg auf. Doch wie immer gilt, es gibt ganz viele Wege nach Rom <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> . Kommt drauf an was man schlussendlich wirklich alles braucht. </p>
<p>Wenn solche Arbeitsschritte erklärt werden liest sich dies meist langsamer als es dann gemacht wird. Und ich versuche immer sehr genau zu erklären, so dass Du dies wirklich 1:1 nachmachen kannst. </p>
<h3>Was man dazu braucht:</h3>
<ul>
<li>Einen Texteditor (WordPad ist keiner)
</li>
<li>die category.php oder archive.php des verwendeten Themes.
</li>
<li>den &#8220;Category Slug&#8221; der gewählten Kategorie.
</li>
<li>die sidebar.php.
</li>
<li>die functions.php um dort neue Widgets einzutragen und für ein paar neue Funktionen.
</li>
</ul>
<p><span id="more-1264"></span></p>
<h3>das neue Template category-slug.php erstellen</h3>
<p>Um die Übersicht in dem ThemeOrdner zu bewahren ist es günstig für solche Aktionen wirklich ein eigenes <strong>category-slug.php </strong>Template zu erstellen.</p>
<p>Einfach die category.php, wenn die nicht da ist im ThemeOrdner, dann die archive.php öffnen und als category-slug.php abspeichern.</p>
<p>Den &#8220;Slug&#8221; einer Kategorie findest Du entweder in der URL, oder <strong>Dashboard ==> Artikeln==>Kategorie==> Titelform</strong>.</p>
<p>WordPress erkennt solche Templates von sich aus, dies habe ich mal <a href="http://www.texto.de/update-cheat-cheet-wp-template-hierarchie-909/" title="Template Hierarchy">hier</a> beschrieben. </p>
<h3>das neue Template sidebar-categoryslug.php</h3>
<p>Ebenfalls der Übersicht wegen ist es günstig, die neue Sidebar unter dem &#8220;Slug&#8221; /Titelform dieser Kategorie abzuspeichern.</p>
<p>Also sidebar.php öffnen und als sidebar-categoryslug.php abspeichern.<br />
WordPress erkennt dieses Template (noch) nicht von selbst, aber es erleichtert ungemein den Durchblick <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<h3>category-slug.php und sidebar-categoryslug.php bekanntmachen</h3>
<p>Naja mir fiel da jetzt wirklich keine andere Überschrift ein, aber die category-slug.php weiß noch nicht, dass sie die neue Sidebar sidebar-categoryslug.php  herzeigen sollte, also muss man es ihr sagen. <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>Ganz am Ende der category-slug.php steht sicher:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">&nbsp;
get_sidebar<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p>Steht dies nicht dort, dann ist dieses Theme sicher ein eigenes Framework und ich tät dann davon abraten dies zu tun, außer man kennt sich in PHP gut aus => oder man fragt die ThemeErsteller. </p>
<p>Aber findest Du dort get_sidebar dann kann man WP sagen, dass es da eine spezielle Sidebar gibt:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">&nbsp;
get_sidebar<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'categorslug'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p>Nun sucht WP nach einem Template das sidebar-categoryslug heißt und nimmt es. </p>
<p>Ab jetzt kann man in dieser Sidebar anzeigen was auch immer man mag, es wird nur für diese Kategorie genommen. </p>
<h3>functions.php neue Widgets erstellen</h3>
<p>Meist stehen in der functions.php bereits Widgets, dort findet man dann auch wie das HTML für dieses Theme dort angeben ist. Ich nehm hier Beispiele aus TwentyTen Eleven.</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">register_sidebar<span style="color: #009900;">&#40;</span> <span style="color: #990000;">array</span><span style="color: #009900;">&#40;</span>
<span style="color: #0000ff;">'name'</span> <span style="color: #339933;">=&gt;</span> __<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'CategorySlugKATS'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'twentyeleven'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span>
<span style="color: #0000ff;">'id'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'sidebar-8'</span><span style="color: #339933;">,</span>
<span style="color: #0000ff;">'description'</span> <span style="color: #339933;">=&gt;</span> __<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'The sidebar for the special Category CategorySlug'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'twentyeleven'</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span>
<span style="color: #0000ff;">'before_widget'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'&lt;aside id=&quot;%1$s&quot; class=&quot;widget %2$s&quot;&gt;'</span><span style="color: #339933;">,</span>
<span style="color: #0000ff;">'after_widget'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">&quot;&lt;/aside&gt;&quot;</span><span style="color: #339933;">,</span>
<span style="color: #0000ff;">'before_title'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'&lt;h3 class=&quot;widget-title&quot;&gt;'</span><span style="color: #339933;">,</span>
<span style="color: #0000ff;">'after_title'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'&lt;/h3&gt;'</span><span style="color: #339933;">,</span>
<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p>Dies in die functions.php kopieren und dort sooft kopieren wie Du Widgets brauchst. name, id und description ändern, so dass es für Dich gut verständlich ist wofür dieses Widget da ist. <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /><br />
Sollte in der functions.php bereits ein Widget mit der ID 8 sein, dann logischerweise bitte eine andere nehmen. IDs kann es immer nur eine geben <img src='http://www.texto.de/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>Widget1 oder Widget3 ist ganz nett, aber sagt Null, Nade Nix aus und spätestens nach 3 Monaten fragt man sich was das da soll.</p>
<h3>Widgets erstellt und nun in der sidebar-categoryslug.php abrufen.</h3>
<p>In der sidebar-categoryslug.php stehen vielleicht schon Widgets. Keine Ahnung, wenn dann löschen und durch das ersetzen.</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">&nbsp;
<span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span> <span style="color: #339933;">!</span> dynamic_sidebar<span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'sidebar-8'</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span> <span style="color: #339933;">:</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
&nbsp;
&nbsp;
<span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">endif</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// end sidebar widget area  ID 8 ?&gt;</span></pre></div></div>

<p>sidebar-8 => die ID (!)</p>
<p>Hast du für diese Sidebar mehrere solche Widgets &#8220;Flächen&#8221; erstellt, dann eben sooft wiederholen wie nötig und die IDs anpassen. </p>
<p>Alle Templates   hochladen. Unter <strong>Dashboard=> Design=>Widgets </strong>diese befüllen und fertig biste.</p>
<h3>Haben nun auch alle Artikel dieser Kategorie diese Sidebar</h3>
<p>Nein.</p>
<p>Diese Sidebar wird aber nur in der Kategorie genommen. Sie erscheint noch nicht bei den Artikeln in dieser Kategorie.</p>
<p>Das aber wird ein nächster Artikel unter dem Stichwort: aus der Praxis&#8230;.., weil sonst wirds wirklich zulang. </p>
<div class="sign">Hast Du Fragen dazu einfach fragen bitte.   <img src="http://www.texto.de/wp-images/smilies/icon_confused.gif" alt="Kaffeetrinkender Smilie" width="27" height="21" /></div>
<hr /><small>Copyright &copy; 2011<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. Original article:  <a href="http://www.texto.de/praxis-sidebar-fuer-eine-bestimmte-kategorie-1264/" >texto.de</a> (Digital Fingerprint:  textoakamts[texto.de])</small><hr />]]></content:encoded>
			<wfw:commentRss>http://www.texto.de/praxis-sidebar-fuer-eine-bestimmte-kategorie-1264/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
		<item>
		<title>3 Möglichkeiten für in_category außerhalb des Loops</title>
		<link>http://www.texto.de/in_category-ausserhalb-des-loops-nutzen-421/</link>
		<comments>http://www.texto.de/in_category-ausserhalb-des-loops-nutzen-421/#comments</comments>
		<pubDate>Fri, 16 Sep 2011 07:20:24 +0000</pubDate>
		<dc:creator>texto</dc:creator>
				<category><![CDATA[WP-CMS]]></category>
		<category><![CDATA[conditional-tags]]></category>
		<category><![CDATA[template]]></category>
		<category><![CDATA[wordpress-cms]]></category>

		<guid isPermaLink="false">http://www.texto.de/?p=421</guid>
		<description><![CDATA[Du magst, dass etwas ganz bestimmtes nur dann erscheint, wenn der Beitrag in einer bestimmten Kategorie ist. Dazu brauchst Du in_category.  Und zwei  neue Funktionen  in_category_extend und is_in_category, die die Verwaltung hochkomplexer Projekte erleichtern. ]]></description>
			<content:encoded><![CDATA[<dl class="left" style="width:260px;">
<dt>WP CMS komplexe Projekte</dt>
<dd><img  src="http://www.texto.de/wp-images/wordpress-cms-komplexe-projekte.jpg" alt="WP CMS einfache L&ouml;sungen f&uuml;r komplexe Projekte" width="250" height="250" /></dd>
</dl>
<p><span class="caplize"> I</span>ch wurde gefragt wie man <strong>in_category</strong> auch außerhalb des Loops nutzen kann. Meist braucht man dies in der Sidebar oder man mag ganz spezielle meta tags im html Header anzeigen. Oder man mag im Footer, also den sichtbaren Footer einer Website, was spezielles anzeigen. Oder man braucht dies für eine ganz spezielle Navigation. Oder&#8230; ?</p>
<p>Ich nutze  dafür drei Möglichkeiten:</p>
<ul>
<li><a href="http://www.texto.de/in_category-ausserhalb-des-loops-nutzen-421/#query_post" title="Sprunglink zur Funktion query post">query post</a>.
</li>
<li>für komplexere Projekte <a href="http://www.texto.de/in_category-ausserhalb-des-loops-nutzen-421/#in_category_extend" title="Sprunglink zur Funktion in_category_extend">in_category_extend</a> .
</li>
<li>und <a href="http://www.texto.de/in_category-ausserhalb-des-loops-nutzen-421/#is_in_category" title="Sprunglink zur Funktion is_in_category">is_in_category</a>.
</li>
</ul>
<p><span id="more-421"></span></p>
<h3>in_category mit query post außerhalb des Loops nutzen<a id="query_post"></a></h3>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
 <span style="color: #000088;">$post</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$wp_query</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">post</span><span style="color: #339933;">;</span>
 <span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span> in_category<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'29'</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>  <span style="color: #000000; font-weight: bold;">?&gt;</span>
&lt;h3&gt;wenn ich category 20 zeige dies&lt;/h3&gt;
&nbsp;
<span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">elseif</span> <span style="color: #009900;">&#40;</span> in_category<span style="color: #009900;">&#40;</span> <span style="color: #990000;">array</span><span style="color: #009900;">&#40;</span> <span style="color: #0000ff;">'Wir sind die Besten'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'kleine-funktionen'</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
&lt;h3&gt;Wenn in  Wir sind die Besten oder in der Cat kleine-funktionen liest du dieses&lt;/h3&gt;
<span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #009900;">&#125;</span> <span style="color: #b1b100;">else</span> <span style="color: #009900;">&#123;</span>  <span style="color: #000000; font-weight: bold;">?&gt;</span>
&lt;h3&gt;Sonst zeige jenes&lt;/h3&gt;
<span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #009900;">&#125;</span><span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>Dies hat den Vorteil es geht schnell und man muss sich nur die ID der Category, den Namen oder den Slug der Kategorien holen.<br />
Es hat den Nachteil, dass es relativ viel Code ist für so manches Projekt ist, weil diese Funktion beinhart ist: sie nimmt nur die angegebenen Kategorien, also &#8220;wirkt&#8221; nicht automatisch auch bei Unterkategorien. </p>
<h3>in_category bei komplexen Projekten mit WordPress</h3>
<p>zb Auf der Domain <a href="http://gesund.co.at/" title="Gesundheitsportal als Beispiel für ein komplexes Projekt">gesund.co.at</a> gibt es mehrere Hauptkategorien und jede Menge an Unterkategorien. Werbung soll in Abhängigkeit zur jeweiligen Hauptkategorie und ihrer Unterkategorien dargestellt werden und zwar auch in der Einzelansicht der jeweiligen Artikel.</p>
<p>Dies ist ein klassischer Fall für &#8220;<strong>in_category</strong>&#8220;. Aber sehr oft wird dies außerhalb jedweden Loops gebraucht und ich wollte mir die Übersicht in den Templates bewahren,und nicht bei jeder Nutzung von in_category elends Listen der Unterkategorien anführen müssen. <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' />   </p>
<p>So suchte ich nach Lösungen und fand diese in der Funktion <strong>in_category_extend</strong> bei <a href="http://www.sycha.com/wordpress-function-in-category-extended" title="Charlie Evans in_category_extend">Charlie Evans</a>.</p>
<h3>in_category_extend<a id="in_category_extend"></a></h3>
<p>Diese Funktion kommt in die <strong>functions.php</strong>.</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #666666; font-style: italic;">//credits to charlie evans</span>
<span style="color: #000000; font-weight: bold;">function</span> in_category_extended<span style="color: #009900;">&#40;</span><span style="color: #000088;">$category</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
&nbsp;
	<span style="color: #666666; font-style: italic;">// easy out</span>
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span><span style="color: #009900;">&#40;</span>is_category<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> or is_single<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #b1b100;">return</span> <span style="color: #009900; font-weight: bold;">false</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #666666; font-style: italic;">// retrieve specified category (ID or slug)</span>
	<span style="color: #000088;">$obj_specified_category</span> <span style="color: #339933;">=</span> <span style="color: #990000;">is_numeric</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$category</span><span style="color: #009900;">&#41;</span> ? get_category<span style="color: #009900;">&#40;</span><span style="color: #000088;">$category</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">:</span> get_category_by_slug<span style="color: #009900;">&#40;</span><span style="color: #000088;">$category</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #990000;">empty</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$obj_specified_category</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">cat_ID</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #b1b100;">return</span> <span style="color: #009900; font-weight: bold;">false</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #666666; font-style: italic;">// we're viewing a category</span>
	<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span>is_category<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$current_category_ID</span> <span style="color: #339933;">=</span> get_query_var<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'cat'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #b1b100;">return</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$obj_specified_category</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">cat_ID</span> <span style="color: #339933;">==</span> <span style="color: #000088;">$current_category_ID</span> or cat_is_ancestor_of<span style="color: #009900;">&#40;</span><span style="color: #000088;">$obj_specified_category</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">cat_ID</span><span style="color: #339933;">,</span><span style="color: #000088;">$current_category_ID</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
&nbsp;
	<span style="color: #666666; font-style: italic;">// we're viewing a post</span>
	<span style="color: #b1b100;">else</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$wp_query</span><span style="color: #339933;">;</span>
		<span style="color: #000088;">$obj_post</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$wp_query</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">get_queried_object</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #990000;">empty</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$obj_post</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">ID</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #b1b100;">return</span> <span style="color: #009900; font-weight: bold;">false</span><span style="color: #339933;">;</span> 
&nbsp;
		<span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span>in_category<span style="color: #009900;">&#40;</span><span style="color: #000088;">$obj_specified_category</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">cat_ID</span><span style="color: #339933;">,</span> <span style="color: #000088;">$obj_post</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">ID</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #b1b100;">return</span> <span style="color: #009900; font-weight: bold;">true</span><span style="color: #339933;">;</span>
		<span style="color: #b1b100;">else</span> <span style="color: #b1b100;">return</span> in_category<span style="color: #009900;">&#40;</span>get_term_children<span style="color: #009900;">&#40;</span><span style="color: #000088;">$obj_specified_category</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">cat_ID</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'category'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span> <span style="color: #000088;">$obj_post</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">ID</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<p>Diese Funktion erweitert in_category derart, dass es auch die Unterkategorien miteinbezieht.</p>
<h3>in_category_extend im Template</h3>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"> <span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span>in_category_extended<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'fitness-beauty'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>  
<span style="color: #b1b100;">echo</span><span style="color: #0000ff;">'&lt;p&gt;Deine Angaben......&lt;/p&gt;'</span><span style="color: #339933;">;</span>
 <span style="color: #009900;">&#125;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>Damit war es aber bei dem Projekt gesund.co.at nicht getan. Manches sollte zwar in Abhängigkeit zu einer Hauptkategorie angezeigt werden, aber nicht in jeder Unterkategorie dieser Hauptkategorie. Da wirds mit query post und category_not_in auch irgendwann ziemlich kompliziert. Vor allem, weil dies innerhalb etlicher category.php und single.php zu tun wäre.</p>
<h3>is_in_category war dafür die Lösung.<a id="is_in_category"></a> </h3>
<p>Dies kommt in die <strong>functions.php</strong>.</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">function</span> is_in_category<span style="color: #009900;">&#40;</span> <span style="color: #009900;">&#41;</span>
<span style="color: #009900;">&#123;</span>
        <span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span> <span style="color: #990000;">func_num_args</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">&gt;</span> <span style="color: #cc66cc;">0</span> <span style="color: #009900;">&#41;</span>
        <span style="color: #009900;">&#123;</span>
                <span style="color: #b1b100;">foreach</span><span style="color: #009900;">&#40;</span> <span style="color: #990000;">func_get_args</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$category</span> <span style="color: #009900;">&#41;</span>
                <span style="color: #009900;">&#123;</span>
                        <span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span> in_category<span style="color: #009900;">&#40;</span> <span style="color: #000088;">$category</span> <span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span>
                        <span style="color: #009900;">&#123;</span>
                                <span style="color: #b1b100;">return</span><span style="color: #009900;">&#40;</span> <span style="color: #009900; font-weight: bold;">true</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
                        <span style="color: #009900;">&#125;</span>
                <span style="color: #009900;">&#125;</span>
        <span style="color: #009900;">&#125;</span>
        <span style="color: #b1b100;">return</span><span style="color: #009900;">&#40;</span> <span style="color: #009900; font-weight: bold;">false</span> <span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<p>Hier wird quasi in_category mit einer Variable bestückt. Sinnvoll ist es dieser Variable einen für die jeweilige Funktion sinnvollen Namen zu geben. Im array der Variable werden die IDs der Kategorien in aufsteigender Reihenfolge angeführt.</p>
<p>Somit kommen in die functions.php gleich unterhalb der Funktion is_in_category die Variablen mit den IDs.</p>
<p>Beispiel- die IDs sind Fantasieziffern <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000088;">$fitness</span> <span style="color: #339933;">=</span> <span style="color: #990000;">array</span> <span style="color: #009900;">&#40;</span><span style="color: #cc66cc;">4</span><span style="color: #339933;">,</span><span style="color: #cc66cc;">6</span><span style="color: #339933;">,</span><span style="color: #cc66cc;">7</span><span style="color: #339933;">,</span><span style="color: #cc66cc;">8</span><span style="color: #339933;">,</span><span style="color: #cc66cc;">9</span><span style="color: #339933;">,</span><span style="color: #cc66cc;">12345</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<h3>is_in_category im Template </h3>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"> <span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span>is_in_category<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'$fitness'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>  
<span style="color: #b1b100;">echo</span><span style="color: #0000ff;">'&lt;p&gt;Deine Angaben......&lt;/p&gt;'</span><span style="color: #339933;">;</span>
 <span style="color: #009900;">&#125;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>Gibt es nun eine Änderung, also sollte auf einmal doch noch die Kategorie &#8220;ichbinneu&#8221; dazukommen und &#8220;ichbinalt&#8221; rausgenommen werden, muss man diese Änderung nur in der functions.php machen. </p>
<p>Dies bringt eine sehr große Zeitersparnis, guten Überblick und eine Reduktion der Fehler mit sich. Man könnt ja bei einer Änderung irgendwo einen Aufruf vergessen.  <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<div class="sign">bei dem Projekt gesund.co.at brauchte ich deren viele => <img src="http://www.texto.de/wp-images/smilies/icon_confused.gif" alt="Kaffeetrinkender Smilie" width="27" height="21" /> <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' />  </div>
<hr /><small>Copyright &copy; 2011<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. Original article:  <a href="http://www.texto.de/in_category-ausserhalb-des-loops-nutzen-421/" >texto.de</a> (Digital Fingerprint:  textoakamts[texto.de])</small><hr />]]></content:encoded>
			<wfw:commentRss>http://www.texto.de/in_category-ausserhalb-des-loops-nutzen-421/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>WP Loop: Teaserartikel-andere Artikel ohne Teaser aber Weiterblättern</title>
		<link>http://www.texto.de/wp-loop-teaserartikel-andere-artikel-ohne-teaser-aber-weiterblaettern-1247/</link>
		<comments>http://www.texto.de/wp-loop-teaserartikel-andere-artikel-ohne-teaser-aber-weiterblaettern-1247/#comments</comments>
		<pubDate>Thu, 15 Sep 2011 17:49:15 +0000</pubDate>
		<dc:creator>texto</dc:creator>
				<category><![CDATA[WP-CMS]]></category>
		<category><![CDATA[loop]]></category>
		<category><![CDATA[template]]></category>
		<category><![CDATA[wordpress-cms]]></category>

		<guid isPermaLink="false">http://www.texto.de/?p=1247</guid>
		<description><![CDATA[Loop in Aktion: Teaserartikel in WordPress erstellen, die folgenden Artikeln ohne Teaserartikel, aber Pagination also Weiterblättern soll weiterhin möglich sein. ]]></description>
			<content:encoded><![CDATA[<dl class="left" style="width:260px;">
<dt>WP Loop</dt>
<dd><img  src="http://www.texto.de/wp-images/loop-wordpress-mts.gif" alt="WordPress Loop in Action viele Beispiele" width="250" height="250" /></dd>
</dl>
<p>Michael von  <a href="http://www.simtimes.de/" title="Simtimes">SimTimes</a> fragte mich via Email: &#8220;Ich möchte den ersten Artikel meines Loops als Teaser-Artikel ausgeben. Aber das Weiterblättern funktioniert dann nicht mehr &#8211; hast Du eine Lösung?&#8221;.</p>
<p>Es gibt dafür jede Menge an Lösungen, ich zeige hier eine, wer weitere Lösungen weiß bitte in die Kommentare schreiben <img src='http://www.texto.de/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p>Auf Nachfrage erklärte mir Michael, dass sein Teaser Artikel einfach der zuletzt geschriebene Artikel ist. Gesucht hat er hier auf der Texto nach &#8220;first post&#8221;. <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p><span id="more-1247"></span></p>
<p>Ich bringe hier nur die Angaben für die Queries, aber nicht die Darstellung der Artikel. Da steht dann einfach im Code<br />
&lt;!-  -your stuff-  -&gt; Dies ist all das   was normalerweise nach &#8220;while have post the post&#8221; und vor &#8220;endwhile&#8221; steht.</p>
<h3>Loop für den Teaser Artikel</h3>
<p>Alles was jetzt kommt ersetzt  &#8220;if have post while have post the post&#8221;  => und das nachfolgende &#8220;endwhile else endif&#8221; =><br />
also es wird ein komplett neues Template erstellt (! ).</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">&nbsp;
<span style="color: #000000; font-weight: bold;">&lt;?php</span> get_header<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">&lt;?php</span>    
<span style="color: #000088;">$temp</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$wp_query</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$wp_query</span><span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">null</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$wp_query</span> <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> WP_Query<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$wp_query</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">query</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'showposts=1'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$do_not_duplicate</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$post</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">ID</span><span style="color: #339933;">;</span><span style="color: #000000; font-weight: bold;">?&gt;</span>
&lt;h1&gt;Deine Überschrift oder Du läßt dies hier einfach weg&lt;/h1&gt;
&nbsp;
<span style="color: #000000; font-weight: bold;">&lt;?php</span>  <span style="color: #b1b100;">while</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$wp_query</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">have_posts</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">:</span> <span style="color: #000088;">$wp_query</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">the_post</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
&nbsp;
&lt;!--your stuff--&gt; 
&nbsp;
<span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">endwhile</span><span style="color: #339933;">;</span><span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>showposts=1 => selbsterklärend, zeige 1 Artikel, magst Du mehrere, die Ziffer ändern.<br />
do not duplicate =>sagt WP, pass auf merk Dir diese ID, die darfst Du nämlich später nicht mehr zeigen <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<h3>Loop für die nachfolgenden Artikel ohne den 1. und mit Pagination</h3>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>    
<span style="color: #000088;">$temp</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$wp_query</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$wp_query</span><span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">null</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$wp_query</span> <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> WP_Query<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$wp_query</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">query</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'showposts=10&amp;paged='</span><span style="color: #339933;">.</span><span style="color: #000088;">$paged</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span>
&lt;h1&gt;Deine Überschrift oder Du läßt dies hier einfach weg&lt;/h1&gt;
&nbsp;
<span style="color: #000000; font-weight: bold;">&lt;?php</span>  <span style="color: #b1b100;">while</span> <span style="color: #009900;">&#40;</span><span style="color: #000088;">$wp_query</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">have_posts</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">:</span> <span style="color: #000088;">$wp_query</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">the_post</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
 <span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span> <span style="color: #000088;">$post</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">ID</span> <span style="color: #339933;">==</span> <span style="color: #000088;">$do_not_duplicate</span> <span style="color: #009900;">&#41;</span> <span style="color: #b1b100;">continue</span><span style="color: #339933;">;</span> update_post_caches<span style="color: #009900;">&#40;</span><span style="color: #000088;">$posts</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
&nbsp;
&lt;!--your stuff--&gt; 
&nbsp;
<span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">endwhile</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
&nbsp;
&lt;!--code für das Weiterblättern next page previous page oder ein Plugincode--&gt;
&nbsp;
&nbsp;
<span style="color: #000000; font-weight: bold;">&lt;?php</span>  <span style="color: #000088;">$wp_query</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">null</span><span style="color: #339933;">;</span> <span style="color: #000088;">$wp_query</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$temp</span><span style="color: #339933;">;</span><span style="color: #000000; font-weight: bold;">?&gt;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">&lt;?php</span> get_sidebar<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>   get_footer<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p> paged =paged=> jetzt wirds dann zum Weiterblättern<br />
if &#8230;.do not duplicate  continue update post cache=> wenn es diese ID von oben ist, dann geh einfach weiter, erneuere aber Deinen post cache WP und ab die Post <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<div class="sign"> Ich habe diese beiden Loops nochmals getestet. Sie funktionieren einwandfrei. Wenns geholfen hat freu ich mich übers Weitersagen, ein +1 <img src="http://www.texto.de/wp-images/smilies/icon_confused.gif" alt="Kaffeetrinkender Smilie" width="27" height="21" /></div>
<hr /><small>Copyright &copy; 2011<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. Original article:  <a href="http://www.texto.de/wp-loop-teaserartikel-andere-artikel-ohne-teaser-aber-weiterblaettern-1247/" >texto.de</a> (Digital Fingerprint:  textoakamts[texto.de])</small><hr />]]></content:encoded>
			<wfw:commentRss>http://www.texto.de/wp-loop-teaserartikel-andere-artikel-ohne-teaser-aber-weiterblaettern-1247/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Noindex   gezielt   in WordPress verwenden</title>
		<link>http://www.texto.de/noindex-gezielt-in-wordpress-verwenden-1221/</link>
		<comments>http://www.texto.de/noindex-gezielt-in-wordpress-verwenden-1221/#comments</comments>
		<pubDate>Mon, 22 Aug 2011 18:43:41 +0000</pubDate>
		<dc:creator>texto</dc:creator>
				<category><![CDATA[WP-CMS]]></category>
		<category><![CDATA[conditional-tags]]></category>
		<category><![CDATA[wordpress-seo-plugin]]></category>

		<guid isPermaLink="false">http://www.texto.de/?p=1221</guid>
		<description><![CDATA[Weiterblättern also Seite 1 von 200, die Paginierung  mit noindex belegen. Noindex korrekt und gezielt  im html Header bei WordPress anwenden. Einzelne Kategorien, deren Inhalte und  statische Seiten mit noindex belegen.  Die Suchergebnisse nicht vergessen und ein bisschen mehr. ]]></description>
			<content:encoded><![CDATA[<dl class="left" style="width:320px;">
<dt> NoIndex richtig</dt>
<dd><img src="http://www.texto.de/wp-images/0811/mts-noindex-html-wordpress.jpg" alt=" NoIndex richtig in WordPress verwenden" width="300" height="200" /></dd>
</dl>
<p><span class="caplize">I</span>ch hörte &#8211; so rein zufällig &#8211; dass der gemütliche Panda, etliche zur Zeit in die Verzweiflung treibt und daher der meta tag &#8220;<strong>noindex</strong>&#8221; zu neuen Ehren erwacht.  </p>
<p>Viele fragten mich die letzten Tage: wie setz ich ne Kategorie auf noindex, wie die Inhalte derselben,  wie schließe ich die paginierten Seiten aus &#8211; also die Seiten, die entstehen, wenn WP einen &#8220;alte Einträge&#8221; &#8221; neue Einträge&#8221; Link macht. </p>
<div class="eyecatch">
<p>Disclaimer: ich übernehme absolut keine Verantwortung für die Verwendung vom meta tag noindex follow. </p>
<p>Null, nada, niente. </p>
<p>Jeder, der das macht, sollte sofort die einzelnen Seiten im Quellcode überprüfen, ob noindex auch wirklich nur dort steht, wo er es haben mag.</p>
</div>
<p>Außerdem habe ich schlichtweg überhaupt keine Ahnung, ob dies irgend ein SEO Plugin von WP anbietet, weil ich diese noch nie genutzt habe.  </p>
<p>Ich weiß bloß wie man noindex gezielt dort einsetzt wo man ihn haben mag. Und das erklär ich hier.</p>
<p><span id="more-1221"></span></p>
<p>Wichtig bei der ganzen Sache sind die <a href="http://www.texto.de/das-geheimnis-der-wp-template-hierarchie-template-sheet-zum-ausdrucken-600/" title="Template Sheet mit etlichen conditional tags">conditional tags </a>von WordPress, die Namen und oder IDs der einzelnen Kategorien, Seiten etc.</p>
<p>Wie immer erkläre ich dies für Leser, die nicht so PHP Gurus sind, daher ging manches sicher einfacher, doch es sollte ja &#8220;verwaltbar&#8221; und durchschaubar bleiben.</p>
<h3>Noindex bei Kategorien, Seiten, Suchergebnissen, Tags gezielt steuern.</h3>
<p>Archive, Kategorien, Seiten, Suchergebnisse, Tags etc sind mal alles, aber keine Einzelansichten eines Artikels. Daher zuerst diese ausschließen.</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span>is_single<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">:</span><span style="color: #000000; font-weight: bold;">?&gt;</span>
dein Inhalt
<span style="color: #000000; font-weight: bold;">&lt;?</span>pgp <span style="color: #b1b100;">endif</span><span style="color: #339933;">;</span><span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>&#8220;Wenn du nicht single bist, dann mache &#8230; &#8221; dies bedeutet obige Abfrage. </p>
<p>Der Reihe nach bedeutet untenstehender Code:<br />
wenn es eine Weiterblätterei gibt und du nicht die 1.Seite davon bist [paged nicht 1 aber paged is da]<br />
wenn du  ein Suchergebnis bist,<br />
die Kategorie mit der ID 9,<br />
ein Jahresarchiv,<br />
die statische Seite mit dem slug &#8220;impressum&#8221;,<br />
dann gib noIndex follow zurück, bei allem anderen index follow, aber schließ das Snippet eines alten Webverzeichnisses aus <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> .</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">&lt;meta name=&quot;robots&quot; content=&quot;<span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$paged</span> <span style="color: #339933;">!=</span> <span style="color: #cc66cc;">1</span>  <span style="color: #339933;">&amp;&amp;</span> <span style="color: #000088;">$paged</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">||</span>is_search<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">||</span>is_category<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'9'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">||</span>is_year<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">||</span>is_page<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'impressum'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span><span style="color: #b1b100;">echo</span><span style="color: #0000ff;">'noindex,follow'</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
<span style="color: #b1b100;">else</span><span style="color: #009900;">&#123;</span>
<span style="color: #b1b100;">echo</span><span style="color: #0000ff;">'index,follow,noodp'</span><span style="color: #339933;">;</span><span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span><span style="color: #000000; font-weight: bold;">?&gt;</span>&quot; /&gt;</pre></div></div>

<p>Achtung:das alles normalerweise in eine Zeile schreiben.</p>
<p>Magst Du mehr ausschließen, dann darfst Du nicht auf die beiden &#8220;||&#8221; vergessen, die bedeuten einfach &#8220;oder&#8221;. </p>
<p>Das ganze kommt nun in die erste Abfrage &#8220;wenn du nicht single&#8221; bist rein. Dort wo steht &#8220;dein Inhalt&#8221;. </p>
<h3>Noindex für einzelne Singles und für alle Artikel aus bestimmten Kategorien</h3>
<p>Jetzt brauchen wir nur sie Singles</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span>is_single<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">:</span><span style="color: #000000; font-weight: bold;">?&gt;</span>
dein Inhalt
<span style="color: #000000; font-weight: bold;">&lt;?</span>pgp <span style="color: #b1b100;">endif</span><span style="color: #339933;">;</span><span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>Und wir brauchen einen Loop, damit <strong>in_category </strong>gut funktioniert, da kann man dann auch alle custom post types und taxonomien Einzelseiten reinpacken, die brauchen auch meist einen Loop zur Abfrage. Naja zumindest ist es wesentlich einfacher <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>Mit untenstehender Anweisung bekommen alle Artikel, die in der Kategorie mit der ID9 sind und der Artikel mit der ID 3456 ein noIndex verpasst, alle anderen dürfen bei Googles Suche drin bleiben.</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">if</span> <span style="color: #009900;">&#40;</span>have_posts<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">:</span> <span style="color: #b1b100;">while</span> <span style="color: #009900;">&#40;</span>have_posts<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">:</span> the_post<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
&lt;meta name=&quot;robots&quot; content=&quot;<span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span>in_category<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'9'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">||</span>is_single<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'3456'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span><span style="color: #b1b100;">echo</span><span style="color: #0000ff;">'noindex,follow'</span><span style="color: #339933;">;</span><span style="color: #009900;">&#125;</span><span style="color: #b1b100;">else</span><span style="color: #009900;">&#123;</span><span style="color: #b1b100;">echo</span><span style="color: #0000ff;">'index,follow,noodp'</span><span style="color: #339933;">;</span><span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span><span style="color: #000000; font-weight: bold;">?&gt;</span>&quot; /&gt;
<span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">endwhile</span><span style="color: #339933;">;</span> <span style="color: #b1b100;">endif</span><span style="color: #339933;">;</span><span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>Das kommt dort rein wo wir zuerst abgefragt haben, ob es ein Single ist. &#8230; </p>
<h3>robots.text und noindex</h3>
<p>Wenn Du magst, dass Google und andere Suchrobots Deine noindex Angaben finden, dann ist es kontraproduktiv gleichzeitig die Bots in der robots.txt von all diesen Kategorien etc auszuschließen.</p>
<p>Der Bot kann nur was finden, wenn er ins Haus darf <img src='http://www.texto.de/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<div class="sign">wenn das heut kein Twittern, +1 oder sonst einen Artikel wo wert ist, dann &#8211; ertränk ich mich in ==> <img src="/wp-images/smilies/icon_confused.gif" alt="Kaffeetrinkender Smilie" width="27" height="21" /> </div>
<hr /><small>Copyright &copy; 2011<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. Original article:  <a href="http://www.texto.de/noindex-gezielt-in-wordpress-verwenden-1221/" >texto.de</a> (Digital Fingerprint:  textoakamts[texto.de])</small><hr />]]></content:encoded>
			<wfw:commentRss>http://www.texto.de/noindex-gezielt-in-wordpress-verwenden-1221/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
		</item>
		<item>
		<title>WP Undelete: Restore Deleted Posts-wenn die Putzwut schlägt</title>
		<link>http://www.texto.de/wp-undelete-restore-deleted-posts-wenn-die-putzwut-schlaegt-1203/</link>
		<comments>http://www.texto.de/wp-undelete-restore-deleted-posts-wenn-die-putzwut-schlaegt-1203/#comments</comments>
		<pubDate>Thu, 11 Aug 2011 10:50:55 +0000</pubDate>
		<dc:creator>texto</dc:creator>
				<category><![CDATA[WP-CMS]]></category>
		<category><![CDATA[wordpress-cms]]></category>
		<category><![CDATA[wordpress-plugins]]></category>

		<guid isPermaLink="false">http://www.texto.de/?p=1203</guid>
		<description><![CDATA[WP Undelete ist ein WordPress Plugin, das den gelöschten Papierkorb wieder herstellt. Man kann also Artikel, die aus dem Papierkorb gelöscht wurden wieder herstellen. Hilfreich für so manche Kundenseite-so meine Erfahrung. ]]></description>
			<content:encoded><![CDATA[<dl class="left" style="width:280px;">
<dt> &nbsp;</dt>
<dd><img src="http://www.texto.de/wp-images/0811/mts-restore-deleted-posts.jpg" alt=" WP-undelete -gelöschte Artikel wieder herstellen" width="223" height="166" /></dd>
<dd>die Icons sind von<a href="http://paradis24434.deviantart.com/art/Antique-icons-65361362" title="Icons"> paradis24434</a>.</dd>
</dl>
<p><span class="caplize">M</span>ancher meint der Papierkorb, den WordPress zur Verfügung stellt reicht aus, damit Artikel nicht mehr in im Nirvana der bites&#038;bytes verschwinden. Dies ist allerdings ein großer Irrtum. </p>
<p>Auch ich habe Kunden, die Artikel im Papierkorb &#8220;zwischenparken&#8221;, dann darauf vergessen und in einem Anfall von &#8220;FrühjahrsputzWut&#8221; einfach auf &#8220;<strong>empty trash</strong>&#8221; klicken und danach völlig erstaunt sind, dass diese Artikel wirklich weg sind.</p>
<p><a href="http://wordpress.org/extend/plugins/wp-undelete-restore-deleted-posts/" title="Restore deleted posts">WP Undelete: Restore Deleted Posts</a> hilft hier zukünftig aus. Es wirkt wie ein doppelter Schutz. Sogar der ausgeleerte Papierkorb wird wieder hergestellt. </p>
<p><span id="more-1203"></span></p>
<p><br class="clear" /></p>
<dl class="left" style="width:320px;">
<dt>WP Undelete verwenden&nbsp;</dt>
<dd><img src="http://www.texto.de/wp-images/0811/restore-deleted-posts.gif" alt=" restore deleted posts" width="312" height="281" /></dd>
</dl>
<h3>WP Undelete &#8211; Nutzung</h3>
<p>Programmiert hat dies <a href="http://www.josscrowcroft.com/projects/wp-undelete-restore-deleted-posts-wordpress-plugin/" title="Joe Crowcroft">Joe Crowcroft</a>. Das Plugin ist noch in der Entwicklung. Daher bitte aufpassen und Bugs etc an ihn melden. </p>
<p>Ist das Plugin aktiviert, findet man unter <strong>Admincenter==>Einstellungen </strong>einen Link zur wichtigen Seite. Der Screen zeigt wies geht <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> . Es werden die gelöschten Artikel angezeigt und dann kann man sich entscheiden: zurück in den Papierkorb oder wirklich &#8220;weg&#8221;.</p>
<p><br class="clear" /></p>
<h3>Empfehlung:</h3>
<p>diese Verwaltungsseite des Plugins würde ich persönlich nicht für Kunden sichtbar machen.<br />
wer weiß was der nächste &#8220;FrühjahrsputzWahnsinn&#8221; sonst wiederum bewirkt <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' />  </p>
<h3>WP Undelete: Download und Support</h3>
<p><a href="http://wordpress.org/extend/plugins/wp-undelete-restore-deleted-posts/" title="Restore deleted posts">WP Undelete: Restore Deleted Posts</a> und <a href="http://www.josscrowcroft.com/projects/wp-undelete-restore-deleted-posts-wordpress-plugin/" title="Joe Crowcroft">Bugreport und Support</a>.</p>
<div class="sign">so lebt sich&#8217;s eindeutig entspannter  <img src="/wp-images/smilies/icon_confused.gif" alt="Kaffeetrinkender Smilie" width="27" height="21" /></div>
<hr /><small>Copyright &copy; 2011<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. Original article:  <a href="http://www.texto.de/wp-undelete-restore-deleted-posts-wenn-die-putzwut-schlaegt-1203/" >texto.de</a> (Digital Fingerprint:  textoakamts[texto.de])</small><hr />]]></content:encoded>
			<wfw:commentRss>http://www.texto.de/wp-undelete-restore-deleted-posts-wenn-die-putzwut-schlaegt-1203/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Pronamic Page Teasers &#8211; auf einer Seite andere Seiten anzeigen</title>
		<link>http://www.texto.de/pronamic-page-teasers-auf-einer-seite-andere-seiten-anzeigen-1201/</link>
		<comments>http://www.texto.de/pronamic-page-teasers-auf-einer-seite-andere-seiten-anzeigen-1201/#comments</comments>
		<pubDate>Tue, 09 Aug 2011 17:37:51 +0000</pubDate>
		<dc:creator>texto</dc:creator>
				<category><![CDATA[WP-CMS]]></category>
		<category><![CDATA[wordpress-plugins]]></category>
		<category><![CDATA[WP-3]]></category>

		<guid isPermaLink="false">http://www.texto.de/?p=1201</guid>
		<description><![CDATA[Auf einer Seite andere Seiten anzeigen und zwar als Teaser, dies bietet das Plugin Pronamic Page Teasers. Hier erkläre ich die Verwendung. ]]></description>
			<content:encoded><![CDATA[<dl class="left" style="width:315px;">
<dt> &nbsp;</dt>
<dd><img src="http://www.texto.de/wp-images/0811/pronamic-page-teasers-.jpg" alt=" Pronamic Page Teasers" width="301" height="318" /></dd>
</dl>
<p><span class="caplize">D</span>as Plugin <a href="http://wordpress.org/extend/plugins/pronamic-page-teasers/" title="Pronamic Page Teasers  Plugin">Pronamic Page Teasers </a> bietet die Möglichkeit auf einer statischen Seite von WordPress andere statische Seiten anzuzeigen. Dies ermöglicht relativ einfach eine sehr individuelle Startseite zu erstellen oder aber auch auf einer Hauptseite sofort die dazugehörenden Unterseiten aufzulisten. </p>
<p>Pronamic Page Teasers  liefert auch ein eigens Template mit dem man die Ausgabe der Teaser frei gestalten kann.</p>
<p><strong>pronamic-page-teasers.php</strong> muss man diese Datei nennen und dann einfach in den eignenn Theme Ordner hochladen.</p>
<p><span id="more-1201"></span></p>
<p>Das ist der Standard Code der pronamic-page-teasers.php.</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">&nbsp;
<span style="color: #000000; font-weight: bold;">&lt;?php</span> 
<span style="color: #000088;">$teasers</span> <span style="color: #339933;">=</span> pronamic_get_page_teasers<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$h</span> <span style="color: #339933;">=</span> is_front_page<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> ? <span style="color: #cc66cc;">3</span> <span style="color: #339933;">:</span> <span style="color: #cc66cc;">2</span><span style="color: #339933;">;</span>
<span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$teasers</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">:</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
&lt;ul&gt;
    <span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">foreach</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$teasers</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$post</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">:</span> setup_postdata<span style="color: #009900;">&#40;</span><span style="color: #000088;">$post</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
    &lt;li&gt;
        &lt;article id=&quot;teaser-<span style="color: #000000; font-weight: bold;">&lt;?php</span> the_ID<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>&quot; <span style="color: #000000; font-weight: bold;">&lt;?php</span> post_class<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'teaser'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>&gt;
            &lt;h<span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">echo</span> <span style="color: #000088;">$h</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span> class=&quot;entry-title&quot;&gt;
                &lt;a href=&quot;<span style="color: #000000; font-weight: bold;">&lt;?php</span> the_permalink<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>&quot; title=&quot;<span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #990000;">printf</span><span style="color: #009900;">&#40;</span>esc_attr__<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'Permalink to %s'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span> the_title_attribute<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'echo=0'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>&quot; rel=&quot;bookmark&quot;&gt;
                    <span style="color: #000000; font-weight: bold;">&lt;?php</span> the_title<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
                &lt;/a&gt;
            &lt;/h<span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">echo</span> <span style="color: #000088;">$h</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>&gt;
            <span style="color: #000000; font-weight: bold;">&lt;?php</span> the_excerpt<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
        &lt;/article&gt;
    &lt;/li&gt;
    <span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">endforeach</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
&lt;/ul&gt;
<span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #b1b100;">endif</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>Wer also anderes html haben mag, der erstellt eine <strong>pronamic-page-teasers.php</strong> kopiert obenstehenden Code hinein und ändert dann ab. Texteditor reicht. WordPad ist keiner!</p>
<h3>ausgeliefertes CSS und HTML des Pronamic Page Teaser Plugins ohne eigene pronamic-page-teasers.php</h3>
<p>oben ersichtliche Liste wird in einem div verpackt.</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;pronamic-page-teasers&quot;</span>&gt;</span></pre></div></div>

<p>article bekommt die zursätzliche CSS Klasse &#8220;pronamic-page-teasers&#8221; und als ID die ID der Seite mit vorangestelltem pronamic-page-teasers, also zB.:  pronamic-page-teasers-87.</p>
<h3>Verwendung des Plugins  Pronamic Page Teaser</h3>
<p>Das Plugin ist aktiviert. Hast Du bereits die statischen Seiten, dann gehst Du zu Admincenter==>Seiten<br />
wählst dort die Seite aus, auf der andere Seiten zu finden sein sollen und &#8220;bearbeitest&#8221; die Seite.</p>
<dl class="left" style="width:310px;">
<dt> Pronamic Page Teasers Menü&nbsp;</dt>
<dd><img src="http://www.texto.de/wp-images/0811/mts-pronamic-page-teasers.gif" alt=" Pronamic Page Teasers Menü" width="300" height="146" /></dd>
</dl>
<p>Rechts findest Du ein neues Menü.<br />
Hier kannst Du via DropDown die Seiten auswählen, die erscheinen sollten. Du kannst jede vorhandene Seite auswählen, egal, ob sie eine Kindseite ist oder nicht. <img src='http://www.texto.de/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<h3>Bilder bei den Seiten </h3>
<p>Wenn Du ein Artikelbild nutzt wird es automatisch bei der Vorschau genommen. Bilder in der jeweiligen Seite erscheinen nicht automatisch.</p>
<h3>Achtung bei mehreren Loops</h3>
<p>Gibt es the_content öfter auf der Seite, was ja bei komplexeren Loops leicht der Fall sein kann,<br />
und man mag logischerweise nicht, dass diese Pronamic Page Teasers überall erscheinen, dann ändert man dies so ab:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;">remove_filter<span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'the_content'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'pronamic_page_teasers_the_content'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<h3>Und LightBox Plugins funktionieren die noch</h3>
<p>Ich teste das Plugin auch mit Shutter Reloaded, weil in den Forenbeiträgen zu lesen war, dass so manches LightboxPlugin nicht funktioniert. Anstandslos tat Shutter Reloaded seinen Dienst . </p>
<h3>Ähnliches Plugin</h3>
<p>Perun zeigt eine andere Möglichkeit auf, den <a href="http://www.perun.net/2011/08/08/wordpress-den-inhalt-einer-seite-einfuegen/" title="Inhalt einer Seite einfügen">Inhalt einer Seite einzufügen</a>.</p>
<h3>Download und Support</h3>
<p>alles gibts hier  <a href="http://wordpress.org/extend/plugins/pronamic-page-teasers/" title="Pronamic Page Teasers  Plugin">Pronamic Page Teasers </a>.</p>
<div class="sign">wars hilfreich freu ich mich auch über ein G+ <img src='http://www.texto.de/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' />  </div>
<hr /><small>Copyright &copy; 2011<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. Original article:  <a href="http://www.texto.de/pronamic-page-teasers-auf-einer-seite-andere-seiten-anzeigen-1201/" >texto.de</a> (Digital Fingerprint:  textoakamts[texto.de])</small><hr />]]></content:encoded>
			<wfw:commentRss>http://www.texto.de/pronamic-page-teasers-auf-einer-seite-andere-seiten-anzeigen-1201/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>E-mail an Autor WP Plugin</title>
		<link>http://www.texto.de/e-mail-an-autor-wp-plugin-1189/</link>
		<comments>http://www.texto.de/e-mail-an-autor-wp-plugin-1189/#comments</comments>
		<pubDate>Sat, 26 Feb 2011 20:37:16 +0000</pubDate>
		<dc:creator>texto</dc:creator>
				<category><![CDATA[WP-CMS]]></category>
		<category><![CDATA[wordpress-plugins]]></category>

		<guid isPermaLink="false">http://www.texto.de/?p=1189</guid>
		<description><![CDATA[Comment Moderation E-mail to Post Author - Ein WordPress Plugin, das E-mails an den Artikel Autoren schickt. ]]></description>
			<content:encoded><![CDATA[<dl class="left" style="width:360px;">
<dt> E-mail an Autor Plugin</dt>
<dd><img src="http://www.texto.de/wp-images/0211/Email-an-Autor-Plugin.jpg" alt=" E-mail an Autor  Plugin bei Comment Moderation" width="350" height="348" /></dd>
</dl>
<p>  Werden die Kommentare moderiert und sind viele Autoren aktiv  hat der Admin des WP Blogs mit einer Menge an E-mails zu kämpfen.</p>
<p>Bei jedem Kommentar, <strong>der auf Moderation wartet</strong> bekommt der Admin eine E-mail. Dies können bei einem stark frenquentiertem Blog schon mal ne ganze Menge pro Tag sein.  Mit dem WP-Plugin <a href="http://4visions.nl/en/wordpress-plugins/comment-moderation-e-mail-to-post-author/" title="Comment Moderation E-mail zum Autor "><strong>Comment Moderation E-mail to Post Author</strong></a> bekommen die Autoren eines Artikels die E-mails, wenn der Kommentar auf Freischaltung wartet.</p>
<p>Das Plugin &#8220;Comment Moderation E-mail to Post Author&#8221; muss <span id="more-1189"></span>einfach aktiviert werden und schon leistet es seinen guten Dienst. </p>
<p>Ich habe dieses Plugin auch mit dem neuen WordPress 3.1. getestet und es funktioniert einwandfrei. </p>
<div class="sign"><img src="/wp-images/smilies/icon_confused.gif" alt="Kaffeetrinkender Smilie" width="27" height="21" /> </div>
<hr /><small>Copyright &copy; 2011<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. Original article:  <a href="http://www.texto.de/e-mail-an-autor-wp-plugin-1189/" >texto.de</a> (Digital Fingerprint:  textoakamts[texto.de])</small><hr />]]></content:encoded>
			<wfw:commentRss>http://www.texto.de/e-mail-an-autor-wp-plugin-1189/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
	</channel>
</rss>

