<?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>Interactive Llama :: Interactive media tutorials and tips &#187; plug_in</title>
	<atom:link href="http://www.interactivellama.com/blog/archives/tag/plug_in/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.interactivellama.com/blog</link>
	<description>Interactive media tutorials and tips</description>
	<lastBuildDate>Wed, 23 Nov 2011 15:25:27 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.3</generator>
		<item>
		<title>Change media and images to full size in WordPress media gallery</title>
		<link>http://www.interactivellama.com/blog/archives/change-media-and-images-to-full-size-in-wordpress-media-gallery/</link>
		<comments>http://www.interactivellama.com/blog/archives/change-media-and-images-to-full-size-in-wordpress-media-gallery/#comments</comments>
		<pubDate>Thu, 22 May 2008 00:15:09 +0000</pubDate>
		<dc:creator>Stephen James</dc:creator>
				<category><![CDATA[Blogging]]></category>
		<category><![CDATA[HTML and CSS]]></category>
		<category><![CDATA[Productivity & Workflow]]></category>
		<category><![CDATA[blog]]></category>
		<category><![CDATA[gallery]]></category>
		<category><![CDATA[image width]]></category>
		<category><![CDATA[maximum image size]]></category>
		<category><![CDATA[photo]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[plug_in]]></category>
		<category><![CDATA[Rachel Steely]]></category>
		<category><![CDATA[themes]]></category>
		<category><![CDATA[upgrade]]></category>
		<category><![CDATA[web design]]></category>
		<category><![CDATA[wordpress]]></category>
		<category><![CDATA[Workflow]]></category>

		<guid isPermaLink="false">/blog/?p=122</guid>
		<description><![CDATA[I&#8217;ve been familiarizing myself with WordPress 2.5&#8242;s new media gallery. If you&#8217;ve visited my blog before, you know I don&#8217;t upload many images, but I&#8217;m hoping to upload many images to my wife, Rachel Steely&#8217;s website. I was annoyed to find out that the default image posting size is medium (which is about 300px). On [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been familiarizing myself with WordPress 2.5&#8242;s new media gallery. If you&#8217;ve visited my blog before, you know I don&#8217;t upload many images, but I&#8217;m hoping to upload many images to my wife, <a href="http://www.rachelsteely.com">Rachel Steely&#8217;s website</a>. I was annoyed to find out that the default image posting size is medium (which is about 300px). On top of that, if you select full size, it doesn&#8217;t mean full size. It means your WordPress theme&#8217;s column width. So unless you are using Kubrick your media size will not be your column width.<span id="more-122"></span></p>
<p><strong>Change Full Size image width to match theme</strong></p>
<p>The column width in WordPress&#8217;s default theme Kubrick is 500px. Therefore, the default (maximum) image size is 500px. The column width of the blog I am posting to is 614px. You can set a global variable to change this setting. Create if not already existing functions.php in your theme directory. Define your maximum media width (that is &#8220;Full Size&#8221; in the Gallery interface):<br />
<code><br />
&lt;?php<br />
$content_width = 614;<br />
?&gt;</code></p>
<p>I&#8217;ve set mine to 614 pixels since that is the width of my div with the class  &#8220;.entry&#8221; minus padding. If this does not work, some have solved this problem with $GLOBALS['content_width'] = 614; also. You can view this setting at a post at <a href="http://www.rachelsteely.com/blog/photos-from-wheeler-spring-open-house/">RachelSteely.com</a>.</p>
<p><strong>Default media to Full Size</strong></p>
<p>I prefer to justify my media (align left and right) to the column width. To do this, set default selected size to &#8220;Full Size&#8221; by changing the code in /wp-admin/includes/media.php. Move the &#8216;checked&#8217; radio attribute from Medium to Full Size.</p>
<p>Line 458:<br />
<code><br />
" : '' ) . "&lt;input type='radio' name='attachments[$post-&gt;ID][image-size]' id='image-size-medium-$post-&gt;ID' value='medium' checked='checked' /&gt;<br />
&lt;label for='image-size-medium-$post-&gt;ID'&gt;" . __('Medium') . "&lt;/label&gt;<br />
&lt;input type='radio' name='attachments[$post-&gt;ID][image-size]' id='image-size-full-$post-&gt;ID' value='full' /&gt;<br />
</code></p>
<p>change to<br />
<code><br />
" : '' ) . "&lt;input type='radio' name='attachments[$post-&gt;ID][image-size]' id='image-size-medium-$post-&gt;ID' value='medium' /&gt;<br />
&lt;label for='image-size-medium-$post-&gt;ID'&gt;" . __('Medium') . "&lt;/label&gt;<br />
&lt;input type='radio' name='attachments[$post-&gt;ID][image-size]' id='image-size-full-$post-&gt;ID' value='full' checked='checked' /&gt;</code></p>
<p>And that&#8217;s it! Happy uploading with the new and improved (and customized) WordPress media gallery.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.interactivellama.com/blog/archives/change-media-and-images-to-full-size-in-wordpress-media-gallery/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>Ignore reply tweets and SEO URLs with Twitter Tools WordPress Plug-in</title>
		<link>http://www.interactivellama.com/blog/archives/ignore-direct-tweets-and-seo-urls-with-twitter-tools-wordpress-plug-in/</link>
		<comments>http://www.interactivellama.com/blog/archives/ignore-direct-tweets-and-seo-urls-with-twitter-tools-wordpress-plug-in/#comments</comments>
		<pubDate>Thu, 27 Mar 2008 04:20:09 +0000</pubDate>
		<dc:creator>Stephen James</dc:creator>
				<category><![CDATA[Blogging]]></category>
		<category><![CDATA[Current Events]]></category>
		<category><![CDATA[Productivity & Workflow]]></category>
		<category><![CDATA[Search Engine Optimization]]></category>
		<category><![CDATA[Social Networks]]></category>
		<category><![CDATA[blog]]></category>
		<category><![CDATA[plugin]]></category>
		<category><![CDATA[plug_in]]></category>
		<category><![CDATA[twitter]]></category>
		<category><![CDATA[wordpress]]></category>

		<guid isPermaLink="false">/blog/archives/ignore-direct-tweets-and-seo-urls-with-twitter-tools-wordpress-plug-in/</guid>
		<description><![CDATA[It&#8217;s been a hot debate over what to include in your blog&#8217;s RSS recently. I say you should include more than blog posts in your RSS feed IF (and this is a big if) you can editorialize what goes in. The following, explains how to change which tweets from Twitter get posted to your blog [...]]]></description>
			<content:encoded><![CDATA[<p>It&#8217;s been a hot debate over what to include in your blog&#8217;s RSS recently. I say you should include more than blog posts in your RSS feed IF (and this is a big if) you can editorialize what goes in. The following, explains how to change which tweets from Twitter get posted to your blog and into your RSS feed.</p>
<p>If you use Alex King&#8217;s <a href="http://alexking.org/projects/wordpress">Twitter Tools</a> (version: 1.1b1), you will want to make the following two changes to his code. The first one will make your tweet-post URLs and title more beautiful and SEO friendly by not splitting words at the end. The second one will remove reply tweets (&#8216;@username&#8217;) from becoming posts in your blog, so that half-conversations do not get recorded.<span id="more-120"></span></p>
<p>In Alex King&#8217;s purpose, Twitter Tools is an archiving tool that saves tweets into his blog. If you use version: 1.2b1, then Twitter Tools can <em>hide</em> reply tweets (those beginning with &#8216;@&#8217;) from displaying in the Twitter Tools sidebar widget, but <em>it will still save every tweet as a blog post</em>. In my purpose of Twitter Tools, I do not want to save (and thus post) tweets that begin with &#8216;@.&#8217; Therefore you will still need to add the additions to the do_tweet_post function below. If you do not, all tweets will end up in your RSS feed as blog posts.</p>
<p><strong>Let&#8217;s not mince words here</strong></p>
<p>If you link your tweets and publish them in your RSS feed, you may have noticed that Twitter Tools trims tweets at 30 characters and usually cuts off a title mid-word. It would be better to index to the previous space and trim the post-slug there. Replacing the code of the function, <strong>trim_add_elipsis</strong> (at about line 1030 in twitter-tools.php, before function ak_gmmktime()) with the code that follows will do this:</p>
<pre><code>if (!function_exists('trim_add_elipsis')) {
// smjdesign edit begin - - - - - - - - - - - - - - - - - - - - - - - - - - - -
function trim_add_elipsis($string, $limit = 100) {
// shorten string
$string = substr($string, 0, $limit);
//find last space character
$max_char_pos = strrpos($string, ' ');
// shorten to last space and add ellipsis
if ($max_char_pos &gt; 0)    { $string = substr($string, 0, $max_char_pos)."..."; }
return $string;
}
// smjdesign edit end - - - - - - - - - - - - - - - - - - - - - - - - - - - -</code></pre>
<p><em>As a bonus, </em>I&#8217;ll tell you were you can change the length of the title, too. It&#8217;s around line 205 within the do_tweet_post function. Look for a &#8217;30&#8242; at the end of a line containing &#8220;trim_add_elipsis&#8221; Change the &#8217;30&#8242; to something larger, for instance 40 or 50.</p>
<p><strong>When indirect communication is preferred </strong></p>
<p><em>UPDATE: Alex has made ignoring reply tweets (beginning with &#8216;@&#8217;) a standard option within Twitter Tools. However, I still recommend changing the trim size as I mention above.</em></p>
<p>I can&#8217;t imagine using Twitter Tools without the following change. If not made, one will be listing half conversations in their blog. In order to ignore direct tweets (or more specifically tweets that start with &#8216;@&#8217;), edit the following code at the end of the <strong>do_tweet_post</strong> function (at about line 215 in twitter-tools.php):</p>
<pre><code>function do_tweet_post($tweet) {
global $wpdb;
remove_action('publish_post', 'aktt_notify_twitter');
$data = array(
'post_content' =&gt; $wpdb-&gt;escape(aktt_make_clickable($tweet-&gt;tw_text))
// smjdesign edit begin - - - - - - - - - - - - - - - - - - - - - - - - - - - -
, 'post_title' =&gt; $wpdb-&gt;escape(trim_add_elipsis($tweet-&gt;tw_text, 40))
// smjdesign edit end - - - - - - - - - - - - - - - - - - - - - - - - - - - -
, 'post_date' =&gt; get_date_from_gmt(date('Y-m-d H:i:s', $tweet-&gt;tw_created_at))
, 'post_category' =&gt; array($this-&gt;blog_post_category)
, 'post_status' =&gt; 'publish'
, 'post_author' =&gt; $wpdb-&gt;escape($this-&gt;blog_post_author)
);
// smjdesign edit begin - - - - - - - - - - - - - - - - - - - - - - - - - - - -
if(substr($data["post_content"], 0, 1) != '@') {
$post_id = wp_insert_post($data);
add_post_meta($post_id, 'aktt_twitter_id', $tweet-&gt;tw_id, true);
wp_set_post_tags($post_id, $this-&gt;blog_post_tags);
}
// smjdesign edit end - - - - - - - - - - - - - - - - - - - - - - - - - - - -
add_action('publish_post', 'aktt_notify_twitter');
}</code></pre>
<p>As always, you can email me from <a href="http://www.smjdesign.com/rachelandstephen/contact-rachel-steely-and-stephen-james/">the contact page</a> and ask me for the entire PHP file if you do not feel comfortable editing the file yourself.</p>
]]></content:encoded>
			<wfw:commentRss>http://www.interactivellama.com/blog/archives/ignore-direct-tweets-and-seo-urls-with-twitter-tools-wordpress-plug-in/feed/</wfw:commentRss>
		<slash:comments>7</slash:comments>
		</item>
	</channel>
</rss>

