<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: WordPress: get page id and content with example &amp; code</title>
	<atom:link href="http://www.tanzilo.com/2008/12/19/wordpress-get-page-id-and-content-with-example-code/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.tanzilo.com/2008/12/19/wordpress-get-page-id-and-content-with-example-code/</link>
	<description>Talks on Web Technology and Better Product Development</description>
	<lastBuildDate>Fri, 23 Jul 2010 21:02:58 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=abc</generator>
	<item>
		<title>By: Ateljedigital</title>
		<link>http://www.tanzilo.com/2008/12/19/wordpress-get-page-id-and-content-with-example-code/comment-page-1/#comment-703</link>
		<dc:creator>Ateljedigital</dc:creator>
		<pubDate>Thu, 18 Mar 2010 20:07:01 +0000</pubDate>
		<guid isPermaLink="false">http://www.tanzilo.com/?p=58#comment-703</guid>
		<description>Great post!
I had this problem, where I wanted to show something on all pages but the first page. Very easy after I read your post and know how to get the ID of the first page.

Thank you SO much!</description>
		<content:encoded><![CDATA[<p>Great post!<br />
I had this problem, where I wanted to show something on all pages but the first page. Very easy after I read your post and know how to get the ID of the first page.</p>
<p>Thank you SO much!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: admin</title>
		<link>http://www.tanzilo.com/2008/12/19/wordpress-get-page-id-and-content-with-example-code/comment-page-1/#comment-685</link>
		<dc:creator>admin</dc:creator>
		<pubDate>Sat, 06 Feb 2010 19:04:28 +0000</pubDate>
		<guid isPermaLink="false">http://www.tanzilo.com/?p=58#comment-685</guid>
		<description>@ Mandy

You can write a custom function in the functions.php file where you can show the pages and ids something like:

&lt;?php


	function getSitemap()
	{
		global $wpdb;
		$output = &#039;&#039;;
		$sqlQuery = &quot;SELECT * FROM {$wpdb-&gt;prefix}posts 
		WHERE post_status = &#039;publish&#039; 
		AND post_type=&#039;page&#039; 
		ORDER BY post_date DESC; &quot;;
		$dbResult = mysql_query($sqlQuery);
		while($dbRow = mysql_fetch_object($dbResult))
		{
			$output .= $dbRow-&gt;post_title . &#039; - &#039; . $dbRow-&gt;ID . &#039;&lt;br /&gt;&#039;;
		}
		return $output;
	}

?&gt;

Then you call it in your sitemap Template file:
&lt;?php getSitemap(); ?&gt;

Give a try!</description>
		<content:encoded><![CDATA[<p>@ Mandy</p>
<p>You can write a custom function in the functions.php file where you can show the pages and ids something like:</p>
<p>< ?php</p>
<p>	function getSitemap()<br />
	{<br />
		global $wpdb;<br />
		$output = '';<br />
		$sqlQuery = "SELECT * FROM {$wpdb->prefix}posts<br />
		WHERE post_status = &#8216;publish&#8217;<br />
		AND post_type=&#8217;page&#8217;<br />
		ORDER BY post_date DESC; &#8220;;<br />
		$dbResult = mysql_query($sqlQuery);<br />
		while($dbRow = mysql_fetch_object($dbResult))<br />
		{<br />
			$output .= $dbRow->post_title . &#8216; &#8211; &#8216; . $dbRow->ID . &#8216;<br />&#8216;;<br />
		}<br />
		return $output;<br />
	}</p>
<p>?></p>
<p>Then you call it in your sitemap Template file:<br />
< ?php getSitemap(); ?></p>
<p>Give a try!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Mandy</title>
		<link>http://www.tanzilo.com/2008/12/19/wordpress-get-page-id-and-content-with-example-code/comment-page-1/#comment-684</link>
		<dc:creator>Mandy</dc:creator>
		<pubDate>Sat, 06 Feb 2010 15:37:34 +0000</pubDate>
		<guid isPermaLink="false">http://www.tanzilo.com/?p=58#comment-684</guid>
		<description>Hi, thanks for this interesting post! 
I have one more question: Is ther a way to display in a sitemap the page title + page ID? 

I&#039;m using this line to display all pages + subpages:

And I&#039;d like to have the output like 
 &quot;Home - 1&quot;
    &quot;Page XYZ - 2&quot; 
ect. 

Is there a way to do this?
Thanks!</description>
		<content:encoded><![CDATA[<p>Hi, thanks for this interesting post!<br />
I have one more question: Is ther a way to display in a sitemap the page title + page ID? </p>
<p>I&#8217;m using this line to display all pages + subpages:</p>
<p>And I&#8217;d like to have the output like<br />
 &#8220;Home &#8211; 1&#8243;<br />
    &#8220;Page XYZ &#8211; 2&#8243;<br />
ect. </p>
<p>Is there a way to do this?<br />
Thanks!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jason kadlec</title>
		<link>http://www.tanzilo.com/2008/12/19/wordpress-get-page-id-and-content-with-example-code/comment-page-1/#comment-676</link>
		<dc:creator>Jason kadlec</dc:creator>
		<pubDate>Fri, 22 Jan 2010 00:21:13 +0000</pubDate>
		<guid isPermaLink="false">http://www.tanzilo.com/?p=58#comment-676</guid>
		<description>Thanks that rules! I knew I&#039;d learned this before....stumbled around google then came (back) to your site. I knew this is where i&#039;d learned it b&#039;c you have a beautiful site.

Thanks!</description>
		<content:encoded><![CDATA[<p>Thanks that rules! I knew I&#8217;d learned this before&#8230;.stumbled around google then came (back) to your site. I knew this is where i&#8217;d learned it b&#8217;c you have a beautiful site.</p>
<p>Thanks!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bisnis UKM</title>
		<link>http://www.tanzilo.com/2008/12/19/wordpress-get-page-id-and-content-with-example-code/comment-page-1/#comment-675</link>
		<dc:creator>Bisnis UKM</dc:creator>
		<pubDate>Thu, 21 Jan 2010 08:50:48 +0000</pubDate>
		<guid isPermaLink="false">http://www.tanzilo.com/?p=58#comment-675</guid>
		<description>How to get page ID outside the loop ?
I&#039;ve try using global for $post, but didn&#039;t work.</description>
		<content:encoded><![CDATA[<p>How to get page ID outside the loop ?<br />
I&#8217;ve try using global for $post, but didn&#8217;t work.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: ebta</title>
		<link>http://www.tanzilo.com/2008/12/19/wordpress-get-page-id-and-content-with-example-code/comment-page-1/#comment-674</link>
		<dc:creator>ebta</dc:creator>
		<pubDate>Thu, 21 Jan 2010 08:49:10 +0000</pubDate>
		<guid isPermaLink="false">http://www.tanzilo.com/?p=58#comment-674</guid>
		<description>Thank you... I understand now..</description>
		<content:encoded><![CDATA[<p>Thank you&#8230; I understand now..</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Yudi</title>
		<link>http://www.tanzilo.com/2008/12/19/wordpress-get-page-id-and-content-with-example-code/comment-page-1/#comment-670</link>
		<dc:creator>Yudi</dc:creator>
		<pubDate>Tue, 12 Jan 2010 13:15:29 +0000</pubDate>
		<guid isPermaLink="false">http://www.tanzilo.com/?p=58#comment-670</guid>
		<description>sorry, I am not familiar with php code.
I has seen your link reference, but I still confuse.
can you please give me the code for make appear the page above like I told ? So, I can put the code in my table.
Thank you.</description>
		<content:encoded><![CDATA[<p>sorry, I am not familiar with php code.<br />
I has seen your link reference, but I still confuse.<br />
can you please give me the code for make appear the page above like I told ? So, I can put the code in my table.<br />
Thank you.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: admin</title>
		<link>http://www.tanzilo.com/2008/12/19/wordpress-get-page-id-and-content-with-example-code/comment-page-1/#comment-669</link>
		<dc:creator>admin</dc:creator>
		<pubDate>Tue, 12 Jan 2010 12:05:26 +0000</pubDate>
		<guid isPermaLink="false">http://www.tanzilo.com/?p=58#comment-669</guid>
		<description>@ Yudi

Check this:
http://codex.wordpress.org/Template_Tags/query_posts</description>
		<content:encoded><![CDATA[<p>@ Yudi</p>
<p>Check this:<br />
<a href="http://codex.wordpress.org/Template_Tags/query_posts" rel="nofollow">http://codex.wordpress.org/Template_Tags/query_posts</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Yudi</title>
		<link>http://www.tanzilo.com/2008/12/19/wordpress-get-page-id-and-content-with-example-code/comment-page-1/#comment-668</link>
		<dc:creator>Yudi</dc:creator>
		<pubDate>Tue, 12 Jan 2010 11:01:42 +0000</pubDate>
		<guid isPermaLink="false">http://www.tanzilo.com/?p=58#comment-668</guid>
		<description>Hi, can you help me please ?
example :
I have wordpress page with name :
http://127.0.0.01/mywordpress/?page_id=67

I want the content of that page can appear in my home page. 
Only content from that page (Not Tittle or etc).

so, what the php code must put in my div table ?
I try using your code above, but all contents of the posts appear in my div table at home page.</description>
		<content:encoded><![CDATA[<p>Hi, can you help me please ?<br />
example :<br />
I have wordpress page with name :<br />
<a href="http://127.0.0.01/mywordpress/?page_id=67" rel="nofollow">http://127.0.0.01/mywordpress/?page_id=67</a></p>
<p>I want the content of that page can appear in my home page.<br />
Only content from that page (Not Tittle or etc).</p>
<p>so, what the php code must put in my div table ?<br />
I try using your code above, but all contents of the posts appear in my div table at home page.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: admin</title>
		<link>http://www.tanzilo.com/2008/12/19/wordpress-get-page-id-and-content-with-example-code/comment-page-1/#comment-664</link>
		<dc:creator>admin</dc:creator>
		<pubDate>Mon, 11 Jan 2010 11:14:56 +0000</pubDate>
		<guid isPermaLink="false">http://www.tanzilo.com/?p=58#comment-664</guid>
		<description>@ potobenka

there is a function wp_list_pages

also there are many other ways such as custom coding to get the posts!</description>
		<content:encoded><![CDATA[<p>@ potobenka</p>
<p>there is a function wp_list_pages</p>
<p>also there are many other ways such as custom coding to get the posts!</p>
]]></content:encoded>
	</item>
</channel>
</rss>
