Pereiti prie turinio

neatvaizduoja tinklapio facebooke


Rekomenduojami pranešimai

Sveiki,

 

turiu wordpress svetainę, facebook puslapį, bet yra bėda, norint įmest kokį nors svetainės postą į facebook, neatvaizduoja jo (turėtų būt nuotrauka iš posto, antraštė, dalis teksto)... Rodo tiesiog paprastą linką, ką čia reiktų pakeist?

Nuoroda į pranešimą
Dalintis kituose puslapiuose

Sveiki,

 

turiu wordpress svetainę, facebook puslapį, bet yra bėda, norint įmest kokį nors svetainės postą į facebook, neatvaizduoja jo (turėtų būt nuotrauka iš posto, antraštė, dalis teksto)... Rodo tiesiog paprastą linką, ką čia reiktų pakeist?

truksta kodo tavo svetaineje ir atvaizduos

<!-- for Facebook -->          
<meta property="og:title" content="" />
<meta property="og:type" content="article" />
<meta property="og:image" content="" />
<meta property="og:url" content="" />
<meta property="og:description" content="" />

Jei naudojat seo by yoast pluginą jis sutvarko šitą problemą

Nuoroda į pranešimą
Dalintis kituose puslapiuose

truksta kodo tavo svetaineje ir atvaizduos

<!-- for Facebook -->          
<meta property="og:title" content="" />
<meta property="og:type" content="article" />
<meta property="og:image" content="" />
<meta property="og:url" content="" />
<meta property="og:description" content="" />

Jei naudojat seo by yoast pluginą jis sutvarko šitą problemą

 

kur klijuot šitą kodą? index.php?

Nuoroda į pranešimą
Dalintis kituose puslapiuose

Kodą reikia įdėti tarp tagų

<head> 

</head>

 

Dažniausiai tai būna header.php failas temos direktorijoje.

 

arba blogai kažką padariau, arba nepadeda :/

 

needitintas header.php, ties kuria vieta reiktų klijuot? :D

 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head profile="http://gmpg.org/xfn/11">

<title><?php woo_title(); ?></title>
<?php woo_meta(); ?>

<link rel="stylesheet" type="text/css" href="<?php bloginfo('stylesheet_url'); ?>" media="screen" />
<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="<?php if ( get_option('woo_feedburner_url') <> "" ) { echo get_option('woo_feedburner_url'); } else { echo get_bloginfo_rss('rss2_url'); } ?>" />
<link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" />

<!--[if IE 6]>
<script type="text/javascript" src="<?php bloginfo('template_directory'); ?>/includes/js/pngfix.js"></script>
<script type="text/javascript" src="<?php bloginfo('template_directory'); ?>/includes/js/menu.js"></script>
<link rel="stylesheet" type="text/css" href="<?php bloginfo('template_directory'); ?>/ie6.css" media="screen" />
<![endif]-->

<?php if ( is_single() ) wp_enqueue_script( 'comment-reply' ); ?>
<?php wp_head(); ?>

<link href="http://fonts.googleapis.com/css?family=PT+Sans" rel="stylesheet" type="text/css">
<style type="text/css">
/* Google Fonts */
#single-post h1, 
#single-post h2, 
#full-post h1, 
#full-post h2, 
#photo-meta h1, 
#photo-meta h2, 
#footer-widgets h3,
h1, h2, h3, h4, h5 {
	font-family: "PT Sans", sans-serif; 
}	
</style>

</head>

<?php 
// Find the blog category ID from options panel
$GLOBALS[blog_id] = get_option('woo_blog_id');
?>

<body <?php body_class(); ?>>

<div id="wrap">

<div id="top" class="content">

   <div id="header">
       <div id="logo" class="fl">

           <?php if (get_option('woo_texttitle') <> "true") { ?><a href="<?php bloginfo('url'); ?>" title="<?php bloginfo('description'); ?>"><img class="title" src="<?php if ( get_option('woo_logo') <> "" ) { echo get_option('woo_logo'); } else { bloginfo('template_directory'); ?>/images/logo.png<?php } ?>" alt="<?php bloginfo('name'); ?>" /></a><?php } ?>

           <?php if(is_single() || is_page()) : ?>
               <span class="site-title"><a href="<?php bloginfo('url'); ?>"><?php bloginfo('name'); ?></a></span>
           <?php else: ?>
               <h1 class="site-title"><a href="<?php bloginfo('url'); ?>"><?php bloginfo('name'); ?></a></h1>
           <?php endif; ?>

       </div><!-- /#logo -->

       <!-- Top Ad / Slogan / Search -->
       <?php if (get_option('woo_ad_top') == "true") 
		include (TEMPLATEPATH . "/ads/top_ad.php"); 
	elseif ( get_option('woo_twitter') ) { ?>
       <ul id="twitter_update_list"><li></li></ul>
	<?php } elseif ( get_option('woo_search_top') == "true" ) { ?>
       <div id="search-top"><?php include(TEMPLATEPATH . '/search-form.php'); ?></div>
	<?php } else { ?>
       <p id="tagline"><?php bloginfo('description'); ?></p>
       <?php } ?>
       <div class="fix"></div>
   </div>
   <!-- Menu Starts -->
   <div id="bg-top-nav">
   <div id="top-nav" class="wrap">
	<?php
	if ( function_exists('has_nav_menu') && has_nav_menu('primary-menu') ) {
		wp_nav_menu( array( 'depth' => 3, 'sort_column' => 'menu_order', 'container' => 'ul', 'menu_class' => 'nav fl', 'theme_location' => 'primary-menu' ) );
	} else {
	?>
       <!-- Category Menu -->       
       <ul class="nav fl">
       	<?php
       	if ( get_option('woo_blog_cats') == "true" ) $depth = 3; else $depth = 1;
       	if ( get_option('woo_custom_nav_menu') == 'true' ) {
       		if ( function_exists('woo_custom_navigation_output') )
				woo_custom_navigation_output('depth=' . $depth);

		} else { ?>
           <?php if (is_page()) { $highlight = "page_item"; } else {$highlight = "page_item current_page_item"; } ?>
           <li class="<?php echo $highlight; ?>"><a href="<?php bloginfo('url'); ?>"><?php _e('Home', 'woothemes' ) ?></a></li>
           <?php wp_list_categories('sort_column=menu_order&depth='.$depth.'&title_li=&exclude='.get_option('woo_nav_exclude')); ?>                
		<?php } ?>       
       </ul>
	<?php } ?>
       <!-- RSS -->       
       <ul class="rss fr">
           <li><a href="<?php if ( get_option('woo_feedburner_url') <> "" ) { echo get_option('woo_feedburner_url'); } else { echo get_bloginfo_rss('rss2_url'); } ?>"><img src="<?php bloginfo('template_directory'); ?>/images/ico-rss.png" alt="RSS" /></a></li>
       </ul>
	<?php
	if ( function_exists('has_nav_menu') && has_nav_menu('secondary-menu') ) {
		wp_nav_menu( array( 'depth' => 3, 'sort_column' => 'menu_order', 'container' => 'ul', 'menu_class' => 'nav fr', 'theme_location' => 'secondary-menu' ) );
	} else {
	?>
       <!-- Page Menu -->       
       <ul class="nav fr">
       	<?php
       	if ( get_option('woo_custom_nav_menu') == 'true' ) {
       		if ( function_exists('woo_custom_navigation_output') )
				woo_custom_navigation_output('name=Woo Menu 2&depth=3');

		} else { ?>
           <?php wp_list_pages('sort_column=menu_order&depth=3&title_li=&exclude='.get_option('woo_nav_exclude')); ?>
           <?php } ?>
       </ul>            
	<?php } ?>
   </div>
   </div>
   <!-- Menu Ends -->

</div>
<div style="display: none;">
<a href="http://w3vina.com" title="W3vina.COM | Joomla, Wordpress, Drupal templates">W3vina.COM</a>
<a href="http://www.wpdaily.org" title="Wordpress Themes Download">Free Wordpress Themes</a>
<a href="http://www.joomladaily.org" title="Joomla Templates Download">Joomla Templates</a>
<a href="http://www.bestwpdaily.com" title="Best Wordpress Themes">Best Wordpress Themes</a>
<a href="http://www.zinthemes.com" title="Premium Wordpress Themes">Premium Wordpress Themes</a>
<a href="http://www.topthemesdeal.com" title="Top Best Wordpress Themes">Top Best Wordpress Themes 2012</a>
</div>

Nuoroda į pranešimą
Dalintis kituose puslapiuose

arba blogai kažką padariau, arba nepadeda :/

 

needitintas header.php, ties kuria vieta reiktų klijuot? :D

 

 

 

Tarkime taip

 

<head profile="http://gmpg.org/xfn/11">

<title><?php woo_title(); ?></title>
<?php woo_meta(); ?>

<link rel="stylesheet" type="text/css" href="<?php bloginfo('stylesheet_url'); ?>" media="screen" />
<link rel="alternate" type="application/rss+xml" title="RSS 2.0" href="<?php if ( get_option('woo_feedburner_url') <> "" ) { echo get_option('woo_feedburner_url'); } else { echo get_bloginfo_rss('rss2_url'); } ?>" />
<link rel="pingback" href="<?php bloginfo('pingback_url'); ?>" />

<!--[if IE 6]>
<script type="text/javascript" src="<?php bloginfo('template_directory'); ?>/includes/js/pngfix.js"></script>
<script type="text/javascript" src="<?php bloginfo('template_directory'); ?>/includes/js/menu.js"></script>
<link rel="stylesheet" type="text/css" href="<?php bloginfo('template_directory'); ?>/ie6.css" media="screen" />
<![endif]-->

<?php if ( is_single() ) wp_enqueue_script( 'comment-reply' ); ?>
<?php wp_head(); ?>

<link href="http://fonts.googleapis.com/css?family=PT+Sans" rel="stylesheet" type="text/css">
<style type="text/css">
       /* Google Fonts */
       #single-post h1, 
       #single-post h2, 
       #full-post h1, 
       #full-post h2, 
       #photo-meta h1, 
       #photo-meta h2, 
       #footer-widgets h3,
       h1, h2, h3, h4, h5 {
               font-family: "PT Sans", sans-serif; 
       }       
</style>


<!-- for Facebook -->          
<meta property="og:title" content="" />
<meta property="og:type" content="article" />
<meta property="og:image" content="" />
<meta property="og:url" content="" />
<meta property="og:description" content="" />

</head>

 

BET, šitas įterptas kodas tėra tik duomenų struktūra, kuri konkrečiam postui/puslapiui turi buti užpildyta t.y. nurodytas puslapio pavadinimas og:title, paveikslėlio url og:image, posto url og:image, aprasymas og:description. Jei juos užpildysi ranka statiškai, tuomet kad ir koki postą sharinsi fb tau visuomet rodys tokį pati įrašą. Tai kažint ar tu no norėjai. Gal geriau pasieškok pluginų kurie šiuos meta duomenis sugeneruoja automatiškai.

 

p.s. pakeitus metaduomenis neskubėk testuoti numesdamas linką tiesiai į fb, nes matysi ta patį vaizdą. Prieš tai išvalyk facebook cache per https://developers.facebook.com/tools/debug/

Nuoroda į pranešimą
Dalintis kituose puslapiuose

<div style="display: none;">
       <a href="http://w3vina.com" title="W3vina.COM | Joomla, Wordpress, Drupal templates">W3vina.COM</a>
       <a href="http://www.wpdaily.org" title="Wordpress Themes Download">Free Wordpress Themes</a>
       <a href="http://www.joomladaily.org" title="Joomla Templates Download">Joomla Templates</a>
       <a href="http://www.bestwpdaily.com" title="Best Wordpress Themes">Best Wordpress Themes</a>
       <a href="http://www.zinthemes.com" title="Premium Wordpress Themes">Premium Wordpress Themes</a>
       <a href="http://www.topthemesdeal.com" title="Top Best Wordpress Themes">Top Best Wordpress Themes 2012</a>
</div>

 

lol

Nuoroda į pranešimą
Dalintis kituose puslapiuose

Prisijunkite prie diskusijos

Jūs galite rašyti dabar, o registruotis vėliau. Jeigu turite paskyrą, prisijunkite dabar, kad rašytumėte iš savo paskyros.

Svečias
Parašykite atsakymą...

×   Įdėta kaip raiškusis tekstas.   Atkurti formatavimą

  Only 75 emoji are allowed.

×   Nuorodos turinys įdėtas automatiškai.   Rodyti kaip įprastą nuorodą

×   Jūsų anksčiau įrašytas turinys buvo atkurtas.   Išvalyti redaktorių

×   You cannot paste images directly. Upload or insert images from URL.

Įkraunama...
  • Dabar naršo   0 narių

    Nei vienas registruotas narys šiuo metu nežiūri šio puslapio.

×
×
  • Pasirinkite naujai kuriamo turinio tipą...