{"id":1015,"date":"2012-07-10T22:44:30","date_gmt":"2012-07-11T03:44:30","guid":{"rendered":"http:\/\/patrioticfederalist.com\/wp\/?p=1015"},"modified":"2012-07-10T22:44:30","modified_gmt":"2012-07-11T03:44:30","slug":"how-to-remove-hard-coded-home-tab-i-had-2-home-tabs-after-static-page-started","status":"publish","type":"post","link":"http:\/\/patrioticfederalist.com\/wp\/?p=1015","title":{"rendered":"How to Remove Hard-Coded Home Tab (I had 2 HOME tabs after static page started)"},"content":{"rendered":"<p>After creating a static page called &#8220;Home,&#8221; I ended up with 2 tabs with the same name because one is hard coded into the header.php file.\u00a0 Each theme may be slightly different, but for mine I went to APPEARANCE, then EDITOR while logged into WordPress as Admin.<\/p>\n<p>On the right side I clicked header.php and scrolled until I found some code that I could comment out then test it.\u00a0 For my theme (currently Elegant Grunge) it looked like this:<\/p>\n<p>&lt;ul&gt;<br \/>\n&lt;li&gt;&lt;a href=&#8221;&lt;?php bloginfo(&#8216;url&#8217;); ?&gt;&#8221;&gt;&lt;?php _e(&#8216;Home&#8217;, &#8216;elegant-grunge&#8217;) ?&gt;&lt;\/a&gt;&lt;\/li&gt;<br \/>\n&lt;?php wp_list_pages(&#8216;title_li=&amp;depth=1&#8217;); ?&gt;<br \/>\n&lt;\/ul&gt;<\/p>\n<p>So I remarked\u00a0 some of the code so it would not be read. This is done with <strong>&lt;!&#8211;\u00a0<\/strong>before the start of the code and\u00a0<strong>&#8211;&gt;\u00a0<\/strong>at the end. Now mine looks like this:<\/p>\n<p>&lt;ul&gt;<br \/>\n<strong>&lt;!&#8211;<\/strong>\u00a0\u00a0 \u00a0\u00a0\u00a0 \u00a0&lt;li&gt;&lt;a href=&#8221;&lt;?php bloginfo(&#8216;url&#8217;); ?&gt;&#8221;&gt;&lt;?php _e(&#8216;Home&#8217;, &#8216;elegant-grunge&#8217;) ?&gt;&lt;\/a&gt;&lt;\/li&gt;<br \/>\n<strong>&#8211;&gt;<\/strong><br \/>\n&lt;?php wp_list_pages(&#8216;title_li=&amp;depth=1&#8217;); ?&gt;<br \/>\n&lt;\/ul&gt;<\/p>\n<p>One last problem after I corrected this was my tabs were not in the order I wanted. You have to go back into PAGES and click EDIT under your page you want to be first.\u00a0 Over on the right side is an ORDER box with a number.\u00a0 This is the order you want the page to appear in the tabs, starting with zero showing first.\u00a0 I put 0 in my page I want first then 1 in the next pages ORDER box and so on.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>After creating a static page called &#8220;Home,&#8221; I ended up with 2 tabs with the same name because one is hard coded into the header.php file.\u00a0 Each theme may be slightly different, but for mine I went to APPEARANCE, then EDITOR while logged into WordPress as Admin. On the right side I clicked header.php and &#8230; <a title=\"How to Remove Hard-Coded Home Tab (I had 2 HOME tabs after static page started)\" class=\"read-more\" href=\"http:\/\/patrioticfederalist.com\/wp\/?p=1015\" aria-label=\"Read more about How to Remove Hard-Coded Home Tab (I had 2 HOME tabs after static page started)\">Read more<\/a><\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[55],"tags":[331,330,332],"class_list":["post-1015","post","type-post","status-publish","format-standard","hentry","category-wordpress","tag-2-home-tabs","tag-remove-hard-coded-home-tab","tag-remove-wordpress-home"],"_links":{"self":[{"href":"http:\/\/patrioticfederalist.com\/wp\/index.php?rest_route=\/wp\/v2\/posts\/1015","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/patrioticfederalist.com\/wp\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/patrioticfederalist.com\/wp\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/patrioticfederalist.com\/wp\/index.php?rest_route=\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"http:\/\/patrioticfederalist.com\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1015"}],"version-history":[{"count":1,"href":"http:\/\/patrioticfederalist.com\/wp\/index.php?rest_route=\/wp\/v2\/posts\/1015\/revisions"}],"predecessor-version":[{"id":1016,"href":"http:\/\/patrioticfederalist.com\/wp\/index.php?rest_route=\/wp\/v2\/posts\/1015\/revisions\/1016"}],"wp:attachment":[{"href":"http:\/\/patrioticfederalist.com\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1015"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/patrioticfederalist.com\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1015"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/patrioticfederalist.com\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1015"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}