2017-09-11 4 views
0

내 트위터 공유 버튼이 실제로 이미지, 제목 및 설명을 보여주는 트윗과 같이 작동하도록하고 싶습니다. 나는 트위터 카드를 주었지만 제대로 작동하지 않고 그 이유를 알지 못한다. 내 G +가 완벽하게 작동하며 Twitter 및 Facebook 공유에 문제가 있습니다.트위터 공유 링크가 작동하지 않습니다.

<a class="fa fa-twitter" href="https://twitter.com/intent/tweet?status=<?php echo base_url(); ?>index.php/Testimonials/fb_share/<?php echo $row->client_id; ?>" target="_blank"><i class="icomoon-icon-twitter"></i><span class="share-title"></span></a> 

이하 나는 또한 상태 대신에 URL로 시도하지만 여전히 운이

<a class="fa fa-twitter" href="https://twitter.com/intent/tweet?url=<?php echo base_url(); ?>index.php/Testimonials/fb_share/<?php echo $row->client_id; ?>" target="_blank"><i class="icomoon-icon-twitter"></i><span class="share-title"></span></a> 

내 트위터 카드는

<!-- Twitter Card data --> 
<meta name="twitter:card" content="summary"> 
<meta name="twitter:site" content="http://quanutrition.com/Dotcom/new/"> 
<meta name="twitter:title" content="<?php echo $res['name'];?>"> 
<meta name="twitter:description" content="<?php echo $res['content1'];?>"> 
<meta name="twitter:creator" content="@author_handle"> 
<meta name="twitter:image" content="http://quanutrition.com/Dotcom/new//admin/assets/uploads/clients_image/<?php echo $res['image'];?>"> 
<!-- Twitter summary card with large image must be at least 280x150px --> 
<meta name="twitter:image:src" content="http://quanutrition.com/Dotcom/new//admin/assets/uploads/clients_image/<?php echo $res['image'];?>"> 
아래 없습니다

트위터 공유에 대한 내 앵커 태그입니다

$ res 변수는 특정 client_id에 대해 이와 유사합니다.

어레이 ([CLIENT_ID] => 1 [이름] => 쉬 하르 다완 [이미지] => shikhar-dhawan-759.jpg [동영상] => [콘텐츠 1] => "영양 재생 키 역할 내 회복과 수행 능력. 스포츠 유전자 검사를 사용하면 영양 생화학 생화학이 향상됩니다. 더 과학 얻고 이런 식으로 결과 지향적 계획을 먹는. "이제

내가 트위터 카드가 작동하지 않는 이유를 이해하고 있지 않다. 나는 똑같은 방식으로 G +를하고 완벽하게 일했다. 누군가가 제안 할 수 있습니다 ?

답변

0

첫째, 당신이 당신의 메타 태그는 URL에 대한 최종 정적 출력에서 ​​사용할 수 있는지 확인해야합니다 당신 공유하고 있습니다.

exa가 하나 인 경우 이 content 값의 양쪽에 큰 따옴표를 가지고 있기 때문에

<meta name="twitter:card" content="summary_large_image"> <meta name="twitter:site" content="http://quanutrition.com/Dotcom/new/"> <meta name="twitter:title" content="S. Danush"> <meta name="twitter:description" content=""Qua Nutrition has helped me grow physically, sports-wise in a healthy manner and explore my strength through right nutrition. I thank my vibrant coach Mr.Veerabadran, who showed me the way to Qua Nutrition and thank my Nutritionist Suhasini for her dedicated support and guidance in helping me achieve my dream. The systematic approach of dietitians and minuscule study of body elements are the strengths of QUA. Wish that every athlete gets an opportunity to visit Qua Nutrition and get the best out of them!" "> <meta name="twitter:creator" content="@author_handle"> <!-- Twitter summary card with large image must be at least 280x150px --> <meta name="twitter:image:src" content="http://quanutrition.com/Dotcom/new//admin/assets/uploads/clients_image/DanushS.jpg">

twitter:description 태그 분류됩니다 mple의 증명서 페이지 http://quanutrition.com/Dotcom/new/index.php/Testimonials/fb_share/4 나는이 참조하십시오.

twitter:creator 태그는 일반 태그입니다.

twitter:image:src 태그 이름은 twitter:image이어야합니다. 이것은 카드 documentation에 있습니다.

Twitter Card Validator 결과에 당신의 연결을 테스트 : ERROR: Failed to fetch page due to: DnsResolutionRequestTimeout

이것은 가능성이 있기 때문에 두 호스트 트위터의 IP 주소를 차단하거나 도메인에 대한 느린 DNS 해상도 (5+ 초)이있다.

Twitter's developer forumsdocumentation site에 대한 문제 해결 도움말이 있습니다.

+0

DNS 문제를 해결하는 방법을 제안 해주십시오. Shuld 내가 트위터의 IP 주소를 허용하고 있습니까? 그렇다면 트위터의 IP 주소를 어떻게 얻을 수 있습니까? –

+0

문제 해결 설명서에 나와 있습니다. IP 범위는 https://dev.twitter.com/cards/troubleshooting ("IP 범위"로 검색)에 명확하게 설명되어 있습니다. Twitter의 설명서 범위를 벗어나는 DNS 문제가있는 경우 –

0

앵커 태그에, "URL"로 "상태"를 교환하십시오이 문제를 해결하는 방법. 모든

+0

나는 이미 변경하려고 시도했다. 그것은 여전히 ​​같은 결과를 보여줍니다. 공유되지만 트위터 카드가로드되지 않습니다. 따라서 내 트윗에서는 이미지, 제목 또는 설명이없는 URL 만 볼 수 있습니다. –

+0

최근 편집을 참조하십시오.나는 당신이 말했듯이 그것을 시도했지만 운이 없다. –

+0

@SayantanMitra, 나에게 최종 URL을 제공해 줄 수 있습니까? –

관련 문제