Hello there! Welcome to Youjoomla Support Forums

We are Web Development Company specializing in Joomla Templates , Joomla Extensions and WordPress Themes development . You are not able to see some forum threads due to your memberhip level. To unlock all forums and special customer support please take few moments to signup . If you are just searching for free joomla templates , or free joomla extension support simply head to our Free Joomla Support forums and open a new thread. Our moderators will help you as soon as possible. To spead up the response time please take few seconds and go over forum rules

Have fun!

Suggested mod to include Facebook OG properties

11-01-2013, 07:36 PM
# 1 (permalink)
adiehm
I have used YGSG as the base template for a few website now and I thought I would share a mod that I incorporate.

This mod will append all the OG parameters that Facebook requires and lets you manipulate the default facebook like image

File : yjsg_head.php
Location in the file : Right at the bottom before the php close tag "?>"
Code to insert :

$mydoc2 =& JFactory::getDocument();
$title = $mydoc2->getTitle();
$description = $mydoc2->getDescription();
$document->addCustomTag('<meta property="og:image" content="'.$yj_site.'/images/system/facebook-like.jpg" />');
$document->addCustomTag('<meta property="og:url" content="'.JURI::base().'?view=featured" />');
$document->addCustomTag('<meta property="og:title" content="'.$title.'" />');
$document->addCustomTag('<meta property="og:description" content="'.$description.'" />');


You have to add your default facebook image (facebook-like.jpg) in the following folder:
/tempales/yougrids/images/system/facebook-like.jpg.

You can test the results in the facebook developers site:
https://developers.facebook.com/tools/debug

Hope this helps someone

Are you sure your are posting in product assigned forum?: Yes

What is your CMS version?: Joomla 3.x

MySQL Version: 5.x

PHP version: 5.x

Link to installation: JTAA - Community Consultation - Stakeholder Engagement

Have you edited any files? If yes tell us which ones.: Yes

Is this personal or client website?: Client
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Powered by vBulletin®
Copyright ©2000 - 2023, Jelsoft Enterprises Ltd.

Members Login

Username
Password