{"id":2924,"date":"2026-10-20T08:39:20","date_gmt":"2026-10-20T07:39:20","guid":{"rendered":"https:\/\/wpgeodirectory.com\/documentation\/article\/change-logo-image-size-2\/"},"modified":"2026-10-20T08:39:20","modified_gmt":"2026-10-20T07:39:20","slug":"change-logo-image-size-2","status":"publish","type":"gd_place","link":"https:\/\/wpgeodirectory.com\/documentation\/article\/how-tos\/change-logo-image-size-2\/","title":{"rendered":"How to change the logo image size on listings"},"content":{"rendered":"\n<p class=\"wp-block-paragraph\">The size of a listing logo depends on which block shows it. <a href=\"https:\/\/wpgeodirectory.com\/documentation\/article\/core-widgets\/gd-post-images\/\">GD &gt; Post Images<\/a> lets you choose the image size, the link and the aspect ratio. <a href=\"https:\/\/wpgeodirectory.com\/documentation\/article\/core-widgets\/gd-post-meta\/\">GD &gt; Post Meta<\/a>, which shows most custom fields, outputs image files at the WordPress medium size and links them to a lightbox.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Show the logo with GD &gt; Post Images<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">Set Image types to <code>logo<\/code> so the block shows only the logo, then set the size and link:<\/p>\n\n\n\n<pre class=\"wp-block-prismatic-blocks\"><code class=\"language-markup\">&#091;gd_post_images type=&#039;image&#039; types=&#039;logo&#039; fallback_types=&#039;0&#039; image_size=&#039;full&#039; link_to=&#039;&#039; aspect=&#039;n&#039;&#093;<\/code><\/pre>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Image size: any image size registered on your site, such as thumbnail, medium, large or full.<\/li>\n\n\n\n<li>Link to: None, Post or Lightbox image. Leave it empty for no link.<\/li>\n\n\n\n<li>Aspect ratio: &#8220;No ratio (natural)&#8221; keeps the logo&#8217;s own proportions.<\/li>\n\n\n\n<li>Fallback types: <code>0<\/code> stops the block showing a default image when a listing has no logo.<\/li>\n<\/ul>\n\n\n\n<p class=\"wp-block-paragraph\">You can use this in the Details page template, the archive item template or any other GeoDirectory page. <a href=\"https:\/\/wpgeodirectory.com\/documentation\/article\/how-tos\/how-to-resize-gd-post-images\/\">How to resize GD Post Images<\/a> covers sizes in more detail.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Keep GD &gt; Post Meta and change the size<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">If you show the logo with GD &gt; Post Meta, for example to keep its icon and label, change the size with the <code>geodir_cf_file_output_image_params<\/code> filter. This snippet uses the full size image for logos only:<\/p>\n\n\n\n<pre class=\"wp-block-prismatic-blocks\"><code class=\"language-php\">add_filter( &#039;geodir_cf_file_output_image_params&#039;, &#039;my_gd_logo_image_size&#039;, 10, 2 );\nfunction my_gd_logo_image_size( $params, $file ) {\n\tif ( ! empty( $file-&gt;type ) &amp;&amp; &#039;logo&#039; === $file-&gt;type ) {\n\t\t$params&#091;&#039;size&#039;&#093; = &#039;full&#039;;\n\t}\n\n\treturn $params;\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Add it with the <a href=\"https:\/\/wpgeodirectory.com\/documentation\/article\/useful-plugins\/code-snippets-plugin\/\">Code Snippets plugin<\/a> or your child theme&#8217;s functions.php. GD &gt; Post Meta always links image files to the lightbox, so if you don&#8217;t want the link, use GD &gt; Post Images instead.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Older uploads<\/h2>\n\n\n\n<p class=\"wp-block-paragraph\">WordPress creates each image size when the file is uploaded. If you add a new size, existing logos only get it after their thumbnails are regenerated, which you can do with Regenerate Thumbnails in GeoDirectory &gt; Status &gt; Tools.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>The size of a listing logo depends on which block shows it. GD &gt; Post Images lets you choose the image size, the link and the aspect ratio. GD &gt; Post Meta, which shows most custom fields, outputs image files at the WordPress medium size and links them to a lightbox. Show the logo with [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"","ping_status":"closed","template":"","meta":{"footnotes":""},"article\/tags":[],"article\/categories":[211,432],"class_list":["post-2924","gd_place","type-gd_place","status-publish","hentry","gd_placecategory-tips-tricks-more","gd_placecategory-how-tos"],"_links":{"self":[{"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article\/2924","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article"}],"about":[{"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/types\/gd_place"}],"author":[{"embeddable":true,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/comments?post=2924"}],"version-history":[{"count":0,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article\/2924\/revisions"}],"wp:attachment":[{"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/media?parent=2924"}],"wp:term":[{"taxonomy":"gd_place_tags","embeddable":true,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article\/tags?post=2924"},{"taxonomy":"gd_placecategory","embeddable":true,"href":"https:\/\/wpgeodirectory.com\/documentation\/wp-json\/wp\/v2\/article\/categories?post=2924"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}