Advertisement
niammuddin

meta description wordpress musica

Jul 27th, 2017
290
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 6.72 KB | None | 0 0
  1. <?php
  2. //fungsi excerpt artikel
  3. function excerpt($limit) {
  4. $excerpt = explode(' ', get_the_excerpt(), $limit);
  5. if (count($excerpt)>=$limit) {
  6. array_pop($excerpt);
  7. $excerpt = implode(" ",$excerpt).'...';
  8. } else {
  9. $excerpt = implode(" ",$excerpt);
  10. }
  11. $excerpt = preg_replace('`\[[^\]]*\]`','',$excerpt);
  12. return $excerpt;
  13. }
  14. ?>
  15. <meta name="robots" content="index, follow">
  16. <meta name="description" content="NadaLagu situs download lagu MP3 dan video 3GP MP4 gratis di Indonesia, menambah koleksi musik, video, lirik lagu dan berita tentang musik terbaru setiap hari <?php echo $paged ?>" />
  17. <meta name="keywords" content="mp3 download, download lagu, download video, k-pop, lagu barat, lagu indonesia, lagu dangdut, full album, lirik lagu, mp3 terbaru, tangga lagu, situs lagu, nada lagu, nadalagu" />
  18. <meta property="og:description" content="NadaLagu situs download lagu MP3 dan video 3GP MP4 gratis di Indonesia, menambah koleksi musik, video, lirik lagu dan berita tentang musik terbaru setiap hari" />
  19. <meta property="fb:app_id" content="218430011893932" />
  20. <meta property="og:title" content="NadaLagu - Download Lagu MP3, Video, Lirik" />
  21. <meta property="og:type" content="article" />
  22. <meta property="og:url" content="<?php echo site_url();?>" />
  23. <meta property="og:image" content="<?php echo get_template_directory_uri();?>/images/artworks_250x250.jpg" />
  24. <meta property="og:site_name" content="<?php bloginfo('name');?>" />
  25. <link rel="canonical" href="<?php echo site_url();?>" />
  26. <?php } elseif (is_single()) { ?>
  27. <meta name="robots" content="index, follow">
  28. <?php if (have_posts() ) : while (have_posts() ) : the_post(); ?>
  29. <meta name="description" content="<?php echo html_entity_decode(excerpt(25)); ?>" />
  30. <meta name="keywords" content="<?php wp_title('');?>, mp3 download, download lagu, download video, k-pop, lagu barat, lagu indonesia, lagu dangdut, full album, lirik lagu, mp3 terbaru, tangga lagu, situs lagu, nada lagu, nadalagu" />
  31. <meta property="og:description" content="<?php echo html_entity_decode(excerpt(30)); ?>" />
  32. <meta property="fb:app_id" content="218430011893932" />
  33. <meta property="og:title" content="<?php echo get_the_title();?>" />
  34. <meta property="og:type" content="article" />
  35. <meta property="og:url" content="<?php echo get_the_permalink();?>" />
  36. <!--<meta property="og:image" content="<?php echo get_template_directory_uri();?>/images/artworks_250x250.jpg" />-->
  37. <meta property="og:site_name" content="<?php bloginfo('name');?>" />
  38. <?php endwhile; endif; ?>
  39. <?php } elseif (is_page()) { ?>
  40. <meta name="robots" content="index, follow">
  41. <?php if (have_posts() ) : while (have_posts() ) : the_post(); ?>
  42. <meta name="description" content="<?php echo excerpt(25); ?>" />
  43. <?php endwhile; endif; ?>
  44. <?php } elseif (is_tag()) { ?>
  45. <meta name="robots" content="index, follow">
  46. <meta name="description" content="Kumpulan Lagu dari Artis <?php wp_title(''); ?> di NadaLagu situs download lagu MP3 dan video 3GP MP4 gratis di Indonesia <?php echo $paged ?>" />
  47. <meta name="keywords" content="<?php wp_title('');?>, mp3 download, download lagu, download video, k-pop, lagu barat, lagu indonesia, lagu dangdut, full album, lirik lagu, mp3 terbaru, tangga lagu, situs lagu, nada lagu, nadalagu" />
  48. <?php } elseif (is_category()) { ?>
  49. <meta name="robots" content="index, follow">
  50. <meta name="description" content="List Lagu dari <?php wp_title(''); ?> di NadaLagu situs download lagu MP3 dan video 3GP MP4 gratis di Indonesia <?php echo $paged ?>" />
  51. <meta name="keywords" content="<?php wp_title('');?>, mp3 download, download lagu, download video, k-pop, lagu barat, lagu indonesia, lagu dangdut, full album, lirik lagu, mp3 terbaru, tangga lagu, situs lagu, nada lagu, nadalagu" />
  52. <?php } elseif (is_search()) { ?>
  53. <?php
  54. $kw = get_search_query();
  55. $hitung = str_word_count($kw);
  56. if ($hitung <=3) {
  57. echo '<meta name="robots" content="noindex, follow">
  58. ';
  59. }
  60. else {
  61. echo '<meta name="robots" content="index, follow">
  62. ';
  63. } ?>
  64. <meta name="description" content="<?php the_search_query(); ?> MP3 Download (<?php echo $rand ?>) Video 3GP MP4 List download link Lagu MP3 <?php the_search_query(); ?> (<?php echo $rand2 ?>) last update <?php echo date('d-M-Y');?> You can streaming and download for free" />
  65. <meta name="keywords" content="<?php the_search_query(); ?>, mp3 download, download lagu, download video, k-pop, lagu barat, lagu indonesia, lagu dangdut, full album, lirik lagu, mp3 terbaru, tangga lagu, situs lagu, nada lagu, nadalagu" />
  66. <meta property="og:description" content="<?php the_search_query(); ?> MP3 Download (<?php echo $rand ?>) Video 3GP MP4 List download link Lagu MP3 <?php the_search_query(); ?> (<?php echo $rand2 ?>) last update <?php echo date('d-M-Y');?> You can streaming and download for free" />
  67. <meta property="fb:app_id" content="218430011893932" />
  68. <meta property="og:title" content="Download <?php the_search_query(); ?>  Lagu MP3, Video MP4 3GP, Lirik" />
  69. <meta property="og:type" content="article" />
  70. <meta property="og:url" content="<?php echo build_permalink_for(get_search_query(),'tag');?>" />
  71. <meta property="og:image" content="<?php echo get_template_directory_uri();?>/images/artworks_250x250.jpg" />
  72. <meta property="og:site_name" content="<?php bloginfo('name');?>" />
  73. <link rel="canonical" href="<?php echo build_permalink_for(get_search_query(),'tag');?>" />
  74. <?php } elseif ($_GET['yttitle']) { ?>
  75. <meta name="robots" content="noindex, nofollow">
  76. <meta name="description" content="Download <?php echo ucwords(str_replace('-',' ',$_GET['yttitle'])); ?> Free Download Lagu MP3, Video Mp4 3GP, Lirik dan Berita Musik Update <?php echo date('d-M-Y');?> Terbaru" />
  77. <meta name="keywords" content="<?php echo ucwords(str_replace('-',' ',$_GET['yttitle'])); ?>, mp3 download, download lagu, download video, k-pop, lagu barat, lagu indonesia, lagu dangdut, full album, lirik lagu, mp3 terbaru, tangga lagu, situs lagu, nada lagu, nadalagu" />
  78. <meta property="og:description" content="Download <?php echo ucwords(str_replace('-',' ',$_GET['yttitle'])); ?> Free Download Lagu MP3, Video Mp4 3GP, Lirik dan Berita Musik Update <?php echo date('d-M-Y');?> Terbaru" />
  79. <meta property="fb:app_id" content="218430011893932" />
  80. <meta property="og:title" content="Link Download <?php echo ucwords(str_replace('-',' ',$_GET['yttitle'])); ?>  MP3, Video, Lirik" />
  81. <meta property="og:type" content="article" />
  82. <meta property="og:url" content="<?php echo get_bloginfo('url').'/link/'.$_GET['yttitle'].'-'.$_GET['ytid'].'/'; ?>" />
  83. <meta property="og:image" content="https://i.ytimg.com/vi/<?php echo base64url_decode($_GET['ytid']);?>/hqdefault.jpg" />
  84. <meta property="og:site_name" content="<?php bloginfo('name');?>" />
  85. <link rel="canonical" href="<?php echo get_bloginfo('url').'/link/'.$_GET['yttitle'].'-'.$_GET['ytid'].'/'; ?>" />
  86. <?php } ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement