How to remove City, Region, Country, Zip Code from Adress in Archive Page.
This topic contains 18 replies, has 4 voices, and was last updated by Alex Rollin 5 years, 9 months ago.
We have moved to a support ticketing system and our forums are now closed.
Open Support Ticket-
AuthorPosts
-
July 16, 2019 at 10:00 pm #498102
Hello,
I have two CPTs with the same settings for the Adress field.
CPT Habitatge i Allotjament Archive Page shows City, Region, Country and Zip Code in the Adress (screenshot attached).
CPT Menjar i Beure Archive Page does not show City, Region, Country and Zip Code in the Adress (screenshot attached).
I would like to remove City, Region, Country, Zip Code from Adress in CPT Habitatge i Allotjament Archive Page.
I can not remember how I did it with CPT Menjar i Beure, most probably with GD V1.
Can you help?
I look forward to your reply.
Thank you very much for your help.
Best regards.
July 17, 2019 at 6:27 am #498121Hi there,
Thanks for your post. Could you try editing your “Archive Item Template” and try removing the address from the listings? https://wpgeodirectory.com/docs-v2/templates/archive-item/
July 17, 2019 at 2:33 pm #498184Hi Kor,
Thank you very much for your reply.
I tried editing the “Archive Item Template”, that looks like this since I got my GD V1 site migrated to GD V2 by one of the GD Experts:
[gd_archive_item_section type=’open’ position=’left’] [gd_post_images type=’image’ ajax_load=’true’ link_to=’post’ show_logo=’true’ ] [gd_archive_item_section type=’close’ position=’left’] [gd_archive_item_section type=’open’ position=’right’] [gd_post_title tag=’h2′] [gd_post_distance][gd_archive_item_section type=’close’ position=’right’] [gd_post_meta key=”address” show=”icon-value” alignment=”left” text_alignment=”left”] [gd_author_actions author_page_only=’1′]
If I remove the adress shortcode [gd_post_meta key=”address” show=”icon-value” alignment=”left” text_alignment=”left”] from the template, the adress does not show at all.
The issue seems to be related to CPT Custom Field Adress settings that are not correctly applied.
For both CPTs I have the same settings:
– Ticked: show City and Neoghborhood.
– Unticked: show Region, Country and Zip Code.However:
– CPT “Habitatge i Allotjament” shows Region, Country and Zip Code.
– CPT “Menjar i Beure” does not show Region, Country and Zip Code.Another problem is that it seems that unticking “City” is not saved, since it appears always ticked when opening again CPT Custom Fields settings, however “City” does not show even when it is ticked. This has been tested only for CPT “Menjar i Beure”.
I look forward to your news.
Thank you very much once again for your help.
Best regards.
July 17, 2019 at 6:02 pm #498237Is it possible that you have an archive item template for each CPT?
Did you check that?
July 17, 2019 at 7:57 pm #498265Hi Paolo,
Thank you very much for your response.
Yes, I checked it, both CPT have the Default Archive Item page set.
In fact, changes made in the part show=”icon-value” of the shortcode [gd_post_meta key=”address” show=”icon-value” alignment=”left” text_alignment=”left”] of the Default Archive Item page show in both CPTs.
I look forward to your news.
Thank you very much once again for your help.
Best regards.
July 17, 2019 at 8:00 pm #498267Please provide link and credentials and we’ll have a look.
Thanks
July 17, 2019 at 8:11 pm #498269This reply has been marked as private.July 17, 2019 at 11:32 pm #498286I have updated it, please check.
July 18, 2019 at 5:23 am #498327This reply has been marked as private.July 18, 2019 at 12:18 pm #498367Check your GD Archive Item template to see changes.
Your earlier template was create before the GD Post Address element was released. We are always releasing new features and taking advantage of them means editing the templates to include new elements that work with your site, the way you want it.
July 18, 2019 at 12:39 pm #498375Hi Alex,
Thank you very much for your reply.
I am sorry, I do not understand what you mean. I have just checked now the GD Archive Item template and I do not see any change, since I see exactly the same than before:
[gd_archive_item_section type=’open’ position=’left’] [gd_post_images type=’image’ ajax_load=’true’ link_to=’post’ show_logo=’true’ ] [gd_archive_item_section type=’close’ position=’left’] [gd_archive_item_section type=’open’ position=’right’] [gd_post_title tag=’h2′] [gd_post_distance][gd_archive_item_section type=’close’ position=’right’] [gd_post_meta key=”address” show=”icon-value” alignment=”left” text_alignment=”left”] [gd_author_actions author_page_only=’1′]
I look forward to your news.
Thank you very much once again for your help.
Best regards.
July 18, 2019 at 1:10 pm #498383You can use the GD Post Address element where you like to display the address as you like.
Use the shortcode builder and adjust the template field
July 18, 2019 at 1:10 pm #498384Hi Alex,
Ok, I see now. You made the changes in the live site, not in the staging site.
Thank you very much for your help.
Best regards.
July 18, 2019 at 1:17 pm #498390Hi Alex,
However, the issue with Adress Tab settings in Detail Page persists.
For both “Habitatge i Allotjament” and “Menjar i Beure” CPTs I have the same settings:
– Ticked: show City and Neighbourhood.
– Unticked: show Region, Country and Zip Code.However, both CPTs Adress Tab in Detail Page show Adress, City and Neighbourhood, but:
– CPT “Habitatge i Allotjament” does show also Region, Country and Zip Code, while they should not show.
– CPT “Menjar i Beure” does not show Region, Country and Zip Code, which is correct.Another problem is that it seems that unticking “City” is not saved, since it appears always ticked when opening again CPT Custom Fields settings, however “City” does not show even when it is ticked. This has been tested only for CPT “Menjar i Beure”.
I look forward to your news.
Thank you very much once again for your help.
Best regards.
July 18, 2019 at 1:31 pm #498397Editing the display of the address in the SD Details area of the GD Single template is outside of support. We can provide CSS to hide features there:
To hide the address use the following CSS:
.sd .sd-address { color: #82888a; }
That will hide it on every CPT and you will need to target it further to hide it in select areas.
For displaying the address as per your requirements on the details page, you can use GD Post Address there, too. As a widget, a shortcode in the template, or in a tab.
-
AuthorPosts
We have moved to a support ticketing system and our forums are now closed.
Open Support Ticket