<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.1" -->
<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"
		>
	<channel>
		<title>WordPress Ideas &#187; Tag: WP_Internal_Pointers - Recent Posts</title>
		<link>http://wordpress.org/ideas/tags/wp_internal_pointers</link>
		<description>WordPress Ideas &#187; Tag: WP_Internal_Pointers - Recent Posts</description>
		<language>en-US</language>
		<pubDate>Sat, 25 May 2013 10:16:47 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.1</generator>
				<atom:link href="http://wordpress.org/ideas/rss/tags/wp_internal_pointers" rel="self" type="application/rss+xml" />

		<item>
			<title>nic0tin on "Update WP_Internal_Pointers::print_js from Private to Public"</title>
			<link>http://wordpress.org/ideas/topic/update-wp_internal_pointersprint_js-from-private-to-public#post-24150</link>
			<pubDate>Tue, 05 Feb 2013 15:25:28 +0000</pubDate>
			<dc:creator>nic0tin</dc:creator>
			<guid isPermaLink="false">24150@http://wordpress.org/ideas/</guid>
			<description><![CDATA[<p>Hello,</p>
<p>Today I wanted to use WP_Internal_Pointers in the public side of my intranet blog based on WP 3.5, but I had to change the core file "wp-admin/includes/template.php" for the static function "print_js" from private to public.</p>
<p>I did so for running this code (themes/theme_name/functions.php):<br />
<pre><code>function gp_reveal_pointers()
{
	global $wp_scripts;

	$wp_scripts-&#62;localize( &#039;wp-pointer&#039;, &#039;wpPointerL10n&#039;, array(
			&#039;dismiss&#039; =&#62; __(&#039;Dismiss&#039;),
		) ); // Retrieve Dismiss translated text
	$dismissed = array_filter( explode( &#039;,&#039;, (string) get_user_meta( get_current_user_id(), &#039;dismissed_wp_pointers&#039;, true ) ) );

	if ( in_array( &#039;gp110_revues&#039;, $dismissed ) ) // Already dismissed? Nothing to display.
		return;

	if(!class_exists(&#34;WP_Internal_Pointers&#34;))
		include(ABSPATH .&#34;/wp-admin/includes/template.php&#34;);
	$content = &#039;&#60;h3&#62;My title&#60;/h3&#62;&#039;
			  .&#039;&#60;p&#62;My content.&#60;/p&#62;&#039;;
	$position = array( &#039;edge&#039; =&#62; &#039;bottom&#039;, &#039;align&#039; =&#62; &#039;center&#039; );
	WP_Internal_Pointers::print_js(&#039;gp110_revues&#039;, &#039;.widget-revues&#039;, array(&#039;content&#039; =&#62; $content, &#039;position&#039; =&#62; $position));
?&#62;
&#60;script type=&#34;text/javascript&#34;&#62;
/* &#60;![CDATA[ */
var ajaxurl = &#34;&#60;?php echo admin_url(&#039;admin-ajax.php&#039;); ?&#62;&#34;;
/* ]]&#62; */
&#60;/script&#62;
&#60;?php
}
add_action(&#039;get_footer&#039;, &#039;gp_reveal_pointers&#039;);</code></pre>
<p>I thought it would be a good thing to change the print_js function from private to public unless off course it's considered as too critical to be publicly exposed.
</p>]]></description>
					</item>

	</channel>
</rss>
