{"id":1003,"date":"2020-02-26T23:17:36","date_gmt":"2020-02-26T23:17:36","guid":{"rendered":"https:\/\/wpgeodirectory.com\/docs-v2\/design\/gd_post_content\/"},"modified":"2020-03-17T12:59:41","modified_gmt":"2020-03-17T12:59:41","slug":"gd_post_content","status":"publish","type":"docs","link":"https:\/\/wpgeodirectory.com\/docs-v2\/design\/gd_post_content\/","title":{"rendered":"GD > Post Content"},"content":{"rendered":"<p>GD > Post Content is used to show an excerpt from a textarea custom field in an Archive Item template.<\/p>\n<p>Here&#8217;s an overview of when not to use GD Post Content<\/p>\n<p><strong>Details Template<\/strong><\/p>\n<p>GD Post Content is meant to show only an excerpt, so it should not be used on the GD Details template.<\/p>\n<p>GD Post Meta should be used to show a textarea custom field on the GD Details template. <\/p>\n<h3><a href=\"#options\" name=\"options\">Options<\/a><\/h3>\n<h4>Basic Options<\/h4>\n<p>The basic settings for GD Post Content include a place where you can write the title.<\/p>\n<p>Also shown is a red arrow pointing to the button that will reveal the advanced settings.<\/p>\n<p>Additional Settings<\/p>\n<p><strong>key<\/strong> (*required*)<\/p>\n<p>Choose the key of the custom field you want to show. The default is the &#8216;post_content&#8217; field, which is labeled as the description field in a listing.<\/p>\n<p><strong>show<\/strong><\/p>\n<p>Choose from different options for how the field value will be displayed. <\/p>\n<p>If you just want to display the value (text) of the field without bolding or italics, leave this set to the default.<\/p>\n<p><strong>limit<\/strong><\/p>\n<p>Choose how many words you want to show. This setting can be used with or without the height option. Use this if you don&#8217;t want to use the height option, which comes with a transparent overlay on the bottom of the text content.<\/p>\n<p><a href=\"http:\/\/wpgeodirectory.com\/docs-v2\/wp-content\/uploads\/sites\/23\/2020\/02\/gdpcb.jpg\"><img src=\"http:\/\/wpgeodirectory.com\/docs-v2\/wp-content\/uploads\/sites\/23\/2020\/02\/gdpcb.jpg\" alt=\"\" width=\"450\" class=\"alignnone size-full wp-image-1006\" srcset=\"https:\/\/wpgeodirectory.com\/docs-v2\/wp-content\/uploads\/sites\/23\/2020\/02\/gdpcb.jpg 489w, https:\/\/wpgeodirectory.com\/docs-v2\/wp-content\/uploads\/sites\/23\/2020\/02\/gdpcb-273x300.jpg 273w\" sizes=\"(max-width: 489px) 100vw, 489px\" \/><\/a><\/p>\n<h4>Advanced Options<\/h4>\n<p><strong>max_height<\/strong><\/p>\n<p>Set a max height for the area of the custom field text value. This will also add a transparent overlay to hude the bottom of the text and add the read more link.<\/p>\n<p><strong>read_more<\/strong><\/p>\n<p>Set the read more text you want to use.<\/p>\n<p><a href=\"http:\/\/wpgeodirectory.com\/docs-v2\/wp-content\/uploads\/sites\/23\/2020\/02\/gdpc.jpg\"><img src=\"http:\/\/wpgeodirectory.com\/docs-v2\/wp-content\/uploads\/sites\/23\/2020\/02\/gdpc.jpg\" alt=\"\" width=\"600\" class=\"alignnone size-full wp-image-1005\" srcset=\"https:\/\/wpgeodirectory.com\/docs-v2\/wp-content\/uploads\/sites\/23\/2020\/02\/gdpc.jpg 775w, https:\/\/wpgeodirectory.com\/docs-v2\/wp-content\/uploads\/sites\/23\/2020\/02\/gdpc-281x300.jpg 281w, https:\/\/wpgeodirectory.com\/docs-v2\/wp-content\/uploads\/sites\/23\/2020\/02\/gdpc-768x820.jpg 768w\" sizes=\"(max-width: 775px) 100vw, 775px\" \/><\/a><\/p>\n<h3><a href=\"#archive-item\" name=\"archive-item\">GD Archive Item Template<\/a><\/h3>\n<p>The GD Archive item template is the most common place to use GD Post Content. <\/p>\n<p>Read more about the GD Archive Item template here: <a href=\"https:\/\/wpgeodirectory.com\/docs-v2\/templates\/archive-item\/\" rel=\"noopener noreferrer\" target=\"_blank\">https:\/\/wpgeodirectory.com\/docs-v2\/templates\/archive-item\/<\/a><\/p>\n<p>To change the &#8220;Read more&#8221; text or remove the transparency you will want to remove the current GD Post Content shortcode and add a new one.<\/p>\n<p>For the new GD Post Content, try something like this:<\/p>\n<pre><code class='html'>\r\n[gd_post_content key=\"post_content\" limit=\"15&#8243; read_more=\"See More\" alignment=\"left\"]\r\n<\/code><\/pre>\n<h3><a href=\"#customizing\" name=\"customizing\">Cutomizing<\/a><\/h3>\n<p>Read more about customizing GD with CSS and PHP snippets<br \/>\n<a href=\"https:\/\/wpgeodirectory.com\/docs-v2\/faq\/customizing\/\" rel=\"noopener noreferrer\" target=\"_blank\">https:\/\/wpgeodirectory.com\/docs-v2\/faq\/customizing\/<\/a><\/p>\n<p><strong>Read more link<\/strong><\/p>\n<p>To put the read more link on a new link and align-right,  try this CSS:<\/p>\n<pre><code class='css'>\r\na.gd-read-more {\r\n    display: block;\r\n    text-align: right;\r\n}\r\n<\/code><\/pre>\n<p><strong>Hide GD Post Content in a specific place<\/strong><\/p>\n<p>This CSS will the post content element in the Supreme Directory Sidebar.<\/p>\n<pre><code class='css'>\r\n.sd-sidebar.sd-sidebar-right .geodir-post-content-container {\r\n    display: none;\r\n}\r\n<\/code><\/pre>\n","protected":false},"featured_media":0,"parent":806,"menu_order":9,"comment_status":"open","ping_status":"closed","template":"","doc_tag":[],"amp_validity":null,"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/wpgeodirectory.com\/docs-v2\/wp-json\/wp\/v2\/docs\/1003"}],"collection":[{"href":"https:\/\/wpgeodirectory.com\/docs-v2\/wp-json\/wp\/v2\/docs"}],"about":[{"href":"https:\/\/wpgeodirectory.com\/docs-v2\/wp-json\/wp\/v2\/types\/docs"}],"replies":[{"embeddable":true,"href":"https:\/\/wpgeodirectory.com\/docs-v2\/wp-json\/wp\/v2\/comments?post=1003"}],"version-history":[{"count":0,"href":"https:\/\/wpgeodirectory.com\/docs-v2\/wp-json\/wp\/v2\/docs\/1003\/revisions"}],"up":[{"embeddable":true,"href":"https:\/\/wpgeodirectory.com\/docs-v2\/wp-json\/wp\/v2\/docs\/806"}],"next":[{"title":"GD > Dynamic Content","link":"https:\/\/wpgeodirectory.com\/docs-v2\/design\/gd_dynamic_content\/","href":"https:\/\/wpgeodirectory.com\/docs-v2\/wp-json\/wp\/v2\/docs\/1008"}],"prev":[{"title":"List and Grid Layouts","link":"https:\/\/wpgeodirectory.com\/docs-v2\/design\/layouts\/","href":"https:\/\/wpgeodirectory.com\/docs-v2\/wp-json\/wp\/v2\/docs\/821"}],"wp:attachment":[{"href":"https:\/\/wpgeodirectory.com\/docs-v2\/wp-json\/wp\/v2\/media?parent=1003"}],"wp:term":[{"taxonomy":"doc_tag","embeddable":true,"href":"https:\/\/wpgeodirectory.com\/docs-v2\/wp-json\/wp\/v2\/doc_tag?post=1003"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}