{"id":931,"date":"2013-05-09T09:50:05","date_gmt":"2013-05-09T09:50:05","guid":{"rendered":"https:\/\/www.frozenlogistic.com\/?p=931"},"modified":"2014-07-04T07:42:32","modified_gmt":"2014-07-04T07:42:32","slug":"child-themes","status":"publish","type":"post","link":"https:\/\/www.frozenlogistic.com\/?p=931","title":{"rendered":"Child Themes"},"content":{"rendered":"<p>Since version 1.6 you can fully use the Child Themes feature.<\/p>\n<p>The implementation of the Child Themes support is strictly connected with two functions:<\/p>\n<ul>\n<li>gavern_file_uri &#8211; returns the URI to the specific file relative to the root of the theme directory<\/li>\n<li>gavern_file_path &#8211; returns the absolute path to the specifi file relative to the root of the theme directory<\/li>\n<\/ul>\n<p>Both functions accepts the <em>false<\/em> as an argument &#8211; then these functions returns the URI\/path to the specific theme directory.<\/p>\n<p><strong>IMPORTANT!<\/strong> Please remember to don&#8217;t use the slash at the start of the path to file.<\/p>\n<p>In example:[code style=\u00bb1&#8243;]gavern_file_uri(&#8216;images\/abc.png&#8217;);[\/code]<\/p>\n<p>will return: <em><a href=\"http:\/\/yourdomain.com\/wp-content\/themes\/MeetGavernWP\/images\/abc.png\">http:\/\/yourdomain.com\/wp-content\/themes\/MeetGavernWP\/images\/abc.png<\/a><\/em><\/p>\n<p>and using the <em>false<\/em> argument:[code style=\u00bb1&#8243;]gavern_file_uri(false);[\/code]<\/p>\n<p>will return: <em><a href=\"http:\/\/yourdomain.com\/wp-content\/themes\/MeetGavernWP\/\">http:\/\/yourdomain.com\/wp-content\/themes\/MeetGavernWP\/<\/a><\/em><\/p>\n<p>So now you can override every file in your Child Theme. Please remember about some specific dependicies.<\/p>\n<p>I.e. you can copy the <em>template.css<\/em> file and change it, but then you will have to also import to your Child Theme the images directory, because the theme will use the CSS from the Child Theme&#8217;s directory so the CSS file will link to the <em>images<\/em> directory in the Child Theme&#8217;s directory.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Since version 1.6 you can fully use the Child Themes feature. The implementation of the Child Themes support is strictly connected with two functions: gavern_file_uri &#8211; returns the URI to &#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[18],"tags":[],"class_list":["post-931","post","type-post","status-publish","format-standard","hentry","category-theme-features"],"_links":{"self":[{"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=\/wp\/v2\/posts\/931","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=931"}],"version-history":[{"count":2,"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=\/wp\/v2\/posts\/931\/revisions"}],"predecessor-version":[{"id":1037,"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=\/wp\/v2\/posts\/931\/revisions\/1037"}],"wp:attachment":[{"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=931"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=931"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.frozenlogistic.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=931"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}