<?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>Orang IT Indonesia &#187; wp hacks</title>
	<atom:link href="http://www.orangit.com/tag/wp-hacks/feed" rel="self" type="application/rss+xml" />
	<link>http://www.orangit.com</link>
	<description>A Blog Written By Ahlul Faradish Resha, S.Si</description>
	<lastBuildDate>Sun, 25 Mar 2012 08:09:01 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>WP-Hacks: Fetch Post Via Email and put in any category</title>
		<link>http://www.orangit.com/2010/01/24/wp-hacks-fetch-post-via-email-and-put-in-any-category.html</link>
		<comments>http://www.orangit.com/2010/01/24/wp-hacks-fetch-post-via-email-and-put-in-any-category.html#comments</comments>
		<pubDate>Sun, 24 Jan 2010 11:58:29 +0000</pubDate>
		<dc:creator>Ahlul</dc:creator>
				<category><![CDATA[Inovasi]]></category>
		<category><![CDATA[Khas Ahlul]]></category>
		<category><![CDATA[Lagi Iseng]]></category>
		<category><![CDATA[Pemograman]]></category>
		<category><![CDATA[Tips & Trick]]></category>
		<category><![CDATA[Tutorial]]></category>
		<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[hacks]]></category>
		<category><![CDATA[trick]]></category>
		<category><![CDATA[wp hacks]]></category>

		<guid isPermaLink="false">http://ahlul.web.id/blog/?p=698</guid>
		<description><![CDATA[[postnotice] Sometime you would like to send the post via email because it easier and simply. For long time ago, wordpress has support this function. But almost of wordpress user didn&#8217;t know about that. Ok before make some hacks please follow this instruction if you don&#8217;t know about post via email settings. Go to Settings [...]]]></description>
			<content:encoded><![CDATA[<p>[postnotice]</p>
<p>Sometime you would like to send the post via email because it easier and simply.</p>
<p>For long time ago, wordpress has support this function. But almost of wordpress user didn&#8217;t know about that.</p>
<p>Ok before make some hacks <img src='http://www.orangit.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' />  please follow this instruction if you don&#8217;t know about post via email settings.</p>
<ol>
<li>Go to <strong>Settings &gt;Writing</strong> ([domain]/wp-admin/options-writing.php)</li>
<li>Please see at &#8220;<strong>Post Via E-Mail</strong>&#8221; section.</li>
<li>Enter all information needed, such as: your mail server, mail username, password.<br />
FYI: for google account you can use mail server: <strong>ssl://pop.gmail.com</strong>, and port <strong>995</strong>.</li>
<li>After all mail settings is filled, you can select default category for the fetched post.</li>
</ol>
<p>Ok, let do some test <img src='http://www.orangit.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>Send and email to the email account that you set in post via email settings.</p>
<p>After your mail is sent, please access wp-mail.php. You can find it at: [domain]/wp-mail.php.<br />
If success, you should see some fetching process.</p>
<p>Now, look at your posts <img src='http://www.orangit.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' />  if success it must saved and listed. But for first post from that mail you have to approve it manually.</p>
<p><strong>NOW LET MAKE SOME HACKS <img src='http://www.orangit.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </strong></p>
<p>When you post is successful fetched, the post category is match with default category that you set before.</p>
<p>I think at your mind there is a question: how make the category as you need?</p>
<p><em>Let&#8217;s I answer that question:</em></p>
<p>Go to your file manager of your hosting, and edit file wp-mail.php (you can find it at main directory of wordpress installation).<br />
If you not have file manager you can use FTP for download and edit that file.</p>
<p>Find the below line:</p>
<p><code>$post_category = array(get_option('default_email_category'));</code></p>
<p>And, change it to:</p>
<p><code>$arr_pt = explode(":",$post_title);<br />
$cat_ID = get_cat_ID($arr_pt[0]);<br />
if($cat_ID) {<br />
$post_category = $cat_ID;<br />
$post_title = $arr_pt[1];<br />
} else {<br />
$post_category = array(get_option('default_email_category'));<br />
}</code></p>
<p>Yap done <img src='http://www.orangit.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p><strong>HOW IT WORKS?</strong></p>
<p>Technically, Mail Subject will be as Post Title for fetched post.</p>
<p>Now with this hack, you can use this format for mail subject:</p>
<p><strong>Category Name:This dummy title for fetched post via email</strong></p>
<p>Please see &#8220;:&#8221; between category name and post title. It use as separator for this case.</p>
<p>Now you can try it <img src='http://www.orangit.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
<p>And for last to do, <strong>don&#8217;t forget to set a cronjob for automation mail fetch</strong>.</p>
<p>In many case you can use this command:</p>
<p><code>GET http://yourdomain.com/wp-mail.php</code></p>
<p>If you use Windows Hosting I think you can use other wordpress plugin that support for emulate a cronjob.</p>
<p><strong>NEED SUPPORT?</strong></p>
<p>He2, if you still have the problem or found it not works for you, please don&#8217;t hesitate to contact me at ceo.ahlul[at]yahoo.com</p>
<p>&#8212;&#8212;&#8212;&#8212;&#8211;</p>
<p>Now you can post anywhere from your phone (with send mail support) <img src='http://www.orangit.com/wp-includes/images/smilies/icon_wink.gif' alt=';)' class='wp-smiley' /> </p>
]]></content:encoded>
			<wfw:commentRss>http://www.orangit.com/2010/01/24/wp-hacks-fetch-post-via-email-and-put-in-any-category.html/feed</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
	</channel>
</rss>

