<?xml version="1.0" encoding="UTF-8"?><!-- generator="bbPress" -->

<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
>

<channel>
<title>WordPress &#8250; Support Tag: custom field</title>
<link>http://wordpress.org/support/</link>
<description>WordPress &#8250; Support Tag: custom field</description>
<language>en</language>
<pubDate>Thu, 26 Nov 2009 05:04:59 +0000</pubDate>

<item>
<title>beradmin on "Put &#60;DIV CLASS… inside php code &#38; show style only when I add that custom field"</title>
<link>http://wordpress.org/support/topic/335372#post-1293927</link>
<pubDate>Wed, 25 Nov 2009 22:07:12 +0000</pubDate>
<dc:creator>beradmin</dc:creator>
<guid isPermaLink="false">1293927@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Cool!! I found the answer:&#60;/p&#62;
&#60;p&#62;&#38;lt;?php  if((get_post_meta($post-&#38;gt;ID, &#34;artistMenu&#34;, true))) { ?&#38;gt;&#60;br /&#62;
	&#38;lt;div id=&#34;artistMenu&#34;&#38;gt;&#60;br /&#62;
		&#38;lt;?php echo get_post_meta($post-&#38;gt;ID, &#34;artistMenu&#34;, true); ?&#38;gt;&#60;br /&#62;
	&#38;lt;/div&#38;gt;&#60;br /&#62;
&#38;lt;?php } ?&#38;gt;&#60;/p&#62;
&#60;p&#62;&#60;strong&#62;Have a look @ &#60;/strong&#62;&#60;a href=&#34;http://www.designisphilosophy.com/tutorials/using-conditional-custom-fields-for-advanced-layouts-20081219/&#34;&#62;http://www.designisphilosophy.com/tutorials/using-conditional-custom-fields-for-advanced-layouts-20081219/&#60;/a&#62;
&#60;/p&#62;</description>
</item>
<item>
<title>beradmin on "Put &#60;DIV CLASS… inside php code &#38; show style only when I add that custom field"</title>
<link>http://wordpress.org/support/topic/335372#post-1292945</link>
<pubDate>Wed, 25 Nov 2009 03:28:28 +0000</pubDate>
<dc:creator>beradmin</dc:creator>
<guid isPermaLink="false">1292945@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Hi guys. I added a custom field key code in my pages template with a style (.imgcred) that includes a grey background colour. The style is showing (as a grey little box) even when I don’t add that custom field when I create the page. The custom field is “imgcenterlabel”.&#60;/p&#62;
&#60;p&#62;1) This is the code I added initially: &#60;/p&#62;
&#60;p&#62;&#38;lt;div align=&#34;center&#34;&#38;gt;&#60;br /&#62;
&#38;lt;div class=&#34;imgcred&#34;&#38;gt;&#60;br /&#62;
&#38;lt;?php $key=&#34;imgcenterlabel&#34;; echo get_post_meta($post-&#38;gt;ID, $key, true); ?&#38;gt;&#60;br /&#62;
&#38;lt;/div&#38;gt;&#60;br /&#62;
&#38;lt;/div&#38;gt;		&#60;/p&#62;
&#60;p&#62;2) Then I inserted the DIV inside the php code but the grey box were still there:&#60;/p&#62;
&#60;p&#62;&#38;lt;div align=&#34;center&#34;&#38;gt;&#60;br /&#62;
&#38;lt;?php&#60;br /&#62;
    $key = &#34;imgcenterlabel&#34;;&#60;br /&#62;
    $value = get_post_meta($post-&#38;gt;ID, $key, true);&#60;br /&#62;
    if ($value != &#34;&#34;)&#60;br /&#62;
	echo '&#38;lt;div class=&#34;imgcred&#34;&#38;gt;';&#60;br /&#62;
	echo $value . &#34;&#34;;&#60;br /&#62;
	echo '&#38;lt;/div&#38;gt;&#38;lt;!-- /.imgcred --&#38;gt;';&#60;br /&#62;
?&#38;gt;&#60;br /&#62;
&#38;lt;/div&#38;gt;&#60;/p&#62;
&#60;p&#62;3) This is the class I am using:&#60;br /&#62;
.imgcred {&#60;br /&#62;
	font-size: .9em;&#60;br /&#62;
	margin: 0px 10px 10px 0px;&#60;br /&#62;
	font-weight: regular;&#60;br /&#62;
	font-family: &#34;Lucida Sans Unicode&#34;, &#34;Lucida Grande&#34;, sans-serif;&#60;br /&#62;
	width: 418px;&#60;br /&#62;
	background-color:#F3F2F0;&#60;br /&#62;
	text-align:center;&#60;br /&#62;
	}&#60;/p&#62;
&#60;p&#62;4) My page.php:&#60;/p&#62;
&#60;p&#62;I added a custom field key code in my pages template with a style (.imgcred) that includes a grey background colour. The style is showing (as a grey little box) even when I don’t add that custom field to the page. &#60;/p&#62;
&#60;p&#62;The custom field is “imgcenterlabel”.&#60;/p&#62;
&#60;p&#62;1) This is the code I added initially: &#60;/p&#62;
&#60;p&#62;&#38;lt;div align=&#34;center&#34;&#38;gt;&#60;br /&#62;
&#38;lt;div class=&#34;imgcred&#34;&#38;gt;&#60;br /&#62;
&#38;lt;?php $key=&#34;imgcenterlabel&#34;; echo get_post_meta($post-&#38;gt;ID, $key, true); ?&#38;gt;&#60;br /&#62;
&#38;lt;/div&#38;gt;&#60;br /&#62;
&#38;lt;/div&#38;gt;		&#60;/p&#62;
&#60;p&#62;2) Then I inserted the DIV inside the php code but the grey box were still there:&#60;/p&#62;
&#60;p&#62;&#38;lt;div align=&#34;center&#34;&#38;gt;&#60;br /&#62;
&#38;lt;?php&#60;br /&#62;
    $key = &#34;imgcenterlabel&#34;;&#60;br /&#62;
    $value = get_post_meta($post-&#38;gt;ID, $key, true);&#60;br /&#62;
    if ($value != &#34;&#34;)&#60;br /&#62;
	echo '&#38;lt;div class=&#34;imgcred&#34;&#38;gt;';&#60;br /&#62;
	echo $value . &#34;&#34;;&#60;br /&#62;
	echo '&#38;lt;/div&#38;gt;&#38;lt;!-- /.imgcred --&#38;gt;';&#60;br /&#62;
?&#38;gt;&#60;br /&#62;
&#38;lt;/div&#38;gt;&#60;/p&#62;
&#60;p&#62;3) This is the class I am using:&#60;br /&#62;
.imgcred {&#60;br /&#62;
	font-size: .9em;&#60;br /&#62;
	margin: 0px 10px 10px 0px;&#60;br /&#62;
	font-weight: regular;&#60;br /&#62;
	font-family: &#34;Lucida Sans Unicode&#34;, &#34;Lucida Grande&#34;, sans-serif;&#60;br /&#62;
	width: 418px;&#60;br /&#62;
	background-color:#F3F2F0;&#60;br /&#62;
	text-align:center;&#60;br /&#62;
	}&#60;/p&#62;
&#60;p&#62;4) My page.php:&#60;/p&#62;
&#60;p&#62;I added a custom field key code in my pages template with a style (.imgcred) that includes a grey background colour. The style is showing (as a grey little box) even when I don’t add that custom field to the page. &#60;/p&#62;
&#60;p&#62;The custom field is “imgcenterlabel”.&#60;/p&#62;
&#60;p&#62;1) This is the code I added initially: &#60;/p&#62;
&#60;p&#62;&#38;lt;div align=&#34;center&#34;&#38;gt;&#60;br /&#62;
&#38;lt;div class=&#34;imgcred&#34;&#38;gt;&#60;br /&#62;
&#38;lt;?php $key=&#34;imgcenterlabel&#34;; echo get_post_meta($post-&#38;gt;ID, $key, true); ?&#38;gt;&#60;br /&#62;
&#38;lt;/div&#38;gt;&#60;br /&#62;
&#38;lt;/div&#38;gt;		&#60;/p&#62;
&#60;p&#62;2) Then I inserted the DIV inside the php code but the grey box were still there:&#60;/p&#62;
&#60;p&#62;&#38;lt;div align=&#34;center&#34;&#38;gt;&#60;br /&#62;
&#38;lt;?php&#60;br /&#62;
    $key = &#34;imgcenterlabel&#34;;&#60;br /&#62;
    $value = get_post_meta($post-&#38;gt;ID, $key, true);&#60;br /&#62;
    if ($value != &#34;&#34;)&#60;br /&#62;
	echo '&#38;lt;div class=&#34;imgcred&#34;&#38;gt;';&#60;br /&#62;
	echo $value . &#34;&#34;;&#60;br /&#62;
	echo '&#38;lt;/div&#38;gt;&#38;lt;!-- /.imgcred --&#38;gt;';&#60;br /&#62;
?&#38;gt;&#60;br /&#62;
&#38;lt;/div&#38;gt;&#60;/p&#62;
&#60;p&#62;3) This is the class I am using:&#60;br /&#62;
.imgcred {&#60;br /&#62;
	font-size: .9em;&#60;br /&#62;
	margin: 0px 10px 10px 0px;&#60;br /&#62;
	font-weight: regular;&#60;br /&#62;
	font-family: &#34;Lucida Sans Unicode&#34;, &#34;Lucida Grande&#34;, sans-serif;&#60;br /&#62;
	width: 418px;&#60;br /&#62;
	background-color:#F3F2F0;&#60;br /&#62;
	text-align:center;&#60;br /&#62;
	}&#60;/p&#62;
&#60;p&#62;4) My page.php:&#60;/p&#62;
&#60;p&#62;&#38;lt;?php get_header(); ?&#38;gt;&#60;/p&#62;
&#60;p&#62;	&#38;lt;div id=&#34;content&#34;&#38;gt;&#60;/p&#62;
&#60;p&#62;    &#38;lt;?&#60;br /&#62;
$toplevelid = $post-&#38;gt;ID;&#60;/p&#62;
&#60;p&#62;			  if ($post-&#38;gt;post_parent) {&#60;/p&#62;
&#60;p&#62;				  	$toplevelid = $post-&#38;gt;post_parent;&#60;/p&#62;
&#60;p&#62;					$toplevel = get_page($toplevelid);&#60;/p&#62;
&#60;p&#62;					if($toplevel-&#38;gt;post_parent) {&#60;br /&#62;
						$toplevelid = $toplevel-&#38;gt;post_parent;&#60;br /&#62;
					}&#60;br /&#62;
			  }  &#60;/p&#62;
&#60;p&#62;?&#38;gt;&#60;/p&#62;
&#60;p&#62;		&#38;lt;?php if (have_posts()) : while (have_posts()) : the_post(); ?&#38;gt;&#60;br /&#62;
		&#38;lt;div class=&#34;post&#34; id=&#34;post-&#38;lt;?php the_ID(); ?&#38;gt;&#34;&#38;gt;&#60;br /&#62;
       &#38;lt;h1 class=&#34;page-title&#34;&#38;gt;&#38;lt;span class=&#34;page-title-span&#34;&#38;gt;&#38;lt;?php the_title(); ?&#38;gt;&#38;lt;/span&#38;gt;&#38;lt;span class=&#34;title&#34;&#38;gt;&#38;lt;?php echo get_the_title($toplevelid); ?&#38;gt;&#38;lt;/span&#38;gt;&#38;lt;/h1&#38;gt;&#60;/p&#62;
&#60;p&#62;&#38;lt;div id=&#34;cf_container&#34;&#38;gt;&#60;/p&#62;
&#60;p&#62;	&#38;lt;div id=&#34;cf_rssleft&#34;&#38;gt;&#60;br /&#62;
&#38;lt;?php&#60;/p&#62;
&#60;p&#62;			$key=&#34;extra&#34;;&#60;br /&#62;
			$feedURL = get_post_meta($post-&#38;gt;ID, $key, true);&#60;/p&#62;
&#60;p&#62;			if ($feedURL) {&#60;br /&#62;
				$feed = new SimplePie($feedURL);&#60;/p&#62;
&#60;p&#62;				$item = $feed-&#38;gt;get_item();&#60;br /&#62;
				print $item-&#38;gt;get_content();&#60;br /&#62;
			} ?&#38;gt;&#60;br /&#62;
	&#38;lt;/div&#38;gt;&#38;lt;!-- close #cf_rssleft --&#38;gt;&#60;/p&#62;
&#60;p&#62;	&#38;lt;div id=&#34;cf_imageright&#34;&#38;gt;&#60;br /&#62;
    &#38;lt;?php $key=&#34;image&#34;;&#60;br /&#62;
if ( get_post_meta($post-&#38;gt;ID, $key, true) ) { ?&#38;gt;&#60;br /&#62;
&#38;lt;img class=&#34;custom_image&#34; src=&#34;&#38;lt;?php echo get_post_meta($post-&#38;gt;ID, $key, true); ?&#38;gt;&#34; alt=&#34;&#34; /&#38;gt;&#38;lt;?php }; ?&#38;gt;&#60;br /&#62;
	&#38;lt;/div&#38;gt;&#38;lt;!-- close #cf_imageright --&#38;gt;&#60;/p&#62;
&#60;p&#62;&#38;lt;/div&#38;gt;&#38;lt;!-- close #cf_container --&#38;gt;&#60;/p&#62;
&#60;p&#62;   &#38;lt;div class=&#34;entry&#34;&#38;gt;&#60;br /&#62;
&#38;lt;?php $key=&#34;imagecenter&#34;;&#60;br /&#62;
if ( get_post_meta($post-&#38;gt;ID, $key, true) ) { ?&#38;gt;&#60;br /&#62;
&#38;lt;center&#38;gt;&#38;lt;img class=&#34;custom_image&#34; src=&#34;&#38;lt;?php echo get_post_meta($post-&#38;gt;ID, $key, true); ?&#38;gt;&#34; alt=&#34;&#34; /&#38;gt;&#38;lt;?php }; ?&#38;gt;&#38;lt;/center&#38;gt;&#60;br /&#62;
&#38;lt;/div&#38;gt;&#38;lt;!-- close .entry --&#38;gt;&#60;/p&#62;
&#60;p&#62;&#38;lt;div align=&#34;center&#34;&#38;gt;&#38;lt;?php $key=&#34;imgcenterlabel&#34;; echo get_post_meta($post-&#38;gt;ID, $key, true); ?&#38;gt;&#38;lt;/div&#38;gt;&#60;/p&#62;
&#60;p&#62;	  &#38;lt;div class=&#34;entry&#34;&#38;gt;&#60;/p&#62;
&#60;p&#62;			&#38;lt;?php&#60;/p&#62;
&#60;p&#62;			$key=&#34;rss&#34;;&#60;br /&#62;
			$feedURL = get_post_meta($post-&#38;gt;ID, $key, true);&#60;/p&#62;
&#60;p&#62;			if ($feedURL) {&#60;br /&#62;
				$feed = new SimplePie($feedURL);&#60;/p&#62;
&#60;p&#62;				$item = $feed-&#38;gt;get_item();&#60;br /&#62;
				print $item-&#38;gt;get_content();&#60;br /&#62;
			} ?&#38;gt;&#60;/p&#62;
&#60;p&#62;				&#38;lt;?php the_content('&#38;lt;p class=&#34;serif&#34;&#38;gt;Read the rest of this page &#38;raquo;&#38;lt;/p&#38;gt;'); ?&#38;gt;	&#60;/p&#62;
&#60;p&#62;				&#38;lt;?php wp_link_pages(array('before' =&#38;gt; '&#38;lt;p&#38;gt;&#60;strong&#62;Pages:&#60;/strong&#62; ', 'after' =&#38;gt; '&#38;lt;/p&#38;gt;', 'next_or_number' =&#38;gt; 'number')); ?&#38;gt;&#60;/p&#62;
&#60;p&#62;			&#38;lt;/div&#38;gt;&#38;lt;!-- close .entry --&#38;gt;&#60;br /&#62;
		&#38;lt;?php endwhile; endif; ?&#38;gt;&#60;br /&#62;
		&#38;lt;?php edit_post_link('Edit this entry.', '&#38;lt;p&#38;gt;', '&#38;lt;/p&#38;gt;'); ?&#38;gt;&#60;br /&#62;
		&#38;lt;/div&#38;gt;&#38;lt;!-- close .post --&#38;gt;&#60;br /&#62;
    &#38;lt;/div&#38;gt;&#60;br /&#62;
     &#38;lt;/div&#38;gt;&#38;lt;!-- close #content --&#38;gt;&#60;/p&#62;
&#60;p&#62;&#38;lt;?php get_footer(); ?&#38;gt;
&#60;/p&#62;</description>
</item>
<item>
<title>noyu on "Not show entire posts in Customised Page"</title>
<link>http://wordpress.org/support/topic/335049#post-1292927</link>
<pubDate>Wed, 25 Nov 2009 03:02:49 +0000</pubDate>
<dc:creator>noyu</dc:creator>
<guid isPermaLink="false">1292927@http://wordpress.org/support/</guid>
<description>&#60;p&#62;&#60;strong&#62;update:&#60;/strong&#62;&#60;/p&#62;
&#60;p&#62;I have not found the solution but have an &#60;strong&#62;alternative&#60;/strong&#62;.&#60;/p&#62;
&#60;p&#62;To create customised 'Pages' in wordpress, simply use put all your codes into a php file and make it a customised page template (just by adding template comment at the top. &#60;a href=&#34;http://codex.wordpress.org/Pages#Creating_Your_Own_Page_Templates)&#34; rel=&#34;nofollow&#34;&#62;http://codex.wordpress.org/Pages#Creating_Your_Own_Page_Templates)&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;Then in WP control panel,&#60;br /&#62;
Edit Page&#38;gt; Attribute &#38;gt; Template &#38;gt; choose your customised page template&#60;/p&#62;
&#60;p&#62;This way, you don't even need to use Exec-php to execute php codes in posts. Just leave the content blank and put all your content in the customised page template.&#60;/p&#62;
&#60;p&#62;hope this helps someone out there. cheers.&#60;/p&#62;
&#60;p&#62;p.s, i am still curious how to solve my previous problem. if anyone knows, do leave a comment. thanks.
&#60;/p&#62;</description>
</item>
<item>
<title>noyu on "Not show entire posts in Customised Page"</title>
<link>http://wordpress.org/support/topic/335049#post-1291967</link>
<pubDate>Tue, 24 Nov 2009 09:24:09 +0000</pubDate>
<dc:creator>noyu</dc:creator>
<guid isPermaLink="false">1291967@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Situation:&#60;br /&#62;
1. I'm using Exec-PHP plugin to allow using php in my Pages.&#60;br /&#62;
2. I save my Pages codes in an external php file and in my 'edit Page', I link it like so:&#60;br /&#62;
&#60;code&#62;&#38;lt;? require_once(ABSPATH. &#38;#39;/wp-content/custom-php/my_custom_page.php&#38;#39;); ?&#38;gt;&#60;/code&#62;&#60;br /&#62;
as suggested by someone online.&#60;br /&#62;
3. I'm using custom fields to retrieve and display only some info from 3 specific posts (i.e thumbnail and a short description).&#60;/p&#62;
&#60;p&#62;Problem:&#60;br /&#62;
I am able to display my custom fields. However, I also end up showing the 3 posts entirely at the end of my custom fields.&#60;br /&#62;
How do I prevent wordpress from showing the entire post automatically. I am not very good with php, and work through trial and error, but got stuck at this for too long already.&#60;/p&#62;
&#60;p&#62;If anyone can give me some insight, it would be much appreciated.&#60;br /&#62;
Thanks!&#60;/p&#62;
&#60;p&#62;Code:&#60;br /&#62;
page.php&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;?php get_header(); ?&#38;gt;
&#38;lt;?php include(&#38;quot;menu.php&#38;quot;); ?&#38;gt;

	&#38;lt;?php if (have_posts()) : while (have_posts()) : the_post(); ?&#38;gt;

		&#38;lt;h1&#38;gt;&#38;lt;?php the_title(); ?&#38;gt;&#38;lt;/h1&#38;gt;
			&#38;lt;div class=&#38;quot;entry&#38;quot;&#38;gt;
				&#38;lt;?php the_content(&#38;#39;&#38;lt;p class=&#38;quot;serif&#38;quot;&#38;gt;Read the rest of this page &#38;amp;raquo;&#38;lt;/p&#38;gt;&#38;#39;); ?&#38;gt;

				&#38;lt;?php wp_link_pages(array(&#38;#39;before&#38;#39; =&#38;gt; &#38;#39;&#38;lt;p&#38;gt;&#38;lt;strong&#38;gt;Pages:&#38;lt;/strong&#38;gt; &#38;#39;, &#38;#39;after&#38;#39; =&#38;gt; &#38;#39;&#38;lt;/p&#38;gt;&#38;#39;, &#38;#39;next_or_number&#38;#39; =&#38;gt; &#38;#39;number&#38;#39;)); ?&#38;gt;

			&#38;lt;/div&#38;gt;

	&#38;lt;?php endwhile; endif; ?&#38;gt;
	&#38;lt;?php edit_post_link(&#38;#39;Edit this entry.&#38;#39;, &#38;#39;&#38;lt;p&#38;gt;&#38;#39;, &#38;#39;&#38;lt;/p&#38;gt;&#38;#39;); ?&#38;gt;

&#38;lt;?php get_sidebar(); ?&#38;gt;
&#38;lt;?php get_footer(); ?&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;my_custom_page.php&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;?php query_posts(array(&#38;#39;post__in&#38;#39; =&#38;gt; array(14,17,20))); ?&#38;gt;
	&#38;lt;?php while (have_posts()) : the_post();
		global $post;
		$fdesc = get_post_meta($post-&#38;gt;ID, &#38;quot;desc&#38;quot;, TRUE); /* define the custom field with key = desc */
	?&#38;gt;
	&#38;lt;div class=&#38;quot;&#38;quot; id=&#38;quot;post-&#38;lt;?php the_ID(); ?&#38;gt;&#38;quot;&#38;gt;
		&#38;lt;p&#38;gt;&#38;lt;?php echo $fdesc; ?&#38;gt;
	&#38;lt;/div&#38;gt;

&#38;lt;?php endwhile; ?&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;One interesting thing is, I tried this code in page.php in one of my theme&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;?php if (have_posts()): ?&#38;gt;
	&#38;lt;?php the_content(&#38;#39;&#38;lt;p class=&#38;quot;serif&#38;quot;&#38;gt;Read the rest of this page &#38;amp;raquo;&#38;lt;/p&#38;gt;&#38;#39;); ?&#38;gt;

&#38;lt;?php endif; ?&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;and that seemed to solve the problem, but when i changed to my new theme, this code shows a blank page (i.e not able to direct to my custom page).
&#60;/p&#62;</description>
</item>
<item>
<title>beradmin on "How to add image to a page using custom field"</title>
<link>http://wordpress.org/support/topic/334610#post-1291604</link>
<pubDate>Mon, 23 Nov 2009 23:30:49 +0000</pubDate>
<dc:creator>beradmin</dc:creator>
<guid isPermaLink="false">1291604@http://wordpress.org/support/</guid>
<description>&#60;p&#62;You are great! THANKS!!!!!
&#60;/p&#62;</description>
</item>
<item>
<title>alchymyth on "How to add image to a page using custom field"</title>
<link>http://wordpress.org/support/topic/334610#post-1291568</link>
<pubDate>Mon, 23 Nov 2009 22:55:12 +0000</pubDate>
<dc:creator>alchymyth</dc:creator>
<guid isPermaLink="false">1291568@http://wordpress.org/support/</guid>
<description>&#60;p&#62;should work with this check to see if the custom field is used:&#60;br /&#62;
(replaces the line suggested earlier)&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;?php $key=&#38;quot;extra&#38;quot;;
if ( get_post_meta($post-&#38;gt;ID, $key, true) ) { ?&#38;gt;
&#38;lt;img class=&#38;quot;custom_image&#38;quot; src=&#38;quot;&#38;lt;?php echo get_post_meta($post-&#38;gt;ID, $key, true); ?&#38;gt;&#38;quot; alt=&#38;quot;&#38;quot; /&#38;gt;&#38;lt;?php }; ?&#38;gt;&#60;/code&#62;&#60;/pre&#62;</description>
</item>
<item>
<title>gregwilker on "Simple but useful plugin - Custom Field Panel on Dashboard???"</title>
<link>http://wordpress.org/support/topic/334897#post-1291563</link>
<pubDate>Mon, 23 Nov 2009 22:48:11 +0000</pubDate>
<dc:creator>gregwilker</dc:creator>
<guid isPermaLink="false">1291563@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Hi,&#60;/p&#62;
&#60;p&#62;I've spent most of my day today searching for and reading different hacks and plugins trying to figure out how to do this very simple task for a client of mine. &#60;/p&#62;
&#60;p&#62;All I need is this a site wide or globe custom field panel on the dashboard. nothing else just the same custom field inputs that sit on the posts and page edit screens. but on the dashboard.&#60;br /&#62;
also I would also like to know how to out put it since it's not going to be on a single page or post.&#60;br /&#62;
the could be example:&#60;br /&#62;
&#60;code&#62;&#38;lt;?php $key=&#38;quot;mykey&#38;quot;; echo get_globe_meta($globe-&#38;gt;ID, $key, true); ?&#38;gt;&#60;/code&#62;&#60;/p&#62;
&#60;p&#62;I would really love some help with this.
&#60;/p&#62;</description>
</item>
<item>
<title>beradmin on "How to add image to a page using custom field"</title>
<link>http://wordpress.org/support/topic/334610#post-1291526</link>
<pubDate>Mon, 23 Nov 2009 22:07:27 +0000</pubDate>
<dc:creator>beradmin</dc:creator>
<guid isPermaLink="false">1291526@http://wordpress.org/support/</guid>
<description>&#60;p&#62;That is great! Thanks so much. I was getting really frustrated. &#60;/p&#62;
&#60;p&#62;Only one more thing. There is a little box showing up in all pages because of the custom_image class. What 'if' code should I add so the page displays the image only if I add that custom field? Thanks :-)
&#60;/p&#62;</description>
</item>
<item>
<title>nathan12343 on "Excluding pages if there is a particular custom field"</title>
<link>http://wordpress.org/support/topic/332865#post-1291392</link>
<pubDate>Mon, 23 Nov 2009 20:02:52 +0000</pubDate>
<dc:creator>nathan12343</dc:creator>
<guid isPermaLink="false">1291392@http://wordpress.org/support/</guid>
<description>&#60;p&#62;MichaelH sorted this out in another thread.&#60;/p&#62;
&#60;p&#62;&#60;a href=&#34;http://wordpress.org/support/topic/320032&#34;&#62; &#60;a href=&#34;http://wordpress.org/support/topic/320032?replies=16&#34; rel=&#34;nofollow&#34;&#62;http://wordpress.org/support/topic/320032?replies=16&#60;/a&#62;&#60;/a&#62;
&#60;/p&#62;</description>
</item>
<item>
<title>alchymyth on "How to add image to a page using custom field"</title>
<link>http://wordpress.org/support/topic/334610#post-1290883</link>
<pubDate>Mon, 23 Nov 2009 11:27:18 +0000</pubDate>
<dc:creator>alchymyth</dc:creator>
<guid isPermaLink="false">1290883@http://wordpress.org/support/</guid>
<description>&#60;p&#62;is your image url in the 'extra' custom field?&#60;/p&#62;
&#60;p&#62;and do you want to show the image where this line&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;?php $key=&#38;quot;extra&#38;quot;; echo get_post_meta($post-&#38;gt;ID, $key, true); ?&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;is?&#60;/p&#62;
&#60;p&#62;if so, try to change the line to:&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;img class=&#38;quot;custom_image&#38;quot; src=&#38;quot;&#38;lt;?php $key=&#38;quot;extra&#38;quot;; echo get_post_meta($post-&#38;gt;ID, $key, true); ?&#38;gt;&#38;quot; alt=&#38;quot;&#38;quot; /&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;you can then style the image in your style.css using&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;.custom_image {
border: 1px solid #999;
margin: 5px 5px 5px 5px;
 and whatever style you want; }&#60;/code&#62;&#60;/pre&#62;</description>
</item>
<item>
<title>beradmin on "How to add image to a page using custom field"</title>
<link>http://wordpress.org/support/topic/334610#post-1290684</link>
<pubDate>Mon, 23 Nov 2009 05:03:07 +0000</pubDate>
<dc:creator>beradmin</dc:creator>
<guid isPermaLink="false">1290684@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Hi guys, I have searched and googled but I couldn't figure out how to make an image custom field works in my page. I have added different codes and it doesn’t work or it adds the URL if it was a text instead of adding the image. I want to add images to my page using Custom Fields. Not a loop, just a simple single image. I am new to WordPress and not good at all in PHP. I am just taking over a website that is published already.&#60;/p&#62;
&#60;p&#62;Here it is my page template (I have 2 custom fields set up already: rss and extra):&#60;/p&#62;
&#60;p&#62;&#38;lt;?php get_header(); ?&#38;gt;&#60;/p&#62;
&#60;p&#62;	&#38;lt;div id=&#34;content&#34;&#38;gt;&#60;br /&#62;
    &#38;lt;?&#60;br /&#62;
$toplevelid = $post-&#38;gt;ID;&#60;br /&#62;
if ($post-&#38;gt;post_parent)&#60;br /&#62;
{&#60;br /&#62;
$toplevelid = $post-&#38;gt;post_parent;&#60;br /&#62;
$toplevel = get_page($toplevelid);&#60;br /&#62;
if($toplevel-&#38;gt;post_parent)&#60;br /&#62;
{&#60;br /&#62;
$toplevelid = $toplevel-&#38;gt;post_parent;&#60;br /&#62;
}&#60;br /&#62;
			  }&#60;br /&#62;
?&#38;gt;&#60;/p&#62;
&#60;p&#62;&#38;lt;?php if (have_posts()) : while (have_posts()) : the_post(); ?&#38;gt;&#60;br /&#62;
		&#38;lt;div class=&#34;post&#34; id=&#34;post-&#38;lt;?php the_ID(); ?&#38;gt;&#34;&#38;gt;&#60;br /&#62;
       &#38;lt;h1 class=&#34;page-title&#34;&#38;gt;&#38;lt;span class=&#34;page-title-span&#34;&#38;gt;&#38;lt;?php the_title(); ?&#38;gt;&#38;lt;/span&#38;gt;&#38;lt;span class=&#34;title&#34;&#38;gt;&#38;lt;?php echo get_the_title($toplevelid); ?&#38;gt;&#38;lt;/span&#38;gt;&#38;lt;/h1&#38;gt;&#60;br /&#62;
			&#38;lt;div class=&#34;entry&#34;&#38;gt;&#60;/p&#62;
&#60;p&#62;&#38;lt;?php $key=&#34;extra&#34;; echo get_post_meta($post-&#38;gt;ID, $key, true); ?&#38;gt;&#60;br /&#62;
		&#60;/p&#62;
&#60;p&#62;			&#38;lt;?php&#60;/p&#62;
&#60;p&#62;			$key=&#34;rss&#34;;&#60;br /&#62;
			$feedURL = get_post_meta($post-&#38;gt;ID, $key, true);&#60;/p&#62;
&#60;p&#62;			if ($feedURL) {&#60;br /&#62;
				$feed = new SimplePie($feedURL);&#60;/p&#62;
&#60;p&#62;				$item = $feed-&#38;gt;get_item();&#60;br /&#62;
				print $item-&#38;gt;get_content();&#60;br /&#62;
			} ?&#38;gt;&#60;/p&#62;
&#60;p&#62;				&#38;lt;?php the_content('&#38;lt;p class=&#34;serif&#34;&#38;gt;Read the rest of this page &#38;raquo;&#38;lt;/p&#38;gt;'); ?&#38;gt;	&#60;/p&#62;
&#60;p&#62;				&#38;lt;?php wp_link_pages(array('before' =&#38;gt; '&#38;lt;p&#38;gt;&#60;strong&#62;Pages:&#60;/strong&#62; ', 'after' =&#38;gt; '&#38;lt;/p&#38;gt;', 'next_or_number' =&#38;gt; 'number')); ?&#38;gt;&#60;/p&#62;
&#60;p&#62;			&#38;lt;/div&#38;gt;&#38;lt;!-- close .entry --&#38;gt;&#60;br /&#62;
		&#38;lt;?php endwhile; endif; ?&#38;gt;&#60;br /&#62;
		&#38;lt;?php edit_post_link('Edit this entry.', '&#38;lt;p&#38;gt;', '&#38;lt;/p&#38;gt;'); ?&#38;gt;&#60;br /&#62;
		&#38;lt;/div&#38;gt;&#38;lt;!-- close .post --&#38;gt;&#60;br /&#62;
    &#38;lt;/div&#38;gt;&#60;br /&#62;
     &#38;lt;/div&#38;gt;&#38;lt;!-- close #content --&#38;gt;&#60;/p&#62;
&#60;p&#62;&#38;lt;?php get_footer(); ?&#38;gt;
&#60;/p&#62;</description>
</item>
<item>
<title>jvinch on "Display posts with the same custom field value as the current post"</title>
<link>http://wordpress.org/support/topic/334007#post-1288964</link>
<pubDate>Sat, 21 Nov 2009 05:57:31 +0000</pubDate>
<dc:creator>jvinch</dc:creator>
<guid isPermaLink="false">1288964@http://wordpress.org/support/</guid>
<description>&#60;p&#62;You may want to look at using custom taxonomies for this. &#60;/p&#62;
&#60;p&#62;&#60;a href=&#34;http://justintadlock.com/archives/2009/05/06/custom-taxonomies-in-wordpress-28&#34; rel=&#34;nofollow&#34;&#62;http://justintadlock.com/archives/2009/05/06/custom-taxonomies-in-wordpress-28&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;It would work the way you envisioned with tags and categories more or less out of the box. The above post has plenty of examples in it.
&#60;/p&#62;</description>
</item>
<item>
<title>MichaelH on "Display posts with the same custom field value as the current post"</title>
<link>http://wordpress.org/support/topic/334007#post-1288935</link>
<pubDate>Sat, 21 Nov 2009 04:18:05 +0000</pubDate>
<dc:creator>MichaelH</dc:creator>
<guid isPermaLink="false">1288935@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Might want to see if this plugins will help:&#60;/p&#62;
&#60;p&#62;&#60;a href=&#34;http://wordpress.org/extend/plugins/custom-field-taxonomies/&#34; rel=&#34;nofollow&#34;&#62;http://wordpress.org/extend/plugins/custom-field-taxonomies/&#60;/a&#62;
&#60;/p&#62;</description>
</item>
<item>
<title>tgildred on "Display posts with the same custom field value as the current post"</title>
<link>http://wordpress.org/support/topic/334007#post-1288838</link>
<pubDate>Sat, 21 Nov 2009 00:48:20 +0000</pubDate>
<dc:creator>tgildred</dc:creator>
<guid isPermaLink="false">1288838@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Hi, I've searched everywhere and can't find an exact answer for what I'm trying to do. &#60;/p&#62;
&#60;p&#62;I have given my posts a set of custom fields, for instance: project_type = magazine. These fields are then displayed in the post on my site. I'd like to be able to turn that field value in each post into a link that, when clicked, would take the user to listing of all posts of that project type. The same way that clicking a tag or category would take you to all posts with that tag or category. I just can't figure out how to accomplish this, though.&#60;/p&#62;
&#60;p&#62;Here's the code from single.php:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;?php get_header(); ?&#38;gt;
	&#38;lt;div id=&#38;quot;content&#38;quot;&#38;gt;
		&#38;lt;?php if (have_posts()) : ?&#38;gt;
			&#38;lt;?php the_post(); ?&#38;gt;
			&#38;lt;div class=&#38;quot;post&#38;quot;&#38;gt;
				&#38;lt;?php skimmed_milk_post_title(&#38;#39;h2&#38;#39;); ?&#38;gt;

				&#38;lt;div class=&#38;quot;entry&#38;quot;&#38;gt;
					&#38;lt;?php skimmed_milk_post_entry(); ?&#38;gt;
				&#38;lt;/div&#38;gt;&#38;lt;!-- entry --&#38;gt;
                &#38;lt;div class=&#38;quot;metadata&#38;quot;&#38;gt;
	                &#38;lt;div class=&#38;quot;top&#38;quot;&#38;gt;&#38;lt;/div&#38;gt;
                	&#38;lt;div class=&#38;quot;navigation&#38;quot;&#38;gt;
						&#38;lt;div class=&#38;quot;alignleft&#38;quot;&#38;gt;&#38;lt;?php next_post_link(&#38;#39;&#38;amp;laquo; %link&#38;#39;, &#38;#39;Previous&#38;#39;, TRUE); ?&#38;gt;&#38;lt;/div&#38;gt;
						&#38;lt;div class=&#38;quot;alignright&#38;quot;&#38;gt;&#38;lt;?php previous_post_link(&#38;#39;%link &#38;amp;raquo;&#38;#39;, &#38;#39;Next&#38;#39;, TRUE); ?&#38;gt;&#38;lt;/div&#38;gt;
						&#38;lt;div class=&#38;quot;snap-to-fit&#38;quot;&#38;gt;&#38;lt;/div&#38;gt;
					&#38;lt;/div&#38;gt;&#38;lt;!-- navigation --&#38;gt;
                	&#38;lt;p class=&#38;quot;postmetadata alt &#38;quot;&#38;gt;
						&#38;lt;?php
							$dateString = __(&#38;#39;F jS, Y&#38;#39;, &#38;#39;skimmed&#38;#39;);
							printf(__(&#38;#39;Posted in %1$s on %2$s&#38;#39;, &#38;#39;skimmed&#38;#39;),
								get_the_category_list(&#38;#39;, &#38;#39;),
								apply_filters(&#38;#39;the_time&#38;#39;, get_the_time($dateString), $dateString),
								apply_filters(&#38;#39;the_time&#38;#39;, get_the_time(&#38;#39;&#38;#39;), &#38;#39;&#38;#39;));
							the_tags(&#38;#39;&#38;lt;br /&#38;gt;&#38;#39; . __(&#38;#39;Tagged with &#38;#39;, &#38;#39;skimmed&#38;#39;), &#38;#39;, &#38;#39;, &#38;#39; &#38;#39;);
						?&#38;gt;
						&#38;lt;br /&#38;gt;Project Type: &#38;lt;?php if ( function_exists(&#38;#39;get_custom_field_value&#38;#39;) ){ get_custom_field_value(&#38;#39;project_type&#38;#39;, true); } ?&#38;gt;
						&#38;lt;br /&#38;gt;Client: &#38;lt;?php if ( function_exists(&#38;#39;get_custom_field_value&#38;#39;) ){ get_custom_field_value(&#38;#39;client&#38;#39;, true); } ?&#38;gt;
						&#38;lt;br /&#38;gt;Description: &#38;lt;?php if ( function_exists(&#38;#39;get_custom_field_value&#38;#39;) ){ get_custom_field_value(&#38;#39;description&#38;#39;, true); } ?&#38;gt;
					&#38;lt;/p&#38;gt;
                &#38;lt;div class=&#38;quot;bottom&#38;quot;&#38;gt;&#38;lt;/div&#38;gt;
                &#38;lt;/div&#38;gt;
			&#38;lt;/div&#38;gt;&#38;lt;!-- post --&#38;gt;
			&#38;lt;?php comments_template();
		else : // no posts
			skimmed_milk_something_not_found(__(&#38;#39;Post not found&#38;#39;, &#38;#39;skimmed&#38;#39;));
		endif; // end if have posts ?&#38;gt;
	&#38;lt;/div&#38;gt;&#38;lt;!-- content --&#38;gt;
&#38;lt;?php get_sidebar(); ?&#38;gt;
&#38;lt;?php get_footer(); ?&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;And the archive.php:&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;?php get_header(); ?&#38;gt;

	&#38;lt;div id=&#38;quot;content&#38;quot;&#38;gt;

		&#38;lt;?php if (have_posts()) :

			if (is_category()) $archive_display_name = single_cat_title(&#38;#39;&#38;#39;, false);
			elseif (is_tag()) $archive_display_name = single_tag_title(&#38;#39;&#38;#39;, false);
			elseif (is_day()) $archive_display_name = get_the_time(__(&#38;#39;F jS, Y&#38;#39;, &#38;#39;skimmed&#38;#39;));
			elseif (is_month()) $archive_display_name = get_the_time(__(&#38;#39;F Y&#38;#39;, &#38;#39;skimmed&#38;#39;));
			elseif (is_year()) $archive_display_name = get_the_time(__(&#38;#39;Y&#38;#39;, &#38;#39;skimmed&#38;#39;));
		?&#38;gt;
			&#38;lt;?php if (is_category()) : ?&#38;gt;
				&#38;lt;h2 class=&#38;quot;pagetitle&#38;quot;&#38;gt;&#38;lt;span class=&#38;quot;darkorange&#38;quot;&#38;gt;/&#38;lt;/span&#38;gt;&#38;lt;span class=&#38;quot;lightorange&#38;quot;&#38;gt;/&#38;lt;/span&#38;gt; &#38;lt;?php printf(__(&#38;#39;%s&#38;#39;, &#38;#39;skimmed&#38;#39;),  $archive_display_name); ?&#38;gt;&#38;lt;/h2&#38;gt;
			&#38;lt;?php elseif (is_tag()) : ?&#38;gt;
				&#38;lt;h2 class=&#38;quot;pagetitle&#38;quot;&#38;gt;&#38;lt;?php printf(__(&#38;#39;Posts tagged with %s&#38;#39;, &#38;#39;skimmed&#38;#39;),  $archive_display_name); ?&#38;gt;&#38;lt;/h2&#38;gt;
			&#38;lt;?php else : ?&#38;gt;
				&#38;lt;h2 class=&#38;quot;pagetitle&#38;quot;&#38;gt;&#38;lt;?php printf(__(&#38;#39;%s Archive&#38;#39;, &#38;#39;skimmed&#38;#39;), $archive_display_name); ?&#38;gt;&#38;lt;/h2&#38;gt;
			&#38;lt;?php endif;
			skimmed_milk_nav_link(sprintf(__(&#38;#39;Later %s posts&#38;#39;, &#38;#39;skimmed&#38;#39;), $archive_display_name), &#38;#39;&#38;#39;);
			while (have_posts()) : the_post();
				global $page; $page = 1; ?&#38;gt;
				&#38;lt;div class=&#38;quot;thumb&#38;quot;&#38;gt;
					&#38;lt;div class=&#38;quot;thumb_excerpt&#38;quot;&#38;gt;
						&#38;lt;?php the_excerpt(&#38;#39;&#38;lt;span class=&#38;quot;nowrap&#38;quot;&#38;gt;&#38;#39; . __(&#38;#39;Read more&#38;#39;, &#38;#39;skimmed&#38;#39;) . &#38;#39; &#38;amp;raquo;&#38;lt;/span&#38;gt;&#38;#39;); ?&#38;gt;
					&#38;lt;/div&#38;gt;&#38;lt;!-- entry --&#38;gt;
                    &#38;lt;div class=&#38;quot;thumb_title&#38;quot;&#38;gt;
                        &#38;lt;?php if ( get_post_meta($post-&#38;gt;ID, &#38;#39;project_type&#38;#39;, true) ) { ?&#38;gt;
						&#38;lt;h3&#38;gt;&#38;lt;a href=&#38;quot;&#38;lt;?php echo get_permalink(); ?&#38;gt;&#38;quot; rel=&#38;quot;bookmark&#38;quot; title=&#38;quot;&#38;lt;?php printf(__(&#38;quot;Permanent link to &#38;#39;%s&#38;#39;&#38;quot;, &#38;#39;skimmed&#38;#39;), the_title_attribute(array(&#38;#39;echo&#38;#39; =&#38;gt; false))); ?&#38;gt;&#38;quot;&#38;gt;&#38;lt;?php echo get_post_meta($post-&#38;gt;ID, &#38;quot;project_type&#38;quot;, $single = true); ?&#38;gt;&#38;lt;?php } ?&#38;gt;&#38;lt;/a&#38;gt;&#38;lt;/h3&#38;gt;
						&#38;lt;?php if( ! is_year()) : // don&#38;#39;t show content if is full year archive ?&#38;gt;
					&#38;lt;/div&#38;gt;
					&#38;lt;?php endif; ?&#38;gt;
					&#38;lt;!-- &#38;lt;?php trackback_rdf(); ?&#38;gt; --&#38;gt;
				&#38;lt;/div&#38;gt; &#38;lt;!-- post --&#38;gt;
			&#38;lt;?php endwhile;
			skimmed_milk_nav_link(&#38;#39;&#38;#39;, sprintf(__(&#38;#39;Earlier %s posts&#38;#39;, &#38;#39;skimmed&#38;#39;), $archive_display_name));
		else : // no posts
			skimmed_milk_something_not_found(__(&#38;#39;Archive not found&#38;#39;, &#38;#39;skimmed&#38;#39;));
		endif; // end if have posts ?&#38;gt;
	&#38;lt;/div&#38;gt;&#38;lt;!-- content --&#38;gt;
&#38;lt;?php get_sidebar(); ?&#38;gt;
&#38;lt;?php get_footer(); ?&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;I've reached the limits of abilities with this one. If anyone could point me in the direction of how to accomplish this, I would really appreciate it. I'm very new at this, so if there's any information I've left out, please let me know!&#60;/p&#62;
&#60;p&#62;Thanks.
&#60;/p&#62;</description>
</item>
<item>
<title>MichaelH on "List a selected parents subpages with custom fields"</title>
<link>http://wordpress.org/support/topic/333656#post-1288832</link>
<pubDate>Sat, 21 Nov 2009 00:43:42 +0000</pubDate>
<dc:creator>MichaelH</dc:creator>
<guid isPermaLink="false">1288832@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Should this:&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;echo get_post_meta($post-&#38;gt;ID, $key, true)&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;be:&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;echo get_post_meta($pageChild-&#38;gt;ID, $key, true)&#60;/code&#62;&#60;/pre&#62;</description>
</item>
<item>
<title>db1987 on "List a selected parents subpages with custom fields"</title>
<link>http://wordpress.org/support/topic/333656#post-1287458</link>
<pubDate>Thu, 19 Nov 2009 23:05:28 +0000</pubDate>
<dc:creator>db1987</dc:creator>
<guid isPermaLink="false">1287458@http://wordpress.org/support/</guid>
<description>&#60;p&#62;I am using flutter, and I would like to list a selected parents child pages along with a custom field which I assigned to them using flutter.&#60;/p&#62;
&#60;p&#62;Please if anyone has any insight help me out. I can get the pages to list using:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;?php
$pageChildren = get_pages(&#38;#39;sort_column=menu_order&#38;amp;hierarchical=0&#38;amp;child_of=&#38;#39;. &#38;#39;134&#38;#39;);
if ( $pageChildren ) {
  foreach ( $pageChildren as $pageChild ) {
    echo &#38;#39;&#38;lt;li&#38;gt;&#38;lt;a href=&#38;quot;&#38;#39; . get_permalink($pageChild-&#38;gt;ID) . &#38;#39;&#38;quot;&#38;gt;&#38;#39;. $pageChild-&#38;gt;post_title.&#38;#39;&#38;lt;/a&#38;gt;&#38;lt;/li&#38;gt;&#38;#39;;
      echo &#38;#39;&#38;lt;li&#38;gt;&#38;#39;.$key=&#38;quot;toolname&#38;quot;; echo get_post_meta($post-&#38;gt;ID, $key, true).&#38;#39;&#38;lt;/li&#38;gt;&#38;#39;;
    }
}
?&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;Unfortunately the customfield &#34;TOOLNAME&#34; does not show my customfield.&#60;/p&#62;
&#60;p&#62;Thanks in advance
&#60;/p&#62;</description>
</item>
<item>
<title>litetheme on "Press This - Adding Custom Field"</title>
<link>http://wordpress.org/support/topic/333549#post-1287083</link>
<pubDate>Thu, 19 Nov 2009 17:56:21 +0000</pubDate>
<dc:creator>litetheme</dc:creator>
<guid isPermaLink="false">1287083@http://wordpress.org/support/</guid>
<description>&#60;p&#62;What I'm trying to do is hit &#34;Press This&#34; on any website and get the url to store into a new custom field. This custom field will serve as an external link to place anywhere in my theme.&#60;/p&#62;
&#60;p&#62;On the theme, (typically single.php)&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;?php
$elink = get_post_meta($post-&#38;gt;ID, &#38;#39;elink&#38;#39;, true);
?&#38;gt;
&#38;lt;?php echo $elink ?&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;Now, if I were to use a normal Post editor, I would have to key in 'elink' in the Name field and the Url in the Value field.&#60;/p&#62;
&#60;p&#62;This works like charm. I'm able to see my link on the Single.php (theme)&#60;/p&#62;
&#60;p&#62;The bad news is, I still haven't got it to play nicely with &#34;Press This&#34;&#60;/p&#62;
&#60;p&#62;What I did was&#60;/p&#62;
&#60;p&#62;1. Add the following line in wp-admin/press-this.php, line :559&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;Link: &#38;lt;input name=&#38;quot;elink&#38;quot; type=&#38;quot;text&#38;quot;  id=&#38;quot;elink&#38;quot; class=&#38;quot;mceEditor&#38;quot; style=&#38;quot;width:100%;&#38;quot; value=&#38;quot;&#38;lt;?php echo $url; ?&#38;gt;&#38;quot;/&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;(this basically inserts URL into an input field.)&#60;/p&#62;
&#60;p&#62;2. Add this to press-this.php, line: 48&#60;br /&#62;
&#60;pre&#62;&#60;code&#62;$elink = $_REQUEST[&#38;#39;elink&#38;#39;];&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;(this is supposed to declare $elink as a varible)&#60;/p&#62;
&#60;p&#62;The problem I am having is, the URL is not sticking to the post. In other words, it's not inserted into the database.&#60;/p&#62;
&#60;p&#62;I'm not a programmer, so please let me know where I screwed up. Thank you in advance.
&#60;/p&#62;</description>
</item>
<item>
<title>nathan12343 on "Excluding pages if there is a particular custom field"</title>
<link>http://wordpress.org/support/topic/332865#post-1285897</link>
<pubDate>Wed, 18 Nov 2009 19:10:53 +0000</pubDate>
<dc:creator>nathan12343</dc:creator>
<guid isPermaLink="false">1285897@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Why doesn't this work???? I've got pages with a custom field of &#34;notmobile&#34; and a value of &#34;notmobile&#34;. These are the only ones that use this field. And this is the only time this value will appear.&#60;/p&#62;
&#60;p&#62;This is the code I'm using: &#60;/p&#62;
&#60;pre&#62;&#60;code&#62;&#38;lt;?php
$menulist = get_children(&#38;#39;meta_compare=!=&#38;amp;meta_value=notmobile&#38;amp;post_type=page&#38;amp;orderby=menu_order&#38;amp;order=ASC&#38;amp;post_parent=&#38;#39;.$post-&#38;gt;ID);
       if(is_array($menulist) &#38;amp;&#38;amp; count($menulist) &#38;gt; 0) :?&#38;gt;
	   &#38;lt;ul id=&#38;quot;relative&#38;quot;&#38;gt;&#38;lt;?php foreach ($menulist as $post) : ?&#38;gt;
        &#38;lt;li&#38;gt;&#38;lt;a href=&#38;quot;&#38;lt;?php the_permalink(); ?&#38;gt;&#38;quot;&#38;gt;&#38;lt;?php the_title(); ?&#38;gt;&#38;lt;/a&#38;gt;&#38;lt;/li&#38;gt;
 &#38;lt;?php endforeach; ?&#38;gt;
&#38;lt;/ul&#38;gt;
&#38;lt;?php else : ?&#38;gt;
&#38;lt;!-- no children --&#38;gt;
&#38;lt;?php endif; ?&#38;gt;&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;If I remove meta_compare=!= then only the two menu items that have a value of &#34;notmobile&#34; appear. Why can't I get it to exclude them?&#60;/p&#62;
&#60;p&#62;Any help would be really, really appreciated!
&#60;/p&#62;</description>
</item>
<item>
<title>nathan12343 on "Excluding pages if there is a particular custom field"</title>
<link>http://wordpress.org/support/topic/332865#post-1285438</link>
<pubDate>Wed, 18 Nov 2009 10:39:06 +0000</pubDate>
<dc:creator>nathan12343</dc:creator>
<guid isPermaLink="false">1285438@http://wordpress.org/support/</guid>
<description>&#60;p&#62;I've been trying out other stuff, and it's just not working because of a conflict with another function. But it seems to me that all I really need to do is hide it from the menu.&#60;/p&#62;
&#60;p&#62;So, is there a way that I can exlude a page from wp_list_pages because of a tag or a custom field?
&#60;/p&#62;</description>
</item>
<item>
<title>dovydas on "custom field content question"</title>
<link>http://wordpress.org/support/topic/332507#post-1285266</link>
<pubDate>Wed, 18 Nov 2009 04:57:45 +0000</pubDate>
<dc:creator>dovydas</dc:creator>
<guid isPermaLink="false">1285266@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Thank you, Michael.&#60;br /&#62;
It's working now. :)
&#60;/p&#62;</description>
</item>
<item>
<title>Yakitos on "Changing the default length of the_excerpt"</title>
<link>http://wordpress.org/support/topic/231953#post-1285161</link>
<pubDate>Wed, 18 Nov 2009 02:13:51 +0000</pubDate>
<dc:creator>Yakitos</dc:creator>
<guid isPermaLink="false">1285161@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Why is this post marked as resolved? I am using 2.8.6 and the following code on my functions.php and it is not working.&#60;/p&#62;
&#60;p&#62;add_filter('excerpt_length', 'new_excerpt_length');&#60;br /&#62;
function new_excerpt_length($length) {&#60;br /&#62;
	return 10;&#60;br /&#62;
}&#60;/p&#62;
&#60;p&#62;Which table can I check in order to see if the filter is actually there?&#60;/p&#62;
&#60;p&#62;Thanks!
&#60;/p&#62;</description>
</item>
<item>
<title>nathan12343 on "Excluding pages if there is a particular custom field"</title>
<link>http://wordpress.org/support/topic/332865#post-1284901</link>
<pubDate>Tue, 17 Nov 2009 22:00:54 +0000</pubDate>
<dc:creator>nathan12343</dc:creator>
<guid isPermaLink="false">1284901@http://wordpress.org/support/</guid>
<description>&#60;p&#62;I've got a site where different content will be shown if you are looking at it through a desktop or a phone/PDA etc. There are different template files for each.&#60;/p&#62;
&#60;p&#62;I have been trying to &#60;strong&#62;exclude&#60;/strong&#62; certain pages from the mobile version if it has a custom field (e.g. key=for mobile value=no). I wanted to do this in the loop through wp_query() because there is a menu generation in the page that needs to exlude these pages too.&#60;/p&#62;
&#60;p&#62;I can see how to do this inclusively, but I've hit a bit of a wall and could do with a helping hand! (I could easily be pursuaded to do the same through a tag (e.g. notMobile) if it is easier.)&#60;/p&#62;
&#60;p&#62;Thanks
&#60;/p&#62;</description>
</item>
<item>
<title>lokrin2000 on "Where do I put this snippet I found."</title>
<link>http://wordpress.org/support/topic/332722#post-1284768</link>
<pubDate>Tue, 17 Nov 2009 20:09:49 +0000</pubDate>
<dc:creator>lokrin2000</dc:creator>
<guid isPermaLink="false">1284768@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Yes.  Yes it is.  &#60;/p&#62;
&#60;p&#62;This is a forum.  It is not an &#60;strong&#62;&#60;em&#62;Instant&#60;/em&#62;&#60;/strong&#62; Messenger.  You may have to wait a day or two for an answer.&#60;/p&#62;
&#60;p&#62;I'm not good at php and I don't know your theme so I can't help.  &#60;/p&#62;
&#60;p&#62;I find it easiest to subscribe to rss feeds here so I can see when people post answers to my questions.
&#60;/p&#62;</description>
</item>
<item>
<title>MichaelH on "custom field content question"</title>
<link>http://wordpress.org/support/topic/332507#post-1284622</link>
<pubDate>Tue, 17 Nov 2009 18:09:03 +0000</pubDate>
<dc:creator>MichaelH</dc:creator>
<guid isPermaLink="false">1284622@http://wordpress.org/support/</guid>
<description>&#60;p&#62;You'll still want to use the &#60;a href=&#34;http://codex.wordpress.org/Conditional_Tags&#34;&#62;Conditional Tags&#60;/a&#62; such as is_page().
&#60;/p&#62;</description>
</item>
<item>
<title>moonfu on "Where do I put this snippet I found."</title>
<link>http://wordpress.org/support/topic/332722#post-1284591</link>
<pubDate>Tue, 17 Nov 2009 17:38:56 +0000</pubDate>
<dc:creator>moonfu</dc:creator>
<guid isPermaLink="false">1284591@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Is this thing on?
&#60;/p&#62;</description>
</item>
<item>
<title>dovydas on "custom field content question"</title>
<link>http://wordpress.org/support/topic/332507#post-1284513</link>
<pubDate>Tue, 17 Nov 2009 16:29:35 +0000</pubDate>
<dc:creator>dovydas</dc:creator>
<guid isPermaLink="false">1284513@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Hi Michael,&#60;/p&#62;
&#60;p&#62;Thanks for helping me. It is working! I have added a cutom field value and key check and my content appears only on correct page now. That's exactly what I wanted. However original content disappeared on all other pages and posts.&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;function load_runninglog() {
  global $post;
  $custom_field_key = &#38;#39;load_runninglog&#38;#39;;
  $one_custom_field_value = get_post_meta($post-&#38;gt;ID, $custom_field_key, true);
  if ($one_custom_field_value == &#38;#39;races&#38;#39;) {
    $content = &#38;#39;It works! for post id &#38;#39;. $post-&#38;gt;ID;
  }
  return $content;
}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;How can I avoid messing up with other content?
&#60;/p&#62;</description>
</item>
<item>
<title>moonfu on "Where do I put this snippet I found."</title>
<link>http://wordpress.org/support/topic/332722#post-1284463</link>
<pubDate>Tue, 17 Nov 2009 15:38:58 +0000</pubDate>
<dc:creator>moonfu</dc:creator>
<guid isPermaLink="false">1284463@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Any ideas? I'm just needing a simple answer so I can try it out.&#60;/p&#62;
&#60;p&#62;If it's to vague of a post just let me know.&#60;/p&#62;
&#60;p&#62;thanks
&#60;/p&#62;</description>
</item>
<item>
<title>moonfu on "Where do I put this snippet I found."</title>
<link>http://wordpress.org/support/topic/332722#post-1284417</link>
<pubDate>Tue, 17 Nov 2009 14:54:58 +0000</pubDate>
<dc:creator>moonfu</dc:creator>
<guid isPermaLink="false">1284417@http://wordpress.org/support/</guid>
<description>&#60;p&#62;This code snippet was marked as incomplete but I want to have this work on my WPtube3 theme I'm using with the video swiper plugin activated. The tube theme from freewptube has a thumb custom field function but the videoswiper plugin overrides the field &#34;thumb&#34; if created in the post.conflicting custom fields? I'm not sure why. I'm new I guess.&#60;/p&#62;
&#60;p&#62;I thought this snippet might help but I don't know where to put it.&#60;br /&#62;
or if it will work. If anyone can tell me a solution or how to use this code I would appreciate it.&#60;br /&#62;
&#38;lt;?php&#60;/p&#62;
&#60;p&#62;function prefix_get_image_thumb($post_id) {&#60;/p&#62;
&#60;p&#62;global $wpdb;&#60;/p&#62;
&#60;p&#62;$attachment_id = $wpdb-&#38;gt;get_var(&#34;SELECT ID FROM $wpdb-&#38;gt;posts WHERE post_parent = '$post_id' AND post_status = 'inherit' AND post_type='attachment' ORDER BY post_date DESC LIMIT 1&#34;);&#60;/p&#62;
&#60;p&#62;$thumb = get_attachment_icon($attachment_id);&#60;/p&#62;
&#60;p&#62;echo $thumb;&#60;/p&#62;
&#60;p&#62;}&#60;/p&#62;
&#60;p&#62;?&#38;gt;
&#60;/p&#62;</description>
</item>
<item>
<title>MichaelH on "custom field content question"</title>
<link>http://wordpress.org/support/topic/332507#post-1284361</link>
<pubDate>Tue, 17 Nov 2009 13:53:18 +0000</pubDate>
<dc:creator>MichaelH</dc:creator>
<guid isPermaLink="false">1284361@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Use global $post&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;function load_runninglog() {
global $post;
$content = &#38;quot;It&#38;#39;s working! for post id &#38;quot;. $post-&#38;gt;ID;
$custom_field_key = &#38;#39;cf1&#38;#39;
$one_custom_field_value = get_post_meta($post-&#38;gt;ID, $custom_field_key, true);
return $content;
}
add_filter(&#38;#39;the_content&#38;#39;, &#38;#39;load_runninglog&#38;#39;);&#60;/code&#62;&#60;/pre&#62;</description>
</item>
<item>
<title>dovydas on "custom field content question"</title>
<link>http://wordpress.org/support/topic/332507#post-1284334</link>
<pubDate>Tue, 17 Nov 2009 13:24:40 +0000</pubDate>
<dc:creator>dovydas</dc:creator>
<guid isPermaLink="false">1284334@http://wordpress.org/support/</guid>
<description>&#60;p&#62;Hi,&#60;/p&#62;
&#60;p&#62;What I am actually trying to achieve is to have a separate page where my data could be displayed. At first I wanted the plugin to create a page automatically (by entering page name in options menu) but it seems not possible. So a user will have to create a page himself and add a custom field with function from plugin. Then this function will display content in that page.&#60;/p&#62;
&#60;p&#62;I have found working example in another plugin, however I'm struggling to adapt it to my needs.&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;function load_runninglog($content) {
  if (is_page()) {
    $cust_values = get_post_custom_values($this-&#38;gt;runninglog_show);
    if ($cust_values != NULL) {
      $log_target = $cust_values[0];
      $content = $this-&#38;gt;display_runninglog($log_target);
    }
  }
  return $content;
}

function display_runninglog($log_target) {
  echo &#38;quot;It&#38;#39;s working!&#38;quot;
}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;I get the following error. &#60;strong&#62;Fatal error&#60;/strong&#62;: Using $this when not in object context in &#60;strong&#62;/var/www/wp-content/plugins/running-log/running-log.php&#60;/strong&#62; on line &#60;strong&#62;264&#60;/strong&#62;.&#60;/p&#62;
&#60;p&#62;I understand I need to get classes involved here. However I'm trying to avoid them as classes go beyond my meager programming knowledge. Is there a way to pass the post id into the function and test if the custom field exists for that post id without using classes?
&#60;/p&#62;</description>
</item>

</channel>
</rss>
