initbiz / seostorm-plugin

SEO Storm - ultimate SEO tool for OctoberCMS
MIT License
26 stars 14 forks source link

Problem with OG image, Blog meta title translation and sitemap #58

Closed bojko91 closed 1 year ago

bojko91 commented 1 year ago

Hello, When try to add an OG image that I select from Media it's retrieve in source this

<meta property="og:image" content="/OG_images/inBG_head.png" /> , but it doesn't work . How can I change to full url ? (in other page set og image that previously uploaded with this twig {{ 'assets/images/about/rabotodateli.png'|theme }} and works like charm.

bojko91 commented 1 year ago

Hi, I don't know is this the best way, but add in social.htm

{% if __SELF__.getOgImage() %}
<meta property="og:image" content="/storage/app/media{{ include(template_from_string(__SELF__.getOgImage())) }}" />
{% endif %}

Found several other problems: 1st. In Blog option when I translate Title and description doesn't affect anything. When change Language is still in main one. The twig that I use is {{ post.seo_options.meta_title }}

2nd. I have 2 languages but in sitemap doesnt appear right url . https://babconsult.bg/job/cloud-architect-with-java it's need to be like canonical one https://babconsult.bg/bg/job/cloud-architect-with-java

dzapek commented 1 year ago

Hi bojko91, if you need full url, can add twig filter media example {{ post.seo_options.og_image }}.

  1. You can do it, for example {{ post.getTranslateAttributes(activeLocale).seo_options.meta_title }}
  2. Unfortunately, we are still working on this functionality, you can have a look here
bojko91 commented 1 year ago

@dzapek thanks a lot!!!! Save my day!