<?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>WP Engineer &#187; WordPress 2.8</title>
	<atom:link href="http://wpengineer.com/tag/wordpress-28/feed/" rel="self" type="application/rss+xml" />
	<link>http://wpengineer.com</link>
	<description>WordPress News, Hacks, Tips, Tutorials, Plugins and Themes</description>
	<lastBuildDate>Mon, 21 May 2012 22:48:48 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Add File Types for Mediathek</title>
		<link>http://wpengineer.com/1668/add-file-types-for-mediathek/</link>
		<comments>http://wpengineer.com/1668/add-file-types-for-mediathek/#comments</comments>
		<pubDate>Fri, 18 Sep 2009 08:54:41 +0000</pubDate>
		<dc:creator>Frank</dc:creator>
				<category><![CDATA[WordPress Hacks]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress 2.8]]></category>
		<category><![CDATA[WP]]></category>

		<guid isPermaLink="false">http://wpengineer.com/?p=1668</guid>
		<description><![CDATA[In WordPress 2.8.5 the whitelist of allowed MIME types for downloads will be valid for administrators the first time. This is a step towards security and you can, with the help of a constant, upload all data types. define ( 'ALLOW_UNFILTERED_UPLOADS', true); Who has implemented several projects already with WordPress probably had experienced that a [...]]]></description>
			<content:encoded><![CDATA[<p>In WordPress 2.8.5 the whitelist of allowed MIME types for downloads will be valid for administrators the first time. This is a step towards security and you can, with the help of a constant, upload all data types.<br />
<code>define ( 'ALLOW_UNFILTERED_UPLOADS', true);</code></p>
<p>Who has implemented several projects already with WordPress probably had experienced that a user doesn't have the rights to upload a specific format.</p>
<p>The Plugin <a href="http://www.im-web-gefunden.de/wordpress-plugins/role-manager/">Role Manager</a> allows the uploading of all MIME types. But in my opinion this is not the perfect way, and therefore here is a small code snippet that takes adjusting according to the particular requirement.<br />
<span id="more-1668"></span><br />
<a href="http://wpengineer.com/wp-content/uploads/upload-filter.png"><img src="http://wpengineer.com/wp-content/uploads/upload-filter.png" alt="upload-filter" title="upload-filter" width="439" height="346" class="aligncenter size-full wp-image-1670" /></a></p>
<p>All allowed types are found in the whitelist-function <code>wp_check_filetype()</code>, in <code> wp-includes/functions.php</code>.<br />
This function has a filter <code>upload_mimes</code> that can be extended. And there we come in and call the MIME types that we need. In the following example, I allow PHP-, XHTML- and htaccess-files. The options are passed in an array and the assignment is important so that WordPress can also assign an icon, like you see on the screenshot.</p>
<pre lang="php">
function my_upload_mimes() {
	$mime_types = array(
		&#039;php|phps&#039;   =&gt; &#039;text/php&#039;,
		&#039;xhtm|xhtml&#039; =&gt; &#039;text/html&#039;,
		&#039;htaccess&#039;    =&gt; &#039;text/plain&#039;
	);

	return $mime_types;
}

add_filter( &#039;upload_mimes&#039;, &#039;my_upload_mimes&#039; );
</pre>
<h4>Mime Types</h4>
<p>To obtain a list of all MIME types that can be used, you can check out the following list. The list should only contain type files, which are explicitly required,  otherwise the above constants can be used.</p>
<pre lang="php">
$mime_types = array(
&#039;323&#039;     =&gt; &#039;text/h323&#039;,
&#039;acx&#039;     =&gt; &#039;application/internet-property-stream&#039;,
&#039;ai&#039;      =&gt; &#039;application/postscript&#039;,
&#039;aif&#039;     =&gt; &#039;audio/x-aiff&#039;,
&#039;aifc&#039;    =&gt; &#039;audio/x-aiff&#039;,
&#039;aiff&#039;    =&gt; &#039;audio/x-aiff&#039;,
&#039;asf&#039;     =&gt; &#039;video/x-ms-asf&#039;,
&#039;asr&#039;     =&gt; &#039;video/x-ms-asf&#039;,
&#039;asx&#039;     =&gt; &#039;video/x-ms-asf&#039;,
&#039;au&#039;      =&gt; &#039;audio/basic&#039;,
&#039;avi&#039;     =&gt; &#039;video/x-msvideo&#039;,
&#039;axs&#039;     =&gt; &#039;application/olescript&#039;,
&#039;bas&#039;     =&gt; &#039;text/plain&#039;,
&#039;bcpio&#039;   =&gt; &#039;application/x-bcpio&#039;,
&#039;bin&#039;     =&gt; &#039;application/octet-stream&#039;,
&#039;bmp&#039;     =&gt; &#039;image/bmp&#039;,
&#039;c&#039;       =&gt; &#039;text/plain&#039;,
&#039;cat&#039;     =&gt; &#039;application/vnd.ms-pkiseccat&#039;,
&#039;cdf&#039;     =&gt; &#039;application/x-cdf&#039;,
&#039;cer&#039;     =&gt; &#039;application/x-x509-ca-cert&#039;,
&#039;class&#039;   =&gt; &#039;application/octet-stream&#039;,
&#039;clp&#039;     =&gt; &#039;application/x-msclip&#039;,
&#039;cmx&#039;     =&gt; &#039;image/x-cmx&#039;,
&#039;cod&#039;     =&gt; &#039;image/cis-cod&#039;,
&#039;cpio&#039;    =&gt; &#039;application/x-cpio&#039;,
&#039;crd&#039;     =&gt; &#039;application/x-mscardfile&#039;,
&#039;crl&#039;     =&gt; &#039;application/pkix-crl&#039;,
&#039;crt&#039;     =&gt; &#039;application/x-x509-ca-cert&#039;,
&#039;csh&#039;     =&gt; &#039;application/x-csh&#039;,
&#039;css&#039;     =&gt; &#039;text/css&#039;,
&#039;dcr&#039;     =&gt; &#039;application/x-director&#039;,
&#039;der&#039;     =&gt; &#039;application/x-x509-ca-cert&#039;,
&#039;dir&#039;     =&gt; &#039;application/x-director&#039;,
&#039;dll&#039;     =&gt; &#039;application/x-msdownload&#039;,
&#039;dms&#039;     =&gt; &#039;application/octet-stream&#039;,
&#039;doc&#039;     =&gt; &#039;application/msword&#039;,
&#039;dot&#039;     =&gt; &#039;application/msword&#039;,
&#039;dvi&#039;     =&gt; &#039;application/x-dvi&#039;,
&#039;dxr&#039;     =&gt; &#039;application/x-director&#039;,
&#039;eps&#039;     =&gt; &#039;application/postscript&#039;,
&#039;etx&#039;     =&gt; &#039;text/x-setext&#039;,
&#039;evy&#039;     =&gt; &#039;application/envoy&#039;,
&#039;exe&#039;     =&gt; &#039;application/octet-stream&#039;,
&#039;fif&#039;     =&gt; &#039;application/fractals&#039;,
&#039;flr&#039;     =&gt; &#039;x-world/x-vrml&#039;,
&#039;gif&#039;     =&gt; &#039;image/gif&#039;,
&#039;gtar&#039;    =&gt; &#039;application/x-gtar&#039;,
&#039;gz&#039;      =&gt; &#039;application/x-gzip&#039;,
&#039;h&#039;       =&gt; &#039;text/plain&#039;,
&#039;hdf&#039;     =&gt; &#039;application/x-hdf&#039;,
&#039;hlp&#039;     =&gt; &#039;application/winhlp&#039;,
&#039;hqx&#039;     =&gt; &#039;application/mac-binhex40&#039;,
&#039;hta&#039;     =&gt; &#039;application/hta&#039;,
&#039;htc&#039;     =&gt; &#039;text/x-component&#039;,
&#039;htm&#039;     =&gt; &#039;text/html&#039;,
&#039;html&#039;    =&gt; &#039;text/html&#039;,
&#039;htt&#039;     =&gt; &#039;text/webviewhtml&#039;,
&#039;ico&#039;     =&gt; &#039;image/x-icon&#039;,
&#039;ief&#039;     =&gt; &#039;image/ief&#039;,
&#039;iii&#039;     =&gt; &#039;application/x-iphone&#039;,
&#039;ins&#039;     =&gt; &#039;application/x-internet-signup&#039;,
&#039;isp&#039;     =&gt; &#039;application/x-internet-signup&#039;,
&#039;jfif&#039;    =&gt; &#039;image/pipeg&#039;,
&#039;jpe&#039;     =&gt; &#039;image/jpeg&#039;,
&#039;jpeg&#039;    =&gt; &#039;image/jpeg&#039;,
&#039;jpg&#039;     =&gt; &#039;image/jpeg&#039;,
&#039;js&#039;      =&gt; &#039;application/x-javascript&#039;,
&#039;latex&#039;   =&gt; &#039;application/x-latex&#039;,
&#039;lha&#039;     =&gt; &#039;application/octet-stream&#039;,
&#039;lsf&#039;     =&gt; &#039;video/x-la-asf&#039;,
&#039;lsx&#039;     =&gt; &#039;video/x-la-asf&#039;,
&#039;lzh&#039;     =&gt; &#039;application/octet-stream&#039;,
&#039;m13&#039;     =&gt; &#039;application/x-msmediaview&#039;,
&#039;m14&#039;     =&gt; &#039;application/x-msmediaview&#039;,
&#039;m3u&#039;     =&gt; &#039;audio/x-mpegurl&#039;,
&#039;man&#039;     =&gt; &#039;application/x-troff-man&#039;,
&#039;mdb&#039;     =&gt; &#039;application/x-msaccess&#039;,
&#039;me&#039;      =&gt; &#039;application/x-troff-me&#039;,
&#039;mht&#039;     =&gt; &#039;message/rfc822&#039;,
&#039;mhtml&#039;   =&gt; &#039;message/rfc822&#039;,
&#039;mid&#039;     =&gt; &#039;audio/mid&#039;,
&#039;mny&#039;     =&gt; &#039;application/x-msmoney&#039;,
&#039;mov&#039;     =&gt; &#039;video/quicktime&#039;,
&#039;movie&#039;   =&gt; &#039;video/x-sgi-movie&#039;,
&#039;mp2&#039;     =&gt; &#039;video/mpeg&#039;,
&#039;mp3&#039;     =&gt; &#039;audio/mpeg&#039;,
&#039;mpa&#039;     =&gt; &#039;video/mpeg&#039;,
&#039;mpe&#039;     =&gt; &#039;video/mpeg&#039;,
&#039;mpeg&#039;    =&gt; &#039;video/mpeg&#039;,
&#039;mpg&#039;     =&gt; &#039;video/mpeg&#039;,
&#039;mpp&#039;     =&gt; &#039;application/vnd.ms-project&#039;,
&#039;mpv2&#039;    =&gt; &#039;video/mpeg&#039;,
&#039;ms&#039;      =&gt; &#039;application/x-troff-ms&#039;,
&#039;mvb&#039;     =&gt; &#039;application/x-msmediaview&#039;,
&#039;nws&#039;     =&gt; &#039;message/rfc822&#039;,
&#039;oda&#039;     =&gt; &#039;application/oda&#039;,
&#039;p10&#039;     =&gt; &#039;application/pkcs10&#039;,
&#039;p12&#039;     =&gt; &#039;application/x-pkcs12&#039;,
&#039;p7b&#039;     =&gt; &#039;application/x-pkcs7-certificates&#039;,
&#039;p7c&#039;     =&gt; &#039;application/x-pkcs7-mime&#039;,
&#039;p7m&#039;     =&gt; &#039;application/x-pkcs7-mime&#039;,
&#039;p7r&#039;     =&gt; &#039;application/x-pkcs7-certreqresp&#039;,
&#039;p7s&#039;     =&gt; &#039;application/x-pkcs7-signature&#039;,
&#039;pbm&#039;     =&gt; &#039;image/x-portable-bitmap&#039;,
&#039;pdf&#039;     =&gt; &#039;application/pdf&#039;,
&#039;pfx&#039;     =&gt; &#039;application/x-pkcs12&#039;,
&#039;pgm&#039;     =&gt; &#039;image/x-portable-graymap&#039;,
&#039;pko&#039;     =&gt; &#039;application/ynd.ms-pkipko&#039;,
&#039;pma&#039;     =&gt; &#039;application/x-perfmon&#039;,
&#039;pmc&#039;     =&gt; &#039;application/x-perfmon&#039;,
&#039;pml&#039;     =&gt; &#039;application/x-perfmon&#039;,
&#039;pmr&#039;     =&gt; &#039;application/x-perfmon&#039;,
&#039;pmw&#039;     =&gt; &#039;application/x-perfmon&#039;,
&#039;pnm&#039;     =&gt; &#039;image/x-portable-anymap&#039;,
&#039;pot&#039;     =&gt; &#039;application/vnd.ms-powerpoint&#039;,
&#039;ppm&#039;     =&gt; &#039;image/x-portable-pixmap&#039;,
&#039;pps&#039;     =&gt; &#039;application/vnd.ms-powerpoint&#039;,
&#039;ppt&#039;     =&gt; &#039;application/vnd.ms-powerpoint&#039;,
&#039;prf&#039;     =&gt; &#039;application/pics-rules&#039;,
&#039;ps&#039;      =&gt; &#039;application/postscript&#039;,
&#039;pub&#039;     =&gt; &#039;application/x-mspublisher&#039;,
&#039;qt&#039;      =&gt; &#039;video/quicktime&#039;,
&#039;ra&#039;      =&gt; &#039;audio/x-pn-realaudio&#039;,
&#039;ram&#039;     =&gt; &#039;audio/x-pn-realaudio&#039;,
&#039;ras&#039;     =&gt; &#039;image/x-cmu-raster&#039;,
&#039;rgb&#039;     =&gt; &#039;image/x-rgb&#039;,
&#039;rmi&#039;     =&gt; &#039;audio/mid&#039;,
&#039;roff&#039;    =&gt; &#039;application/x-troff&#039;,
&#039;rtf&#039;     =&gt; &#039;application/rtf&#039;,
&#039;rtx&#039;     =&gt; &#039;text/richtext&#039;,
&#039;scd&#039;     =&gt; &#039;application/x-msschedule&#039;,
&#039;sct&#039;     =&gt; &#039;text/scriptlet&#039;,
&#039;setpay&#039;  =&gt; &#039;application/set-payment-initiation&#039;,
&#039;setreg&#039;  =&gt; &#039;application/set-registration-initiation&#039;,
&#039;sh&#039;      =&gt; &#039;application/x-sh&#039;,
&#039;shar&#039;    =&gt; &#039;application/x-shar&#039;,
&#039;sit&#039;     =&gt; &#039;application/x-stuffit&#039;,
&#039;snd&#039;     =&gt; &#039;audio/basic&#039;,
&#039;spc&#039;     =&gt; &#039;application/x-pkcs7-certificates&#039;,
&#039;spl&#039;     =&gt; &#039;application/futuresplash&#039;,
&#039;src&#039;     =&gt; &#039;application/x-wais-source&#039;,
&#039;sst&#039;     =&gt; &#039;application/vnd.ms-pkicertstore&#039;,
&#039;stl&#039;     =&gt; &#039;application/vnd.ms-pkistl&#039;,
&#039;stm&#039;     =&gt; &#039;text/html&#039;,
&#039;svg&#039;     =&gt; &#039;image/svg+xml&#039;,
&#039;sv4cpio&#039; =&gt; &#039;application/x-sv4cpio&#039;,
&#039;sv4crc&#039;  =&gt; &#039;application/x-sv4crc&#039;,
&#039;t&#039;       =&gt; &#039;application/x-troff&#039;,
&#039;tar&#039;     =&gt; &#039;application/x-tar&#039;,
&#039;tcl&#039;     =&gt; &#039;application/x-tcl&#039;,
&#039;tex&#039;     =&gt; &#039;application/x-tex&#039;,
&#039;texi&#039;    =&gt; &#039;application/x-texinfo&#039;,
&#039;texinfo&#039; =&gt; &#039;application/x-texinfo&#039;,
&#039;tgz&#039;     =&gt; &#039;application/x-compressed&#039;,
&#039;tif&#039;     =&gt; &#039;image/tiff&#039;,
&#039;tiff&#039;    =&gt; &#039;image/tiff&#039;,
&#039;tr&#039;      =&gt; &#039;application/x-troff&#039;,
&#039;trm&#039;     =&gt; &#039;application/x-msterminal&#039;,
&#039;tsv&#039;     =&gt; &#039;text/tab-separated-values&#039;,
&#039;txt&#039;     =&gt; &#039;text/plain&#039;,
&#039;uls&#039;     =&gt; &#039;text/iuls&#039;,
&#039;ustar&#039;   =&gt; &#039;application/x-ustar&#039;,
&#039;vcf&#039;     =&gt; &#039;text/x-vcard&#039;,
&#039;vrml&#039;    =&gt; &#039;x-world/x-vrml&#039;,
&#039;wav&#039;     =&gt; &#039;audio/x-wav&#039;,
&#039;wcm&#039;     =&gt; &#039;application/vnd.ms-works&#039;,
&#039;wdb&#039;     =&gt; &#039;application/vnd.ms-works&#039;,
&#039;wks&#039;     =&gt; &#039;application/vnd.ms-works&#039;,
&#039;wmf&#039;     =&gt; &#039;application/x-msmetafile&#039;,
&#039;wps&#039;     =&gt; &#039;application/vnd.ms-works&#039;,
&#039;wri&#039;     =&gt; &#039;application/x-mswrite&#039;,
&#039;wrl&#039;     =&gt; &#039;x-world/x-vrml&#039;,
&#039;wrz&#039;     =&gt; &#039;x-world/x-vrml&#039;,
&#039;xaf&#039;     =&gt; &#039;x-world/x-vrml&#039;,
&#039;xbm&#039;     =&gt; &#039;image/x-xbitmap&#039;,
&#039;xla&#039;     =&gt; &#039;application/vnd.ms-excel&#039;,
&#039;xlc&#039;     =&gt; &#039;application/vnd.ms-excel&#039;,
&#039;xlm&#039;     =&gt; &#039;application/vnd.ms-excel&#039;,
&#039;xls&#039;     =&gt; &#039;application/vnd.ms-excel&#039;,
&#039;xlt&#039;     =&gt; &#039;application/vnd.ms-excel&#039;,
&#039;xlw&#039;     =&gt; &#039;application/vnd.ms-excel&#039;,
&#039;xof&#039;     =&gt; &#039;x-world/x-vrml&#039;,
&#039;xpm&#039;     =&gt; &#039;image/x-xpixmap&#039;,
&#039;xwd&#039;     =&gt; &#039;image/x-xwindowdump&#039;,
&#039;z&#039;       =&gt; &#039;application/x-compress&#039;,
&#039;zip&#039;     =&gt; &#039;application/zip&#039;
);
</pre>
<hr /><a href="http://wpplugins.com/plugin/281/snippets" title="More informations about this plugin for WordPress"><img src="http://wpengineer.com/wp-content/themes/wpe-3/images/snippets-125-125.png" height="90" alt="WordPress Snippet Plugin" /></a> <a href="http://xtreme-theme.com"><img src="http://wpengineer.com/wp-content/uploads/feed-banner-2.jpg" alt="Xtreme One WordPress Framework"/></a><br />
&copy; <a href="http://wpengineer.com/">WP Engineer Team</a>, All rights reserved <small>(Digital Fingerprint: WPEngineer-be0254ce2b4972feb4b9cb72034a092d)</small></p>
]]></content:encoded>
			<wfw:commentRss>http://wpengineer.com/1668/add-file-types-for-mediathek/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Cleanup WordPress Header</title>
		<link>http://wpengineer.com/1438/wordpress-header/</link>
		<comments>http://wpengineer.com/1438/wordpress-header/#comments</comments>
		<pubDate>Mon, 13 Jul 2009 13:24:03 +0000</pubDate>
		<dc:creator>Frank</dc:creator>
				<category><![CDATA[WordPress Hacks]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress 2.8]]></category>
		<category><![CDATA[WordPress Themes]]></category>
		<category><![CDATA[WordPress Tutorials]]></category>
		<category><![CDATA[wp2.8]]></category>

		<guid isPermaLink="false">http://wpengineer.com/?p=1438</guid>
		<description><![CDATA[WordPress implements new standard features in the head of the theme since version 2.5, that are always on the hook wp_head. Even in WordPress 2.8 new functions were added. If you don't need them you can easily disable them by using the function remove_action. Function remove_action remove_action( $tag, $function_to_add, $priority, $accepted_args ); This function removes [...]]]></description>
			<content:encoded><![CDATA[<p>WordPress implements new standard features in the head of the theme since version 2.5, that are always on the hook <code>wp_head</code>. Even in WordPress 2.8 new functions were added. If you don't need them you can easily disable them by using the function <a title="Doc in Codex" href="http://codex.wordpress.org/Function_Reference/remove_action"><code>remove_action</code></a>.<br />
<span id="more-1438"></span></p>
<h3>Function <code>remove_action</code></h3>
<p><code>remove_action( $tag, $function_to_add, $priority, $accepted_args );</code></p>
<blockquote><p>This function removes a function attached to a specified action hook. This method can be used to remove default functions attached to a specific action hook and possibly replace them with a substitute.</p>
<p><strong>Important:</strong> To remove a hook, the <code>$function_to_remove</code> and <code>$priority</code> arguments must match when the hook was added. This goes for both filters and actions. No warning will be given on removal failure.<br />
<cite>via: <a href="http://codex.wordpress.org/Function_Reference/remove_action">WP Codexy</a></cite></p></blockquote>
<p>The following syntax shows an excerpt, only a part of the output you can have in your theme. They result from the standard functions, which are loaded in the head of the theme. Visible, if you search in the file <code>wp-includes/default-filters.php</code> for the Hook <code>wp_head</code>. Not all filters should be deactivated, because in most cases they are useful. But WordPress is not only as classical blog in use and therefore some functions are not necessary.</p>
<pre lang="php">
&lt;link rel=&quot;alternate&quot; type=&quot;application/rss+xml&quot; title=&quot;WP Engineer RSS Feed&quot; href=&quot;http://wpengineer.com/feed/&quot; /&gt;
&lt;link rel=&quot;alternate&quot; type=&quot;application/atom+xml&quot; title=&quot;WP Engineer Atom Feed&quot; href=&quot;http://wpengineer.com/feed/atom/&quot; /&gt;
&lt;link rel=&quot;pingback&quot; href=&quot;http://wpengineer.com/blog/xmlrpc.php&quot; /&gt;
&lt;link rel=&quot;EditURI&quot; type=&quot;application/rsd+xml&quot; title=&quot;RSD&quot; href=&quot;http://wpengineer.com/xmlrpc.php?rsd&quot; /&gt;
&lt;link rel=&#039;index&#039; title=&#039;WP Engineer&#039; href=&#039;http://wpengineer.com&#039; /&gt;
&lt;link rel=&#039;start&#039; title=&#039;Use WordPress 2.7 Offline&#039; href=&#039;http://wpengineer.com/use-wordpress-27-offline/&#039; /&gt;
&lt;link rel=&#039;prev&#039; title=&#039;Recents Drafts All Authors&#039; href=&#039;http://wpengineer.com/recents-drafts-all-authors/&#039; /&gt;
</pre>
<p>This is an example, not a recommendation where some functions are deactivated. Check your header and turn off what you don't need. Less markup and better loading time.</p>
<pre lang="php">
remove_action( &#039;wp_head&#039;, &#039;feed_links_extra&#039;, 3 ); // Display the links to the extra feeds such as category feeds
remove_action( &#039;wp_head&#039;, &#039;feed_links&#039;, 2 ); // Display the links to the general feeds: Post and Comment Feed
remove_action( &#039;wp_head&#039;, &#039;rsd_link&#039; ); // Display the link to the Really Simple Discovery service endpoint, EditURI link
remove_action( &#039;wp_head&#039;, &#039;wlwmanifest_link&#039; ); // Display the link to the Windows Live Writer manifest file.
remove_action( &#039;wp_head&#039;, &#039;index_rel_link&#039; ); // index link
remove_action( &#039;wp_head&#039;, &#039;parent_post_rel_link&#039;, 10, 0 ); // prev link
remove_action( &#039;wp_head&#039;, &#039;start_post_rel_link&#039;, 10, 0 ); // start link
remove_action( &#039;wp_head&#039;, &#039;adjacent_posts_rel_link&#039;, 10, 0 ); // Display relational links for the posts adjacent to the current post.
remove_action( &#039;wp_head&#039;, &#039;wp_generator&#039; ); // Display the XHTML generator that is generated on the wp_head hook, WP version
</pre>
<hr /><a href="http://wpplugins.com/plugin/281/snippets" title="More informations about this plugin for WordPress"><img src="http://wpengineer.com/wp-content/themes/wpe-3/images/snippets-125-125.png" height="90" alt="WordPress Snippet Plugin" /></a> <a href="http://xtreme-theme.com"><img src="http://wpengineer.com/wp-content/uploads/feed-banner-2.jpg" alt="Xtreme One WordPress Framework"/></a><br />
&copy; <a href="http://wpengineer.com/">WP Engineer Team</a>, All rights reserved <small>(Digital Fingerprint: WPEngineer-be0254ce2b4972feb4b9cb72034a092d)</small></p>
]]></content:encoded>
			<wfw:commentRss>http://wpengineer.com/1438/wordpress-header/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>More Memory For WordPress &#8211; More Information About WordPress</title>
		<link>http://wpengineer.com/1324/more-memory-for-wordpress-more-information-about-wordpress/</link>
		<comments>http://wpengineer.com/1324/more-memory-for-wordpress-more-information-about-wordpress/#comments</comments>
		<pubDate>Thu, 18 Jun 2009 07:49:26 +0000</pubDate>
		<dc:creator>Frank</dc:creator>
				<category><![CDATA[WordPress Hacks]]></category>
		<category><![CDATA[WordPress Plugins]]></category>
		<category><![CDATA[Plugin]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress 2.8]]></category>
		<category><![CDATA[WordPress Tutorials]]></category>
		<category><![CDATA[WP]]></category>
		<category><![CDATA[wp2.8]]></category>

		<guid isPermaLink="false">http://wpengineer.com/?p=1324</guid>
		<description><![CDATA[WordPress is growing and growing, with the growing of WordPress the demand of memory is also growing. The standard use is WordPress 32MByte (see settings.php ), which is not even provided by every hoster today. This is a problem - therefore: Lovely Hoster, give users more memory! But also to use the memory, it requires [...]]]></description>
			<content:encoded><![CDATA[<p><img src="http://wpengineer.com/wp-content/uploads/wp-system-health.png" alt="wp-system-health" title="wp-system-health" width="300" height="200" class="alignright size-full wp-image-1387" /><br />
WordPress is growing and growing, with the growing of WordPress the demand of memory is also growing. The standard use is WordPress 32MByte (see <code> settings.php </code>), which is not even provided by every hoster today. This is a problem - therefore: Lovely Hoster, give users more memory!</p>
<p>But also to use the memory, it requires a small syntax extension in the configuration of WordPress.<br />
<span id="more-1324"></span><br />
To have a quick overview about the demand: Use the Plugin for WordPress <em><a href="http://alexrabe.boelinger.com/2009/06/14/dear-hoster-we-need-more-memory/">WP-Memory-Usage</a></em> by Alex Rabe ...</p>
<p><img src="http://wpengineer.com/wp-content/uploads/memory-overview.png" alt="memory-overview" title="memory-overview" width="417" height="247" class="aligncenter size-full wp-image-1325" /></p>
<p>...  or the more extensive version of an analysis with the Plugin <a href="http://www.code-styling.de/deutsch/wp-system-health-wie-gehts-meinem-wordpress">WordPress System Health</a> by Heiko Rabe.</p>
<h3>More Information</h3>
<p>Thus, it provides the analysis of blogs and a quick way to see the problems at a customers blog or project of your own. This WordPress Plugin <a href="http://www.code-styling.de/deutsch/wp-system-health-wie-gehts-meinem-wordpress">Health System</a> will not only provide information on the status of WordPress, but will also provide information on important configuration settings, supply information on the state of the database and also the tables and information about PHP. In each mode you can add various details, which provide a lot of information to the WordPress experts about the system without the need to investigate the individual Settings, the PHP and the database information.</p>
<h3>More Memory</h3>
<p>It is recommended when working with WordPress to increase memory, as long the <!--<a href="http://www.webhostingsearch.com/">host</a>--> host permits. This requires the expansion of <code>wp-config.php</code>; the best way is to do it in steps in order to check the possibilities of the host.</p>
<pre lang="php">
// more memory
define(&#039;WP_MEMORY_LIMIT&#039;, &#039;64M&#039;);
// even more memory
define(&#039;WP_MEMORY_LIMIT&#039;, &#039;96M&#039;);
// a good deal more memory <img src='http://wpengineer.com/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' />
define(&#039;WP_MEMORY_LIMIT&#039;, &#039;128M&#039;);
</pre>
<p>Will you get a white page as return, then it was too much and it goes back down to 32 MByte. Good luck.<br />
<hr /><a href="http://wpplugins.com/plugin/281/snippets" title="More informations about this plugin for WordPress"><img src="http://wpengineer.com/wp-content/themes/wpe-3/images/snippets-125-125.png" height="90" alt="WordPress Snippet Plugin" /></a> <a href="http://xtreme-theme.com"><img src="http://wpengineer.com/wp-content/uploads/feed-banner-2.jpg" alt="Xtreme One WordPress Framework"/></a><br />
&copy; <a href="http://wpengineer.com/">WP Engineer Team</a>, All rights reserved <small>(Digital Fingerprint: WPEngineer-be0254ce2b4972feb4b9cb72034a092d)</small></p>
]]></content:encoded>
			<wfw:commentRss>http://wpengineer.com/1324/more-memory-for-wordpress-more-information-about-wordpress/feed/</wfw:commentRss>
		<slash:comments>15</slash:comments>
		</item>
		<item>
		<title>Ping Problem?</title>
		<link>http://wpengineer.com/1322/ping-problem/</link>
		<comments>http://wpengineer.com/1322/ping-problem/#comments</comments>
		<pubDate>Wed, 17 Jun 2009 11:07:36 +0000</pubDate>
		<dc:creator>Frank</dc:creator>
				<category><![CDATA[WordPress Hacks]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress 2.8]]></category>
		<category><![CDATA[WordPress Tutorials]]></category>

		<guid isPermaLink="false">http://wpengineer.com/?p=1322</guid>
		<description><![CDATA[Since version 2.7 of WordPress, there have been several issues that Pingbacks in WordPress don't work. WordPress works with it in the request-function (wp-includes/cron.php), not to be confused with the wp-cron.php. There is a time limit of 0:01 seconds set, which is not sufficient under all conditions. It is known and the developers of WordPress [...]]]></description>
			<content:encoded><![CDATA[<p>Since version 2.7 of WordPress, there have been several issues that Pingbacks in WordPress don't work. WordPress works with it in the request-function (<code>wp-includes/cron.php</code>), not to be confused with the  <code>wp-cron.php</code>. There is a time limit of 0:01 seconds set, which is not sufficient under all conditions. It is known and the developers of WordPress have not changed the entry intentionally, with the reference that it runs smoothly under many configurations, see <a href="http://core.trac.wordpress.org/ticket/8923">Trac ticket 8923</a>. </p>
<p>This problem in 2.8 continues to be an issue in various installations. Who wants to change the value should set it to <em> 1</em>, and should no longer have problems. All other users can only hope that it will be changed in 2.8.1. </p>
<p><strong>Original code  in WordPress 2.8</strong></p>
<pre lang="php">
$cron_url = get_option( &#039;siteurl&#039; ) . &#039;/wp-cron.php?doing_wp_cron&#039;;
wp_remote_post( $cron_url, array(&#039;timeout&#039; =&gt; 0.01, &#039;blocking&#039; =&gt; false, &#039;sslverify&#039; =&gt; apply_filters(&#039;https_local_ssl_verify&#039;, true)) );
</pre>
<p><strong>after change the value</strong></p>
<pre lang="php">
$cron_url = get_option( &#039;siteurl&#039; ) . &#039;/wp-cron.php?doing_wp_cron&#039;;
wp_remote_post( $cron_url, array(&#039;timeout&#039; =&gt; 1, &#039;blocking&#039; =&gt; false, &#039;sslverify&#039; =&gt; apply_filters(&#039;https_local_ssl_verify&#039;, true)) );
</pre>
<hr /><a href="http://wpplugins.com/plugin/281/snippets" title="More informations about this plugin for WordPress"><img src="http://wpengineer.com/wp-content/themes/wpe-3/images/snippets-125-125.png" height="90" alt="WordPress Snippet Plugin" /></a> <a href="http://xtreme-theme.com"><img src="http://wpengineer.com/wp-content/uploads/feed-banner-2.jpg" alt="Xtreme One WordPress Framework"/></a><br />
&copy; <a href="http://wpengineer.com/">WP Engineer Team</a>, All rights reserved <small>(Digital Fingerprint: WPEngineer-be0254ce2b4972feb4b9cb72034a092d)</small></p>
]]></content:encoded>
			<wfw:commentRss>http://wpengineer.com/1322/ping-problem/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		</item>
		<item>
		<title>Set Meta Links For WordPress Plugins</title>
		<link>http://wpengineer.com/1295/meta-links-for-wordpress-plugins/</link>
		<comments>http://wpengineer.com/1295/meta-links-for-wordpress-plugins/#comments</comments>
		<pubDate>Wed, 10 Jun 2009 13:46:01 +0000</pubDate>
		<dc:creator>Frank</dc:creator>
				<category><![CDATA[WordPress Hacks]]></category>
		<category><![CDATA[WordPress Tutorials]]></category>
		<category><![CDATA[development]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Plugin]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress 2.8]]></category>
		<category><![CDATA[WP]]></category>
		<category><![CDATA[wp2.8]]></category>

		<guid isPermaLink="false">http://wpengineer.com/?p=1295</guid>
		<description><![CDATA[In the past I explained in the article &#8222;How To Improve WordPress Plugins&#8220; , how you can expand Plugins with useful functions and therefore optimize their usage. One of the suggestions was a simple link to the options page of your Plugin. With WordPress 2.8 the Plugin page will be a little bit different and [...]]]></description>
			<content:encoded><![CDATA[<p>In the past I explained in the article &#8222;<a href="http://wpengineer.com/how-to-improve-wordpress-plugins/">How To Improve WordPress Plugins</a>&#8220; , how you can expand Plugins with useful functions and therefore optimize their usage. One of the suggestions was a simple link to the options page of your Plugin.<br />
With WordPress 2.8 the Plugin page will be a little bit different and now there will be a hook, which you can use to enter a link, which is even more convenient.<br />
<span id="more-1295"></span><br />
This tutorial works only in Version 2.8 or higher. For 2.7 you have to use the tutorial of &#8222;<a href="http://wpengineer.com/how-to-improve-wordpress-plugins/">How To Improve WordPress Plugins</a>&#8220; or without further explanation this short snippet.</p>
<pre lang="php">
/**
 * @version WP 2.7
 * Add action link(s) to plugins page
 */
function set_plugin_meta27($links) {

	$plugin = plugin_basename(__FILE__);

	$settings_link = sprintf( &#039;&lt;a href=&quot;options-general.php?page=%s&quot;&gt;%s&lt;/a&gt;&#039;, $plugin, __(&#039;Settings&#039;) );
	array_unshift( $links, $settings_link );

	return $links;
}

add_filter( &#039;plugin_action_links_&#039; . $plugin, &#039;set_plugin_meta27&#039; );
</pre>
<p>Since version 2.8 the backend is a little bit different, also the meta links to Plugins are displayed differently from now on, which you can use as you can see on this screenshot.</p>
<p><a href="http://wpengineer.com/wp-content/uploads/28_plugin_meta_link.png"><img src="http://wpengineer.com/wp-content/uploads/28_plugin_meta_link-299x221.png" alt="28_plugin_meta_link" title="28_plugin_meta_link" width="299" height="221" class="aligncenter size-medium wp-image-1296" /></a></p>
<p>You can use following code to set the link to your options page. You can use the term &#8222;Settings&#8220; , so you don't have to take care about other languages, since it is already in the respective language package included. The word will be adjust automatically to the according language.</p>
<pre lang="php">
function set_plugin_meta($links, $file) {

	$plugin = plugin_basename(__FILE__);

	// create link
	if ($file == $plugin) {
		return array_merge(
			$links,
			array( sprintf( &#039;&lt;a href=&quot;options-general.php?page=%s&quot;&gt;%s&lt;/a&gt;&#039;, $plugin, __(&#039;Settings&#039;) ) )
		);
	}

	return $links;
}

add_filter( &#039;plugin_row_meta&#039;, &#039;set_plugin_meta&#039;, 10, 2 );
</pre>
<p>Alternativ you can use the follow functions to link before other links on the plugin page.</p>
<pre lang="php">
// plugin definitions
define( &#039;FB_BASENAME&#039;, plugin_basename( __FILE__ ) );
define( &#039;FB_BASEFOLDER&#039;, plugin_basename( dirname( __FILE__ ) ) );
define( &#039;FB_FILENAME&#039;, str_replace( FB_BASEFOLDER.&#039;/&#039;, &#039;&#039;, plugin_basename(__FILE__) ) );

function filter_plugin_meta($links, $file) {

	/* create link */
	if ( $file == FB_BASENAME ) {
		array_unshift(
			$links,
			sprintf( &#039;&lt;a href=&quot;options-general.php?page=%s&quot;&gt;%s&lt;/a&gt;&#039;, FB_FILENAME, __(&#039;Settings&#039;) )
		);
	}

	return $links;
}

global $wp_version;
if ( version_compare( $wp_version, &#039;2.8alpha&#039;, &#039;&gt;&#039; ) )
	add_filter( &#039;plugin_row_meta&#039;, &#039;filter_plugin_meta&#039;, 10, 2 ); // only 2.8 and higher
add_filter( &#039;plugin_action_links&#039;, &#039;filter_plugin_meta&#039;, 10, 2 );
</pre>
<p>This little hack is easy to do but has a significant value for the user, since it's easy to get to the options page. It's just sad, that the developer of WordPress always changing the hook, so you have to adjust it after every new version. Hope that won't happen again in the near future.<br />
<hr /><a href="http://wpplugins.com/plugin/281/snippets" title="More informations about this plugin for WordPress"><img src="http://wpengineer.com/wp-content/themes/wpe-3/images/snippets-125-125.png" height="90" alt="WordPress Snippet Plugin" /></a> <a href="http://xtreme-theme.com"><img src="http://wpengineer.com/wp-content/uploads/feed-banner-2.jpg" alt="Xtreme One WordPress Framework"/></a><br />
&copy; <a href="http://wpengineer.com/">WP Engineer Team</a>, All rights reserved <small>(Digital Fingerprint: WPEngineer-be0254ce2b4972feb4b9cb72034a092d)</small></p>
]]></content:encoded>
			<wfw:commentRss>http://wpengineer.com/1295/meta-links-for-wordpress-plugins/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>WordPress Proxysupport</title>
		<link>http://wpengineer.com/1227/wordpress-proxysupport/</link>
		<comments>http://wpengineer.com/1227/wordpress-proxysupport/#comments</comments>
		<pubDate>Fri, 15 May 2009 10:58:13 +0000</pubDate>
		<dc:creator>Frank</dc:creator>
				<category><![CDATA[WordPress Hacks]]></category>
		<category><![CDATA[Constants]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[proxy]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress 2.8]]></category>
		<category><![CDATA[WordPress Tutorials]]></category>
		<category><![CDATA[WP]]></category>
		<category><![CDATA[wp2.8]]></category>

		<guid isPermaLink="false">http://wpengineer.com/?p=1227</guid>
		<description><![CDATA[Who is using WordPress in an intranet environment, will quickly realize, that despite internet connection, no feed content gets loaded in the backend. In general, it's because of the proxy of the company. So far WordPress wasn't particularly flexible in this case. As of WordPress 2.8 that will change and new constants make ensure that [...]]]></description>
			<content:encoded><![CDATA[<p>Who is using WordPress in an intranet environment, will quickly realize, that despite internet connection, no feed content gets loaded in the backend. In general, it's because of the proxy of the company. So far WordPress wasn't particularly flexible in this case. As of WordPress 2.8 that will change and new constants make ensure that you now can enter the proxy directly to <code>wp-config.php</code>.<br />
<span id="more-1227"></span></p>
<h3>Until WordPress 2.7</h3>
<p>Up to this version of WordPress it works only with an adjustment in the core, in <code>wp-includes/class-snoopy.php</code>. Here you have to change the settings of <code>$proxy_host</code>, <code>$proxy_port</code> and <code>$_isproxy</code>. The value of var <code>$_isproxy = false;</code> will of course have <code>TRUE</code> as value.</p>
<pre lang="php">
var $host       = &quot;www.php.net&quot;; // host name we are connecting to
var $port       = 8080; // port we are connecting to
var $proxy_host = &quot;&quot;; // proxy host to use
var $proxy_port = &quot;&quot;; // proxy port to use
var $proxy_user = &quot;&quot;; // proxy user to use
var $proxy_pass = &quot;&quot;; // proxy password to use
var $_isproxy   = true; // set if using a proxy server
</pre>
<h3>WordPress 2.8</h3>
<p>With the new version it is much easier, because no more intrusion into the core files is necessary and the possibility to define the values in the configuration file <code>wp-config.php</code>.</p>
<pre lang="php">
define(&#039;WP_PROXY_HOST&#039;, &#039;192.168.84.101&#039;);
define(&#039;WP_PROXY_PORT&#039;, &#039;8080&#039;);
define(&#039;WP_PROXY_USERNAME&#039;, &#039;my_user_name&#039;);
define(&#039;WP_PROXY_PASSWORD&#039;, &#039;my_password&#039;);
define(&#039;WP_PROXY_BYPASS_HOSTS&#039;, &#039;localhost, www.example.com&#039;);
</pre>
<p>Various references are also in<a href="http://core.trac.wordpress.org/ticket/4011">Ticket 4011</a>.<br />
<hr /><a href="http://wpplugins.com/plugin/281/snippets" title="More informations about this plugin for WordPress"><img src="http://wpengineer.com/wp-content/themes/wpe-3/images/snippets-125-125.png" height="90" alt="WordPress Snippet Plugin" /></a> <a href="http://xtreme-theme.com"><img src="http://wpengineer.com/wp-content/uploads/feed-banner-2.jpg" alt="Xtreme One WordPress Framework"/></a><br />
&copy; <a href="http://wpengineer.com/">WP Engineer Team</a>, All rights reserved <small>(Digital Fingerprint: WPEngineer-be0254ce2b4972feb4b9cb72034a092d)</small></p>
]]></content:encoded>
			<wfw:commentRss>http://wpengineer.com/1227/wordpress-proxysupport/feed/</wfw:commentRss>
		<slash:comments>13</slash:comments>
		</item>
		<item>
		<title>WordPress 2.8 Feature Password</title>
		<link>http://wpengineer.com/1211/wordpress-28-feature-password/</link>
		<comments>http://wpengineer.com/1211/wordpress-28-feature-password/#comments</comments>
		<pubDate>Tue, 05 May 2009 21:14:16 +0000</pubDate>
		<dc:creator>Frank</dc:creator>
				<category><![CDATA[WordPress News]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress 2.8]]></category>
		<category><![CDATA[WP]]></category>
		<category><![CDATA[wp2.8]]></category>

		<guid isPermaLink="false">http://wpengineer.com/?p=1211</guid>
		<description><![CDATA[WordPress 2.8 is going to be published soon, even though they do not have a date yet. Nevertheless, another small insight into a new feature. After a new installation of WordPress, you get informed that you are logged in with the default password and this can be a security risk. It is therefore strongly recommended [...]]]></description>
			<content:encoded><![CDATA[<p>WordPress 2.8 is going to be published soon, even though they do not have a date yet. Nevertheless, another small insight into a new feature. After a new installation of WordPress, you get informed that you are logged in with the default password and this can be a <a href="http://perishablepress.com/press/2009/05/05/important-security-fix-for-wordpress/">security risk</a>. It is therefore strongly recommended to change the password. The necessary internal links to set a new password are included in this notice.</p>
<p><a href="http://wpengineer.com/wp-content/uploads/wp28_passwort.png"><img src="http://wpengineer.com/wp-content/uploads/wp28_passwort-300x47.png" alt="wp28_passwort" title="wp28_passwort" width="300" height="47" class="aligncenter size-medium wp-image-1210" /></a><br />
<hr /><a href="http://wpplugins.com/plugin/281/snippets" title="More informations about this plugin for WordPress"><img src="http://wpengineer.com/wp-content/themes/wpe-3/images/snippets-125-125.png" height="90" alt="WordPress Snippet Plugin" /></a> <a href="http://xtreme-theme.com"><img src="http://wpengineer.com/wp-content/uploads/feed-banner-2.jpg" alt="Xtreme One WordPress Framework"/></a><br />
&copy; <a href="http://wpengineer.com/">WP Engineer Team</a>, All rights reserved <small>(Digital Fingerprint: WPEngineer-be0254ce2b4972feb4b9cb72034a092d)</small></p>
]]></content:encoded>
			<wfw:commentRss>http://wpengineer.com/1211/wordpress-28-feature-password/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
		</item>
		<item>
		<title>WordPress Plugin-Path</title>
		<link>http://wpengineer.com/1134/wordpress-plugin-path/</link>
		<comments>http://wpengineer.com/1134/wordpress-plugin-path/#comments</comments>
		<pubDate>Mon, 27 Apr 2009 13:26:26 +0000</pubDate>
		<dc:creator>Frank</dc:creator>
				<category><![CDATA[WordPress Hacks]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Plugin]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress 2.8]]></category>
		<category><![CDATA[WordPress Plugins]]></category>
		<category><![CDATA[WordPress Tutorials]]></category>
		<category><![CDATA[WP]]></category>
		<category><![CDATA[wp2.7]]></category>
		<category><![CDATA[wp2.8]]></category>

		<guid isPermaLink="false">http://wpengineer.com/?p=1134</guid>
		<description><![CDATA[When working on a Plugin I noticed that the path to its files is not always complete, which depends on the WordPress version. With WordPress Version 2.8 the function plugins_url() extends and it can be incorporate in a much cleaner way, no maintenance of the folder required, where the Plugin is put. An example will [...]]]></description>
			<content:encoded><![CDATA[<p>When working on a Plugin I noticed that the path to its files is not always complete, which depends on the WordPress version.<br />
With WordPress <strong>Version 2.8</strong> the function <code>plugins_url()</code> extends and it can be incorporate in a much cleaner way, no maintenance of the folder required, where the Plugin is put. An example will illustrate it and possibly will help the one or other author at his work.<br />
<span id="more-1134"></span><br />
In the articles &#8222;<a href="http://wpengineer.com/use-javascript-libraries-in-and-of-wordpress/">Use JavaScript Libraries In And Of WordPress</a>&#8220;, &#8222;<a href="http://wpengineer.com/top-level-menu-in-wordpress-27/">Top Level Menu In WordPress 2.7</a>&#8220; and &#8222;<a href="http://wpengineer.com/wordpress-return-url/">WordPress - Return URL</a>&#8220; I often have the function <code>plugins_url()</code>, because it delivers very nice the path.</p>
<p>As of WordPress version 2.8 the function can take two parameters:</p>
<pre lang="php">
/**
 * @param string $path Optional. Path relative to the plugins url.
 * @param string $plugin Optional. The plugin file that you want to be relative to - i.e. pass in __FILE__
 * @return string Plugins url link with optional path appended.
*/
function plugins_url($path = &#039;&#039;, $plugin = &#039;&#039;)
</pre>
<p>So far only the $ path parameter could be passed, so that required a proper definition of the folder.</p>
<pre lang="php">
$style = plugins_url( &#039;my_plugin_folder/css/style-frontend.css&#039; );
</pre>
<p>With the extension in version 2.8 of WordPress it can be done like:</p>
<pre lang="php">
$style = plugins_url( &#039;css/style-frontend.css&#039;, __FILE__ );
</pre>
<p>The use should make it simpler and clearer. But the question will come up, how do I do backwards compatibility of the plugin? You can either use the version query:</p>
<pre lang="php">
if ( version_compare( $wp_version, &#039;2.8dev&#039;, &#039;&gt;&#039; ) )
</pre>
<p>and then supplement or write a custom function for the replacement:</p>
<pre lang="php">
// function for WP &lt; 2.8
function plugins_url($path = &#039;&#039;, $plugin = &#039;&#039;) {
  if ( function_exists(&#039;is_ssl&#039;) )
    $scheme = ( is_ssl() ? &#039;https&#039; : &#039;http&#039; );
  else
    $scheme = &#039;http&#039;;
  $url = WP_PLUGIN_URL;
  if ( 0 === strpos($url, &#039;http&#039;) ) {
    if ( function_exists(&#039;is_ssl&#039;) &amp;&amp; is_ssl() )
      $url = str_replace( &#039;http://&#039;, &quot;{$scheme}://&quot;, $url );
  }

  if ( !empty($plugin) &amp;&amp; is_string($plugin) )
  {
    $folder = dirname(plugin_basename($plugin));
    if (&#039;.&#039; != $folder)
      $url .= &#039;/&#039; . ltrim($folder, &#039;/&#039;);
  }

  if ( !empty($path) &amp;&amp; is_string($path) &amp;&amp; strpos($path, &#039;..&#039;) === false )
    $url .= &#039;/&#039; . ltrim($path, &#039;/&#039;);

  return apply_filters(&#039;plugins_url&#039;, $url, $path, $plugin);
}
</pre>
<p>This is only an alternative, the possibilities are endless - maybe one or the other has a beautiful idea and solution?<br />
<hr /><a href="http://wpplugins.com/plugin/281/snippets" title="More informations about this plugin for WordPress"><img src="http://wpengineer.com/wp-content/themes/wpe-3/images/snippets-125-125.png" height="90" alt="WordPress Snippet Plugin" /></a> <a href="http://xtreme-theme.com"><img src="http://wpengineer.com/wp-content/uploads/feed-banner-2.jpg" alt="Xtreme One WordPress Framework"/></a><br />
&copy; <a href="http://wpengineer.com/">WP Engineer Team</a>, All rights reserved <small>(Digital Fingerprint: WPEngineer-be0254ce2b4972feb4b9cb72034a092d)</small></p>
]]></content:encoded>
			<wfw:commentRss>http://wpengineer.com/1134/wordpress-plugin-path/feed/</wfw:commentRss>
		<slash:comments>6</slash:comments>
		</item>
		<item>
		<title>WordPress 2.8 Insights, The Favorite Actions</title>
		<link>http://wpengineer.com/1139/wordpress-28-insights-favorite-actions/</link>
		<comments>http://wpengineer.com/1139/wordpress-28-insights-favorite-actions/#comments</comments>
		<pubDate>Fri, 24 Apr 2009 15:59:49 +0000</pubDate>
		<dc:creator>Frank</dc:creator>
				<category><![CDATA[WordPress News]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress 2.8]]></category>

		<guid isPermaLink="false">http://wpengineer.com/?p=1139</guid>
		<description><![CDATA[The new version of WordPress is in the starting blocks and got new features this week which is not immediately noticable, it affects the favorites in the header of your backend. The favorites are changing from 2.8 in dependence of the page that you are using. I hope the screenshot shows it. Also the Plugin [...]]]></description>
			<content:encoded><![CDATA[<p>The new version of WordPress is in the starting blocks and got new features this week which is not immediately noticable, it affects the favorites in the header of your backend.</p>
<p>The favorites are changing from 2.8 in dependence of the page that you are using. I hope the screenshot shows it.<br />
<a href="http://wpengineer.com/wp-content/uploads/wp28_fav-actions.png"><img src="http://wpengineer.com/wp-content/uploads/wp28_fav-actions-300x122.png" alt="wp28_fav-actions" title="wp28_fav-actions" width="300" height="122" class="aligncenter size-medium wp-image-1140" /></a></p>
<p>Also the Plugin page was revised. From version 2.8 on, WordPress saves user behaviors and hence you are always in the area that you used the last time - definitely an added value.<br />
This applies also for the comment administration. In addition, the Plugin page has changed completely, so that you get an own summary on various topics.<br />
<a href="http://wpengineer.com/wp-content/uploads/wp28_manage_plugins.png"><img src="http://wpengineer.com/wp-content/uploads/wp28_manage_plugins-300x243.png" alt="wp28_manage_plugins" title="wp28_manage_plugins" width="300" height="243" class="aligncenter size-medium wp-image-1142" /></a><br />
<hr /><a href="http://wpplugins.com/plugin/281/snippets" title="More informations about this plugin for WordPress"><img src="http://wpengineer.com/wp-content/themes/wpe-3/images/snippets-125-125.png" height="90" alt="WordPress Snippet Plugin" /></a> <a href="http://xtreme-theme.com"><img src="http://wpengineer.com/wp-content/uploads/feed-banner-2.jpg" alt="Xtreme One WordPress Framework"/></a><br />
&copy; <a href="http://wpengineer.com/">WP Engineer Team</a>, All rights reserved <small>(Digital Fingerprint: WPEngineer-be0254ce2b4972feb4b9cb72034a092d)</small></p>
]]></content:encoded>
			<wfw:commentRss>http://wpengineer.com/1139/wordpress-28-insights-favorite-actions/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>WordPress 2.8 &#8211; Small Insights</title>
		<link>http://wpengineer.com/980/wordpress-28-small-insights/</link>
		<comments>http://wpengineer.com/980/wordpress-28-small-insights/#comments</comments>
		<pubDate>Mon, 23 Mar 2009 12:46:09 +0000</pubDate>
		<dc:creator>Frank</dc:creator>
				<category><![CDATA[WordPress News]]></category>
		<category><![CDATA[WordPress]]></category>
		<category><![CDATA[WordPress 2.8]]></category>
		<category><![CDATA[WP]]></category>
		<category><![CDATA[wp2.8]]></category>

		<guid isPermaLink="false">http://wpengineer.com/?p=980</guid>
		<description><![CDATA[WordPress sticks to the publication date in April this year. In advance, I would like to briefly mention some innovations, which from my personal point of view are quite exciting. New Template Tag: the_modified_author() In the use of different authors long awaited, in 2.8 available Widget API Widgets have been loved by most users and [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignright size-full" title="wordpress" src="http://wpengineer.com/wp-content/uploads/wordpress-grey.jpg" alt="wordpress" width="150" height="150" /><br />
WordPress sticks to the publication date in April this year. In advance, I would like to briefly mention some innovations, which from my personal point of view are quite exciting.</p>
<ul>
<li>New Template Tag: <a href="http://codex.wordpress.org/Template_Tags/the_modified_author"><code>the_modified_author()</code></a><br />
In the use of different authors long awaited, in 2.8 available</li>
<li><a href="http://core.trac.wordpress.org/ticket/8441">Widget API</a><br />
Widgets have been loved by most users and tolerated by developers. The new API will simplify it and the access to the <a href="http://xref.yoast.com/trunk/nav.html?_functions/wp_widget.html">class</a> makes this possible. This means that multiple instances now finally possible.</li>
<li><a href="http://wpdevel.wordpress.com/2008/12/27/optimizing-script-loading/">Optimized loading of JavaScript </a><br />
Since 2.7 is clean and checked loading of JS involved. <a href="http://wpengineer.com/use-javascript-libraries-in-and-of-wordpress/">Additional functions</a> provide a control of the loading process and dependency. Now, via WordPress, scripts are going to summarized and returned in a single call. You can also include scripts in the footer now, directly through the targeted functions.</li>
<li>More options, when making the frontend, with the new Template Tag <a href="http://wpengineer.com/wordpress-28-body_class-automatic_feed_links/"><code>body_class()</code></a></li>
<li><a href="http://xref.yoast.com/trunk/nav.html?_functions/simplepie.html">SimplePie in Core</a><br />
With version 2.8 <a href="http://magpierss.sourceforge.net/">Magpie</a> is removed and the well-known <a href="http://simplepie.org/">SimplePie</a> project comes into the core; in my view in relation to use of feeds, especially in the ATOM standard, a lot more comfortable.</li>
</ul>
<h3>What are your most exciting innovations in 2.8?</h3>
<hr /><a href="http://wpplugins.com/plugin/281/snippets" title="More informations about this plugin for WordPress"><img src="http://wpengineer.com/wp-content/themes/wpe-3/images/snippets-125-125.png" height="90" alt="WordPress Snippet Plugin" /></a> <a href="http://xtreme-theme.com"><img src="http://wpengineer.com/wp-content/uploads/feed-banner-2.jpg" alt="Xtreme One WordPress Framework"/></a><br />
&copy; <a href="http://wpengineer.com/">WP Engineer Team</a>, All rights reserved <small>(Digital Fingerprint: WPEngineer-be0254ce2b4972feb4b9cb72034a092d)</small></p>
]]></content:encoded>
			<wfw:commentRss>http://wpengineer.com/980/wordpress-28-small-insights/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		</item>
	</channel>
</rss>

