<?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>Narga &#187; wordpress tips and tricks</title>
	<atom:link href="http://www.narga.net/tag/wordpress-tips-and-tricks/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.narga.net</link>
	<description>Narga - Ideas and inspiration in my opinion!</description>
	<lastBuildDate>Wed, 18 Jan 2012 20:20:37 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=</generator>
	<atom:link rel='hub' href='http://www.narga.net/?pushpress=hub'/>
		<item>
		<title>How to hide The WordPress Stats Smiley Face</title>
		<link>http://www.narga.net/how-to-hide-the-wordpress-stats-smiley-face/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=how-to-hide-the-wordpress-stats-smiley-face</link>
		<comments>http://www.narga.net/how-to-hide-the-wordpress-stats-smiley-face/#comments</comments>
		<pubDate>Wed, 18 Jan 2012 20:20:37 +0000</pubDate>
		<dc:creator>Narga</dc:creator>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[wordpress tips and tricks]]></category>

		<guid isPermaLink="false">http://www.narga.net/?p=1</guid>
		<description><![CDATA[Automattic just released a collection of plugins as one “super-plugin” called Jetpack. As they explained it, the goal was to bring eight of the most requested features available on WordPress.com to the millions of self-hosted WordPress sites in one easy-to-install curated package. If you use JetPack Stats on your site (formerly released as a stand alone plugin called WordPress.com stats), you may be familiar with the smiley face image   that it adds to the bottom of every page on your site.]]></description>
			<content:encoded><![CDATA[<p><strong>Automattic</strong> just released a collection of plugins as one “super-plugin” called Jetpack. As they explained it, the goal was to bring eight of the most requested features available on WordPress.com to the millions of self-hosted WordPress sites in one easy-to-install curated package. If you use JetPack Stats on your site (formerly released as a stand alone plugin called WordPress.com stats), you may be familiar with the smiley face image <img class="stats-smiley" src="http://www.narga.net/wp-content/plugins/jetpack/_inc/images/stats-smiley.gif" alt="Smiley face" width="6" height="5" /> face that it adds to the bottom of every page on your site.<br />
The smiley was added as a visual way to ensure the stats are tracking and is not something that can be removed directly from the plugin code. Like many other bloggers I do like the WordPress stats service but I'm not a huge fan of it so I looked into how you can remove it. Simplest way to remove it is to go into your themes style sheet (style.css) and put the following code snippet:</p>
<pre class="brush: css; light: true; title: ; notranslate">img#wpstats{width:0px;height:0px;padding:0px;border:none;overflow:hidden}</pre>
<p>If you’re using THESIS, just head to custom.css and paste in;</p>
<pre class="brush: css; light: true; title: ; notranslate">.custom img#wpstats{width:0px;height:0px;padding:0px;border:none;overflow:hidden}</pre>
<p>Thankfully, the recent release of JetPack addressed this issue. If you go to the configuration page for JetPack stats</p>
<pre class="brush: php; light: true; title: ; notranslate">http://www.yoursite.com/wp-admin/admin.php?page=jetpack&amp;configure=stats</pre>
<p>you will now see an option to hide the smiley image.</p>
<p><div id="attachment_2753" class="wp-caption aligncenter" style="width: 559px"><img class="size-medium wp-image-2753" title="Jetpack WordPress.com Stats Configuration" src="http://www.narga.net/wp-content/uploads/2011/10/Jetpack-Wordpress.com-Stats-Configuration-549x380.png" alt="Jetpack WordPress.com Stats Configuration" width="549" height="380" /><p class="wp-caption-text">Jetpack WordPress.com Stats Configuration</p></div><br />
So now you know how to remove the WordPress Stats smiley face. The question is, do you really want to?!</p>
]]></content:encoded>
			<wfw:commentRss>http://www.narga.net/how-to-hide-the-wordpress-stats-smiley-face/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to List most recent comments and recent post on your wordpress themes</title>
		<link>http://www.narga.net/how-to-list-most-recent-comments-and-recent-post-on-your-wordpress-themes/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=how-to-list-most-recent-comments-and-recent-post-on-your-wordpress-themes</link>
		<comments>http://www.narga.net/how-to-list-most-recent-comments-and-recent-post-on-your-wordpress-themes/#comments</comments>
		<pubDate>Tue, 27 Oct 2009 13:30:22 +0000</pubDate>
		<dc:creator>Narga</dc:creator>
				<category><![CDATA[PHP]]></category>
		<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[wordpress recipes]]></category>
		<category><![CDATA[wordpress tips and tricks]]></category>

		<guid isPermaLink="false">http://www.narga.net/?p=1319</guid>
		<description><![CDATA[Installing too many plugins will make the wordpress blog work slowly and unstable, use code built in your theme will reduce the system resources. I've known a ton of plugins and widgets that allows me to list recent comments and recent post on my WordPress blog but I'm not using it because I've integrated some useful code below then I get results similar to those extensions which I've known.]]></description>
			<content:encoded><![CDATA[<p>Installing too many plugins will make the WordPress blog work slowly and unstable, use code built-in your theme will reduce the system resources.<br />
<div id="attachment_1322" class="wp-caption aligncenter" style="width: 490px"><img src="http://www.narga.net/wp-content/uploads/2009/10/86.jpg" alt="Most recent post and comments" width="480" height="360" class="size-full wp-image-1322" /><p class="wp-caption-text">Most recent post and comments</p></div>I've known a ton of plugins and widgets that allows me to list recent comments and recent post on my WordPress blog but I'm not using it. Because I've integrated some useful code below then I get results similar to those extensions which I've known.</p>
<h3>List most recent comments</h3>
<pre class="brush: php; html-script: true; title: ; notranslate">&lt;?php
  global $wpdb;
  $sql = &quot;SELECT DISTINCT ID, post_title, post_password, comment_ID, comment_post_ID, comment_author, comment_date_gmt, comment_approved, comment_type,comment_author_url, SUBSTRING(comment_content,1,30) AS com_excerpt FROM $wpdb-&gt;comments LEFT OUTER JOIN $wpdb-&gt;posts ON ($wpdb-&gt;comments.comment_post_ID = $wpdb-&gt;posts.ID) WHERE comment_approved = '1' AND comment_type = '' AND post_password = '' ORDER BY comment_date_gmt DESC LIMIT 10&quot;;

  $comments = $wpdb-&gt;get_results($sql);
  $output = $pre_HTML;
  $output .= &quot;n&lt;ul&gt;&quot;;
  foreach ($comments as $comment) {
    $output .= &quot;n&lt;li&gt;&quot;.strip_tags($comment-&gt;comment_author) .&quot;:&quot; . &quot;&lt;a href=&quot;&quot; . get_permalink($comment-&gt;ID).&quot;#comment-&quot; . $comment-&gt;comment_ID . &quot;&quot; title=&quot;on &quot;.$comment-&gt;post_title . &quot;&quot;&gt;&quot; . strip_tags($comment-&gt;com_excerpt).&quot;&lt;/a&gt;&lt;/li&gt;&quot;;
  }
  $output .= &quot;n&lt;/ul&gt;&quot;;
  $output .= $post_HTML;
  echo $output;
?&gt;</pre>
<p><span id="more-1319"></span>If you want to list more or less comments, simply change the "10" in the <strong>$sql</strong> variable.</p>
<h3>List most recent posts</h3>
<pre class="brush: php; html-script: true; title: ; notranslate">&lt;?php query_posts('showposts=5'); ?&gt;
&lt;ul&gt;
&lt;?php while (have_posts()) : the_post(); ?&gt;
&lt;li&gt;&lt;a href=&quot;&lt;?php the_permalink() ?&gt;&quot;&gt;&lt;?php the_title(); ?&gt;&lt;/a&gt;&lt;/li&gt;
&lt;?php endwhile;?&gt;
&lt;/ul&gt;</pre>
<p>Do you want to deactive your <em>List most recent comments and recent post</em> plugins then use code snippets above?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.narga.net/how-to-list-most-recent-comments-and-recent-post-on-your-wordpress-themes/feed/</wfw:commentRss>
		<slash:comments>39</slash:comments>
		</item>
		<item>
		<title>Mastering Worpress [gallery] shortcode</title>
		<link>http://www.narga.net/mastering-worpress-gallery-shortcode/?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=mastering-worpress-gallery-shortcode</link>
		<comments>http://www.narga.net/mastering-worpress-gallery-shortcode/#comments</comments>
		<pubDate>Tue, 20 Oct 2009 13:30:34 +0000</pubDate>
		<dc:creator>Narga</dc:creator>
				<category><![CDATA[Wordpress]]></category>
		<category><![CDATA[wordpress tips and tricks]]></category>

		<guid isPermaLink="false">http://www.narga.net/?p=1243</guid>
		<description><![CDATA[From WordPress 2.5, the Gallery feature allows the option to add an image gallery to a Post or Page on your WordPress blog.
Upload all your photos and simply type the  shortcode <code>[gallery</code> in a post or page to display a thumbnail gallery of images attached to that post or page. Clicking on a thumbnail image will open either the original image or a larger image in a separate Attachment page.]]></description>
			<content:encoded><![CDATA[<p>From WordPress 2.5, the Gallery feature allows the option to add an image gallery to a Post or Page on your WordPress blog.<br />
Upload all your photos and simply type the  shortcode <code>&#091;gallery</code> in a post or page to display a thumbnail gallery of images attached to that post or page. Clicking on a thumbnail image will open either the original image or a larger image in a separate Attachment page.<br />
<span id="more-1243"></span><br />
<h3>Shortcode Options</h3>
<p>There are several basic options of &#091;gallery&#093; shortcode that may be specified using the following syntax<br />
&#091;gallery option1="value1" option2="value2"&#093;<br />
The following basic options are supported:</p>
<ul>
<li><strong>columns</strong>: specify the number of columns. The gallery will include a break tag at the end of each row, and calculate the column width as appropriate. The default value is 3. If columns is set to 0, no row breaks will be included. For example, to display a 4 column gallery: &#091;gallery columns="4"&#093;</li>
<li><strong>id</strong>: specify the post ID. The gallery will display images which are attached to that post. The default behaviour if no ID is specified is to display images attached to the current post. For example, to display images attached to post 123: &#091;gallery id="123"&#093;</li>
<li><strong>size: </strong>specify the image size to use for the thumbnail display. Valid values include "thumbnail", "medium", "large" and "full". The default is "thumbnail". The size of the images for "thumbnail", "medium" and "large" can be configured in WordPress admin panel under Settings &gt; Media. For example, to display a gallery of medium sized images:&#091;gallery size="medium"&#093;</li>
</ul>
<h3>Advanced options</h3>
<ul>
<li><strong>orderby: </strong>specify the sort order used to display thumbnails. The default is "<em>menu_order ASC, ID ASC</em>". </li>
<li><strong>itemtag</strong>: the name of the XHTML tag used to enclose each item in the gallery. The default is "<em>dl</em>". </li>
<li><strong>icontag</strong>: the name of the XHTML tag used to enclose each thumbnail icon in the gallery. The default is "<em>dt</em>". </li>
<li><strong>captiontag</strong>: the name of the XHTML tag used to enclose each caption. The default is "<em>dd</em>". For example, to change the gallery markup to use div, span and p tags.</li>
<li><strong>link</strong>: you can set it to "file" so each image will link to the image file. The default value links to the attachment's permalink.</li>
</ul>
<p>You should now see a Gallery shortcode appear in your post similar to the following:<br />
&#091;gallery link="file" orderby="post_name"&#093;<br />
You can also assign your own tags for enclosing the various elements of the image gallery. I have select tags to enclose my items, thumbnails and captions.<br />
&#091;gallery link="file" orderby="post_name" itemtag="div" icontag="span" captiontag="p"&#093;</p>
<h3>&#091;gallery&#093; shortcode FAQs</h3>
<ol>
<li><strong>How many images can I have in my Gallery?</strong><br />
I’m assuming the only limitation is the amount of storage space you have available, so optimizing your images before uploading is important not only because of space and viewer considerations.</li>
<li><strong>The Gallery doesn’t display the thumbnails in the order I want. How do I rearrange them?</strong><br />
In the Post or Page Visual Editor, click on the Gallery placeholder. You will see two small buttons appear in the upper left corner of the placeholder, clicking on the left button will bring you to the Gallery tab in the Image Uploader where you can change thumbnail order under the Gallery Settings.<br />
You can set the order number for your images as you want.</li>
<li><strong>My gallery pages not valid XHTML</strong><br />
By default when using the gallery shortcode the styles are placed into the post content which breaks XHTML validation. You can use Gallery Shortcode Style to Head plugin to fix this places the style into the head of the page using a look ahead to determine if the ‘gallery’ shortcode is used in any posts.</li>
<li><strong>The Gallery thumbnails on my blog are not arranged in columns and rows.</strong><br />
By default, the Gallery shows 3 thumbnails per row. If the Theme you are using is particularly narrow, this knocks the thumbnails out of alignment and you see the behavior described above. In order to change the number of thumbnails displayed per row, you will need to open the Image Uploader in the Post or Page Editor, switch to the Gallery tab and modify the Gallery settings.  Another way is to switch to the HTML Editor window and directly modify the shortcode to &#091;gallery columns="2"&#093; or if your theme is very wide and you want to display more thumbnails per row &#091;gallery columns="4"&#093;.</li>
<li><strong>Can I add or delete images, thumbnail images in my existing Gallery?</strong>
<ul>
<li><strong>To change thumbnail images size:</strong> You can change the default size of thumbnails on your blog via your Dashboard’s &gt;&gt;Settings &gt;&gt;Media&gt;&gt;Thumbnail Size. Changing this setting changes the thumbnail size globally on your entire blog, not just in a single Gallery.</li>
<li><strong>To add or delete images,</strong> have the Post or Page where the Gallery appears open in the Editor. You can add or delete images in the Gallery tab. If necessary, reorder your thumbnails as described above.<br />
In all cases, remember to click “Save All Changes” and “Update Gallery Settings”.</li>
</ul>
</li>
<li><strong>Is it possible to edit the images in my Gallery or Attachment pages?</strong><br />
Because your Gallery images are being displayed via the Gallery shortcode, you do not have the option of editing images that appear in a Gallery.<br />
Attachment pages themselves cannot be edited as a regular Page. If you click on the “Edit Post” button or “Edit This” link that appears on the Attachment page, you will be taken to your Media Library where you can change the image’s Title, Caption and Description.</li>
<li><strong>How can I display an image in the same Post or Page without it being a part of the Gallery?</strong><br />
Any image you upload in the same Post or Page where your Gallery appears will automatically be included in that Gallery. Inserting an image which was uploaded via “Media&gt;Add New” in the Dashboard is not attached to a specific Post or Page and will become attached to the Post or Page where your Gallery appears.</li>
<li><strong>Can I have more than one Gallery in my Post?</strong><br />
Galleries are tied to individual Posts or Pages. In order to have more than one Gallery per Post or Page, you need to create a new Post and upload the images you want there. Save the Post, go to your Dashboard’s Manage&gt;&gt;Posts and then hold your mouse over the title of the Post where you inserted the additional Gallery. (Update: you can also find this information via your Media Library.) In your browser’s status bar, you will see the link to edit your Post, which ends in a number. That is the ID number for the Post where the additional Gallery appears and what needs to be inserted in the Gallery shortcode via the HTML Editor. For example, the Gallery just below is coming from a past Post and also demonstrates displaying medium thumbnail size. The shortcode looks like &#091;gallery id="119" size="medium"&#093;.<br />
Unfortunately, the additional Gallery only shown in post if it appears in a post was published, otherwise when viewers click on a thumbnail, they get a “Page not found” error. </li>
<li><strong>Can I have a Page that displays all my existing Galleries?</strong><br />
Answers like the ones above, the difference is posts and pages.<br />
<strong>Can I Remove WordPress &#091;gallery&#093; shortcode embedded stylesheet then using my own?</strong><br />
Yes, you can. Dump this code anywhere in Theme’s template functions.php file: </p>
<pre class="brush: php; title: ; notranslate">function remove_gallery_style() {
  return &quot;&lt;div class='gallery'&gt;&quot;;
}
add_filter('gallery_style', 'remove_gallery_style');</pre>
<p>And these are the classes for your stylesheet:</p>
<pre class="brush: css; title: ; notranslate">.gallery {}
.gallery-item {}
.gallery-icon {}
.gallery-caption {}</pre>
<p>Now, you can use your own stylesheet code.</li>
</ol>
<h3>Reference Resources</h3>
<ul>
<li><a rel="nofollow" href="http://gammagirl.wordpress.com/2008/07/27/not-the-official-wordpresscom-gallery-faq/"  title="Not the Official WordPress.com Gallery FAQ">Not the Official WordPress.com Gallery FAQ</a></li>
<li><a rel="nofollow" href="http://codex.wordpress.org/Gallery_Shortcode"  title="Wordpress.org Docs - Gallery Shortcode">WordPress.org Docs - Gallery Shortcode</a></li>
</ul>
<p>Are you can total control wordpress &#091;gallery&#093; shortcode?</p>
]]></content:encoded>
			<wfw:commentRss>http://www.narga.net/mastering-worpress-gallery-shortcode/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
	</channel>
</rss>

