Go Back   Mosets Community > Mosets Announcements and Discussions > Mosets & Joomla

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Old 01-30-2018, 03:24 PM
peterwalker peterwalker is offline
Mosets'd
 
Join Date: Nov 2013
Posts: 53
Default @DKnight - Set sharing meta tag with setMetaData() instead of addCustomTag()

You are using addCustomTag() to set social share meta tags and that makes it challenging to unset() duplicates such as sitename. Joomla supports the property attribute in setMetatData() and the tags within that array are easily unset by a system plugin.

In future updates, please change all the social meta settings from
PHP Code:
$document->addCustomTag'<meta property="og:site_name" content="'.JFactory::getApplication()->get('sitename').'"/>' ); 
to
PHP Code:
$document->setMetaData('og:site_name'JFactory::getApplication()->get('sitename'), 'property'); 
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Meta Robot Tag johnpreville Discussions, Troubleshooting & Problems 1 04-25-2017 11:40 AM


All times are GMT +8. The time now is 02:45 PM.

Copyright © 2005-2010 Mosets Consulting

Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.