Go Back   vb.org Archive > vBulletin 4 Discussion > vB4 Programming Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 02-28-2014, 10:32 PM
MacroPhotoPro MacroPhotoPro is offline
 
Join Date: Feb 2012
Posts: 122
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Facebook Share - Embed Custom Pic

Hello all,

I am creating a photography database application, so sharing pictures is an absolute must. When a person is on the "view pic" page, a facebook link is there as well so that the person can share the pic on facebook.

I am able to post to the person's wall, but I cannot figure out how to include the picture in the Facebook popup for posting. It's driving me nuts.

Before I make the dynamic solution to this problem, my goal is to first establish a static proof-of-concept. Here is the html I am using in the root directory. Notice I am intending on using the Facebook OpenGraph tool to a linked picture:

It is as if all the custom "meta" tags are being completely ignored.

How can I include a custom pic in my Facebook Shares? Your help is greatly appreciated.

Code:
<html>
<head>
	<meta property='fb:app_id' content='473597412755690' />
	<meta property='og:site_name' content='Nature Photography Resource & Database' />
	<meta property='og:description' content='Online community for dedicated macro photographers worldwide.' />
	<meta property='og:url' content='http://www.macrophotopro.com' />
	<meta property='og:type' content='website' />
	<meta property='og:image' content='http://www.macrophotopro.com/thumbnails/1/1_thumb_0000000548_tiny.jpg'>
</head>
	
<body>
	<div id='fb-root'></div>
	<script>(function(d, s, id) {
  		var js, fjs = d.getElementsByTagName(s)[0];
  		if (d.getElementById(id)) return;
  		js = d.createElement(s); js.id = id;
  		js.src = '//connect.facebook.net/en_US/all.js#xfbml=1&appId=473597412755690';
  		fjs.parentNode.insertBefore(js, fjs);
	}
	(document, 'script', 'facebook-jssdk'));
	</script>
	
	
	<div class='fb-share-button' data-href='http://www.macrophotopro.com/' data-type='button_count'>
	</div>
</body>
</html>
A pic of what happens when I click the Facebook button is shown in the attached Pic (notice that other metatags are also being completely ignored.)

This is the picture that SHOULD be appearing on the Share:



However, the attached below (my forum logo) is what's actually getting displayed. What do I have to do to get the desired pic to override the default posting of the logo?

Help is greatly appreciated!
Attached Images
File Type: gif Facebook_Fail.gif (49.5 KB, 0 views)
Reply With Quote
  #2  
Old 03-03-2014, 04:30 PM
MacroPhotoPro MacroPhotoPro is offline
 
Join Date: Feb 2012
Posts: 122
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Anyone?
Reply With Quote
Reply


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


All times are GMT. The time now is 03:45 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.03458 seconds
  • Memory Usage 2,188KB
  • Queries Executed 14 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)bbcode_code
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (2)post_thanks_box
  • (2)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (2)post_thanks_postbit_info
  • (2)postbit
  • (1)postbit_attachment
  • (2)postbit_onlinestatus
  • (2)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete