<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.0.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>Gravity Support Forums Topic: remove_menu_page breaks form edit interface</title>
		<link>https://legacy.forums.gravityhelp.com/topic/remove_menu_page-breaks-form-edit-interface</link>
		<description>Gravity Support Forums Topic: remove_menu_page breaks form edit interface</description>
		<language>en-US</language>
		<pubDate>Sun, 05 Apr 2026 21:20:10 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.0.1</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>https://legacy.forums.gravityhelp.com/search.php</link>
		</textInput>
		<atom:link href="https://legacy.forums.gravityhelp.com/rss/topic/remove_menu_page-breaks-form-edit-interface" rel="self" type="application/rss+xml" />

		<item>
			<title>Chris Hajer on "remove_menu_page breaks form edit interface"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/remove_menu_page-breaks-form-edit-interface#post-102226</link>
			<pubDate>Thu, 13 Dec 2012 12:54:22 +0000</pubDate>
			<dc:creator>Chris Hajer</dc:creator>
			<guid isPermaLink="false">102226@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Thank you for that update.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Matt Banks on "remove_menu_page breaks form edit interface"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/remove_menu_page-breaks-form-edit-interface#post-102207</link>
			<pubDate>Thu, 13 Dec 2012 12:20:15 +0000</pubDate>
			<dc:creator>Matt Banks</dc:creator>
			<guid isPermaLink="false">102207@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I did a but more digging and found out the recommended hook has changed for removing menu pages. I had it hooked to admin_init, which was running entirely too soon. Changed it to hook into admin_menu and it now form editing is not broken!&#60;/p&#62;
&#60;p&#62;Here's the proper revised code that works, in case others see this and wonder what's needed:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;// Hide Admin Areas that are not used
add_action( &#38;#39;admin_menu&#38;#39;, &#38;#39;my_remove_menu_pages&#38;#39; );
function my_remove_menu_pages() {
	remove_menu_page(&#38;#39;edit.php&#38;#39;);
	remove_menu_page(&#38;#39;edit-comments.php&#38;#39;);
}&#60;/code&#62;&#60;/pre&#62;</description>
		</item>
		<item>
			<title>Matt Banks on "remove_menu_page breaks form edit interface"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/remove_menu_page-breaks-form-edit-interface#post-102204</link>
			<pubDate>Thu, 13 Dec 2012 12:13:06 +0000</pubDate>
			<dc:creator>Matt Banks</dc:creator>
			<guid isPermaLink="false">102204@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Also getting the following JS errors when remove_menu_page is on:&#60;/p&#62;
&#60;p&#62;&#60;code&#62;Uncaught SyntaxError: Unexpected token &#38;lt;&#60;/code&#62;&#60;br /&#62;
in admin.php:3232&#60;/p&#62;
&#60;p&#62;&#60;code&#62;Uncaught SyntaxError: Unexpected token &#38;lt;&#60;/code&#62;&#60;br /&#62;
in admin.php:1&#60;/p&#62;
&#60;p&#62;&#60;code&#62;Uncaught SyntaxError: Unexpected token &#38;lt;&#60;/code&#62;&#60;br /&#62;
in tw-sack.min.js:1&#60;/p&#62;
&#60;p&#62;Also, with the code inactive for remove_menu_page, I'm getting the first JS error whenever I edit a form anyway, so something is causing a JS error regardless.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Matt Banks on "remove_menu_page breaks form edit interface"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/remove_menu_page-breaks-form-edit-interface#post-102190</link>
			<pubDate>Thu, 13 Dec 2012 11:41:45 +0000</pubDate>
			<dc:creator>Matt Banks</dc:creator>
			<guid isPermaLink="false">102190@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;David - sure I can send the theme. It's still in development and I'm doing it locally on my Mac for a client, so if I can get it to you privately since it's client work, that would be great.&#60;/p&#62;
&#60;p&#62;It's based on my starter theme that I have on Github - &#60;a href=&#34;https://github.com/mattbanks/WordPress-Starter-Theme&#34; rel=&#34;nofollow&#34;&#62;https://github.com/mattbanks/WordPress-Starter-Theme&#60;/a&#62;
&#60;/p&#62;</description>
		</item>
		<item>
			<title>David Peralty on "remove_menu_page breaks form edit interface"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/remove_menu_page-breaks-form-edit-interface#post-102175</link>
			<pubDate>Thu, 13 Dec 2012 11:11:49 +0000</pubDate>
			<dc:creator>David Peralty</dc:creator>
			<guid isPermaLink="false">102175@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Very strange, I'll pass it on to our developers. Is there any way you would be willing to give us a copy of the theme - even better if its functions.php still had that code so we can see it not working to troubleshoot?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Matt Banks on "remove_menu_page breaks form edit interface"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/remove_menu_page-breaks-form-edit-interface#post-102149</link>
			<pubDate>Thu, 13 Dec 2012 10:41:48 +0000</pubDate>
			<dc:creator>Matt Banks</dc:creator>
			<guid isPermaLink="false">102149@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Completely custom theme on WordPress 3.5, all JS is loaded with !is_admin() in the enqueue, so it's only loading on the front end. I tried taking out all theme JS and CSS, but it was still preventing me from editing the form. The only thing that fixed it was taking away the call to remove_menu_page(). Here's the call I'm using in functions.php:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;// Hide Admin Areas that are not used
add_action( &#38;#39;admin_init&#38;#39;, &#38;#39;my_remove_menu_pages&#38;#39; );
function my_remove_menu_pages() {
	remove_menu_page(&#38;#39;edit.php&#38;#39;);
	remove_menu_page(&#38;#39;edit-comments.php&#38;#39;);
}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;This was the only thing in the theme that made it stop working, so I turned it off for now, but need to get it turned back on if possible.
&#60;/p&#62;</description>
		</item>
		<item>
			<title>David Peralty on "remove_menu_page breaks form edit interface"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/remove_menu_page-breaks-form-edit-interface#post-102145</link>
			<pubDate>Thu, 13 Dec 2012 10:36:04 +0000</pubDate>
			<dc:creator>David Peralty</dc:creator>
			<guid isPermaLink="false">102145@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Can you give us more details, or maybe provide us with the steps to recreate the issue? What version of WordPress are you using? Is it a completely custom theme? Does your theme add any JS to the WP Admin?
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Matt Banks on "remove_menu_page breaks form edit interface"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/remove_menu_page-breaks-form-edit-interface#post-102142</link>
			<pubDate>Thu, 13 Dec 2012 10:32:27 +0000</pubDate>
			<dc:creator>Matt Banks</dc:creator>
			<guid isPermaLink="false">102142@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I can duplicate this issue as I just ran into it myself with v1.6.10.1. Form editing works fine in Twenty Twelve and with/without all plugins active, so I switched back to my custom theme and started deleting functions until I found the culprit, and it looks like remove_menu_page() is the one that did it. I'm hiding Posts and Comments for this client since they aren't using them, but I think I'm going to have to leave them in now since it's not allowing form editing.&#60;/p&#62;
&#60;p&#62;Any idea what might be causing this?&#60;/p&#62;
&#60;p&#62;Thanks,&#60;br /&#62;
Matt
&#60;/p&#62;</description>
		</item>
		<item>
			<title>David Smith on "remove_menu_page breaks form edit interface"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/remove_menu_page-breaks-form-edit-interface#post-77182</link>
			<pubDate>Mon, 24 Sep 2012 16:27:49 +0000</pubDate>
			<dc:creator>David Smith</dc:creator>
			<guid isPermaLink="false">77182@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;Hi Stylmark,&#60;/p&#62;
&#60;p&#62;Using the latest version of Gravity Forms and WordPress running TwentyTen, I added this code to my functions.php file and was unable to recreate this issue.&#60;/p&#62;
&#60;p&#62;&#60;a href=&#34;http://pastie.org/4793301&#34; rel=&#34;nofollow&#34;&#62;http://pastie.org/4793301&#60;/a&#62;&#60;/p&#62;
&#60;p&#62;Can you do the theme and plugin test and confirm there is not issue there?&#60;/p&#62;
&#60;p&#62;&#60;a href=&#34;http://www.gravityhelp.com/documentation/page/Testing_for_a_Theme/Plugin_Conflict&#34; rel=&#34;nofollow&#34;&#62;http://www.gravityhelp.com/documentation/page/Testing_for_a_Theme/Plugin_Conflict&#60;/a&#62;
&#60;/p&#62;</description>
		</item>
		<item>
			<title>Stylmark on "remove_menu_page breaks form edit interface"</title>
			<link>https://legacy.forums.gravityhelp.com/topic/remove_menu_page-breaks-form-edit-interface#post-76913</link>
			<pubDate>Sat, 22 Sep 2012 21:15:33 +0000</pubDate>
			<dc:creator>Stylmark</dc:creator>
			<guid isPermaLink="false">76913@https://legacy.forums.gravityhelp.com/</guid>
			<description>&#60;p&#62;I've found that adding this to the admin_init hook will break the Gravity Forms edit form interface:&#60;/p&#62;
&#60;pre&#62;&#60;code&#62;function my_func_clear_admin() {
remove_menu_page(&#38;#39;edit-comments.php&#38;#39;);
remove_menu_page(&#38;#39;link-manager.php&#38;#39;);
}&#60;/code&#62;&#60;/pre&#62;
&#60;p&#62;regardless of the function name, having any kind of remove_menu_page function call will cause the edit form screen to throw a javascript error:&#60;/p&#62;
&#60;p&#62;Uncaught SyntaxError: Unexpected identifier  in tw-sack.js line 1&#60;/p&#62;
&#60;p&#62;Are there any solutions to this?
&#60;/p&#62;</description>
		</item>

	</channel>
</rss>
