Facebook images

More
14 years 5 months ago #8073 by d4rkcloud
Facebook images was created by d4rkcloud
Hi guys,

i'd like to share my contents in fb, i changed the code of item.php and it's ok, but it doesn't let me share the image field.
It share images on the page, but not the image field as it should be.
Can you tell why?



Thanks!

Please Log in or Create an account to join the conversation.

More
14 years 5 months ago #8086 by micker
Replied by micker on topic Facebook images
hello can post the code and an link for example ?
Thanks

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]

Please Log in or Create an account to join the conversation.

More
14 years 5 months ago #8090 by d4rkcloud
Replied by d4rkcloud on topic Facebook images
Thanks Micker!

this is the code:
Code:
<?php /** * @version 1.5 stable $Id: default.php 85 2009-10-10 13:48:04Z vistamedia $ * @package Joomla * @subpackage FLEXIcontent * @copyright (C) 2009 Emmanuel Danan - www.vistamedia.fr * @license GNU/GPL v2 * * FLEXIcontent is a derivative work of the excellent QuickFAQ component * @copyright (C) 2008 Christoph Lukes * see www.schlu.net for more information * * FLEXIcontent is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. */ defined( '_JEXEC' ) or die( 'Restricted access' ); // first define the template name $tmpl = $this->tmpl; ?> <div id="flexicontent" class="flexicontent item<?php echo $this->item->id; ?> type<?php echo $this->item->type_id; ?>"> <!-- BOF buttons --> <p class="buttons"> <?php echo flexicontent_html::pdfbutton( $this->item, $this->params ); ?> <?php echo flexicontent_html::mailbutton( 'items', $this->params, null , $this->item->slug ); ?> <?php echo flexicontent_html::printbutton( $this->print_link, $this->params ); ?> </p> <!-- EOF buttons --> <!-- BOF page title --> <!-- EOF page title --> <!-- BOF item title --> <?php if ($this->params->get('show_title', 1)) : ?> <h2 class="contentheading flexicontent"> <?php echo $this->escape($this->item->title); ?> </h2> <?php endif; ?> <!-- EOF item title --> <!-- BOF subtitle1 block --> <?php if (isset($this->item->positions['subtitle1'])) : ?> <div class="lineinfo subtitle1"> <?php foreach ($this->item->positions['subtitle1'] as $field) : ?> <span class="element"> <?php if ($field->label) : ?> <span class="label field_<?php echo $field->name; ?>"><?php echo $field->label; ?></span> <?php endif; ?> <span class="value field_<?php echo $field->name; ?>"><?php echo $field->display; ?></span> </span> <?php endforeach; ?> </div> <?php endif; ?> <!-- EOF subtitle1 block --> <!-- BOF subtitle2 block --> <?php if (isset($this->item->positions['subtitle2'])) : ?> <div class="lineinfo subtitle2"> <?php foreach ($this->item->positions['subtitle2'] as $field) : ?> <span class="element"> <?php if ($field->label) : ?> <span class="label field_<?php echo $field->name; ?>"><?php echo $field->label; ?></span> <?php endif; ?> <span class="value field_<?php echo $field->name; ?>"><?php echo $field->display; ?></span> </span> <?php endforeach; ?> </div> <?php endif; ?> <!-- EOF subtitle2 block --> <!-- BOF subtitle3 block --> <?php if (isset($this->item->positions['subtitle3'])) : ?> <div class="lineinfo subtitle3"> <?php foreach ($this->item->positions['subtitle3'] as $field) : ?> <span class="element"> <?php if ($field->label) : ?> <span class="label field_<?php echo $field->name; ?>"><?php echo $field->label; ?></span> <?php endif; ?> <span class="value field_<?php echo $field->name; ?>"><?php echo $field->display; ?></span> </span> <?php endforeach; ?> </div> <?php endif; ?> <!-- EOF subtitle3 block --> <?php if ((isset($this->item->positions['image'])) || (isset($this->item->positions['top']))) : ?> <div class="topblock"> <!-- BOF image block --> <?php if (isset($this->item->positions['image'])) : ?> <?php foreach ($this->item->positions['image'] as $field) : ?> <div class="image field_<?php echo $field->name; ?>"> <?php echo $field->display; ?> <div class="clear"></div> </div> <?php endforeach; ?> <?php endif; ?> <!-- EOF image block --> <?php if (isset($this->item->positions['top'])) : ?> <!-- BOF top block --> <div class="infoblock <?php echo $this->params->get('top_cols', 'two'); ?>cols"> <ul> <?php foreach ($this->item->positions['top'] as $field) : ?> <li> <div> <?php if ($field->label) : ?> <div class="label field_<?php echo $field->name; ?>"><?php echo $field->label; ?></div> <?php endif; ?> <div class="value field_<?php echo $field->name; ?>"><?php echo $field->display; ?></div> </div> </li> <?php endforeach; ?> </ul> </div> <!-- EOF top block --> <?php endif; ?> </div> <?php endif; ?> <div class="clear"></div> <?php if (isset($this->item->positions['description'])) : ?> <!-- BOF description --> <div class="description"> <!-- BOF descriptionimage block --> <?php if (isset($this->item->positions['descriptionimage'])) : ?> <?php foreach ($this->item->positions['descriptionimage'] as $field) : ?> <div class="descriptionimage field_<?php echo $field->name; ?>"> <?php echo $field->display; ?> <div class="clear"></div> </div> <?php endforeach; ?> <?php endif; ?> <!-- EOF descriptionimage block --> <?php foreach ($this->item->positions['description'] as $field) : ?> <?php if ($field->label) : ?> <div class="desc-title"><?php echo $field->label; ?></div> <?php endif; ?> <div class="desc-content"><?php echo $field->display; ?></div> <?php endforeach; ?> </div> <!-- EOF description --> <?php endif; ?> <div class="clear"></div> <?php if (isset($this->item->positions['bottom'])) : ?> <!-- BOF bottom block --> <div class="infoblock <?php echo $this->params->get('bottom_cols', 'two'); ?>cols"> <ul> <?php foreach ($this->item->positions['bottom'] as $field) : ?> <li> <div> <?php if ($field->label) : ?> <div class="label field_<?php echo $field->name; ?>"><?php echo $field->label; ?></div> <?php endif; ?> <div class="value field_<?php echo $field->name; ?>"><?php echo $field->display; ?></div> </div> </li> <?php endforeach; ?> </ul> </div> <!-- EOF bottom block --> <?php endif; ?> <?php if ($this->params->get('comments')) : ?> <!-- BOF comments --> <div class="comments"> <?php if ($this->params->get('comments') == 1) : if (file_exists(JPATH_SITE.DS.'components'.DS.'com_jcomments'.DS.'jcomments.php')) : require_once(JPATH_SITE.DS.'components'.DS.'com_jcomments'.DS.'jcomments.php'); echo JComments::showComments($this->item->id, 'com_flexicontent', $this->escape($this->item->title)); endif; endif; if ($this->params->get('comments') == 2) : if (file_exists(JPATH_SITE.DS.'plugins'.DS.'content'.DS.'jom_comment_bot.php')) : require_once(JPATH_SITE.DS.'plugins'.DS.'content'.DS.'jom_comment_bot.php'); echo jomcomment($this->item->id, 'com_flexicontent'); endif; endif; ?> </div> <p> <!-- EOF comments --> <?php endif; ?> <strong>Condividi questo contenuto</strong> <div class="social" style="float:left;" margin-top: 5px;> <div class="social" style="float:left;" margin-left: 5px;> <script type="text/javascript"> tweetmeme_style = 'compact'; </script> </div> <div class="social" style="float:left;" margin-left: 55px;> <script type="text/javascript" src="http://tweetmeme.com/i/scripts/button.js"></script> </div> <div class="social" style="float:left;" margin-left: 10px;> <a name="fb_share" type="icon_link" href="http://www.facebook.com/sharer.php">Condividi<script src="http://static.ak.fbcdn.net/connect.php/js/FB.Share" type="text/javascript"></script> </div> <div class="social" style="float:left; margin-left: 10px;"> <script type="text/javascript"> (function() { var s = document.createElement('SCRIPT'), s1 = document.getElementsByTagName('SCRIPT')[0]; s.type = 'text/javascript'; s.async = true; s.src = 'http://widgets.digg.com/buttons.js'; s1.parentNode.insertBefore(s, s1); })(); </script> </div> <div class="social" style="float:left; margin-left: 10px;"> <a class="DiggThisButton DiggCompact"> </div> <div class="social" style="float:left; margin-left: 10px;"> <a href="http://technorati.com/faves?sub=addfavbtn&add=http://polpen.it"></br> </div> <div class="social" style="float:left; margin-left: 10px;"> <img alt="Add to Technorati Favorites" src="http://farm4.static.flickr.com/3048/2346636939_763f266eac_o.gif"/> </div> <div class="social" style="float:left; margin-left: 10px;"> <script src="http://www.stumbleupon.com/hostedbadge.php?s=3"></script> </div> </div> </div>

and this is the url:

www.mbapubbliservice.com/prova

user: userprova1
pass: prova2


Thanks again!!! :D

Please Log in or Create an account to join the conversation.

More
12 years 8 months ago #23942 by pabro
Replied by pabro on topic Facebook images
same problem! is there a solution?

Please Log in or Create an account to join the conversation.

More
12 years 8 months ago #23943 by ggppdk
Replied by ggppdk on topic Facebook images
As reported by another forum member the images must be inside a <p> ... </p> in order to be used by facebook
You can add this at your template, item.php, we plan to test and change default templates


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...

Please Log in or Create an account to join the conversation.

More
12 years 8 months ago #23996 by igcorreia
Replied by igcorreia on topic Facebook images
It was me who reported.

We have used the trick of changing the code from:
Code:
<div><img>
to
Code:
<div><p><img>

I think it steal does the trick.

but if you want "TALK" to facebook this is how facebook will use as default, add this to the META TAGS in the <head>:
Code:
<meta property="og:title" content="Eu quero umas férias no Algarve! Ajuda-me!" /> <meta property="og:description" content="Eu quero ganhar umas férias no Algarve, para isso preciso de ajuda." /> <meta property="og:image" content="http://fb.rochabrava.com/images/rocha_brava/ferias_algarve.jpg" /> <meta property="og:site_name" content="Concurso Semana de Férias"/> <meta property="fb:app_id" content="292475854148801" />

This are meta tags to talk to Facebook.

Hope it helps.

Please Log in or Create an account to join the conversation.

Moderators: vistamediajoomlacornerggppdk
Time to create page: 0.458 seconds
Save
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Essential
These cookies are needed to make the website work correctly. You can not disable them.
Display
Accept
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline