MyBB 1.8.x Mod Google Search Console
#1
Bug 
El siguiente codigo es para mejorar la apariencia de la pagina web en Google Search Console.

Este codigo lo puse en el templan del Header, donde ya habíamos implementado el Google Custom Search

Este Seria el Codigo implementado:

PHP Code:
<!-- Google WebMaster Tools Logo Script  -->
<
script type="application/ld+json">
{
 
 "@context""http://schema.org",
 
 "@type""Organization",
 
 "url""https://pinostudio1.com",
 
 "logo""https://pinostudio1.com/images/logo.png"
}
</script>

<!-- Google WebMaster Tools Sitelinks Searchbox Script  -->
<script type="application/ld+json">
{
  "@context": "http://schema.org",
  "@type": "WebSite",
  "url": "https://pinostudio1.com",
  "potentialAction": [{
    "@type": "SearchAction",
    "target": "https://pinostudio1.com/search?q={search_term_string}",
    "query-input": "required name=search_term_string"
  }]
}
</script>

<!-- Google WebMaster Tools Sitelinks Social Profile Script  -->
<script type="application/ld+json">
{
  "@context": "http://schema.org",
  "@type": "Person",
  "name": "DiegoPino",
  "url": "https://pinostudio1.com",
  "sameAs": [
    "https://plus.google.com/u/0/+DiegoPinoDurango",
    "https://www.youtube.com/user/we11world/",
    "https://twitter.com/DiegoPin0"
  ]
}
</script>

<meta name="PinoStudio1" content="Website con informacion para estudiar sobre La Santa Biblia, Musica, Historia & Filosofia"> 


Este seria el Codigo Completo del template Header
Home » Template Sets » Default Templates » Edit Template: header

Code:
<!-- Google WebMaster Tools Logo Script  -->
<script type="application/ld+json">
{
 "@context": "http://schema.org",
 "@type": "Organization",
 "url": "https://pinostudio1.com",
 "logo": "https://pinostudio1.com/images/logo.png"
}
</script>

<!-- Google WebMaster Tools Sitelinks Searchbox Script  -->
<script type="application/ld+json">
{
 "@context": "http://schema.org",
 "@type": "WebSite",
 "url": "https://pinostudio1.com",
 "potentialAction": [{
   "@type": "SearchAction",
   "target": "https://pinostudio1.com/search?q={search_term_string}",
   "query-input": "required name=search_term_string"
 }]
}
</script>

<!-- Google WebMaster Tools Sitelinks Social Profile Script  -->
<script type="application/ld+json">
{
 "@context": "http://schema.org",
 "@type": "Person",
 "name": "DiegoPino",
 "url": "https://pinostudio1.com",
 "sameAs": [
   "https://plus.google.com/u/0/+DiegoPinoDurango",
   "https://www.youtube.com/user/we11world/",
   "https://twitter.com/DiegoPin0"
 ]
}
</script>

<meta name="PinoStudio1" content="Website con informacion para estudiar sobre La Santa Biblia, Musica, Historia & Filosofia">



<div id="container">
        <a name="top" id="top"></a>
        <div id="header">
            <div id="logo">
                <div class="wrapper">
                    <a href="{$mybb->settings['bburl']}/index.php"><img src="{$theme['logo']}" alt="{$mybb->settings['bbname']}" title="{$mybb->settings['bbname']}" /></a>
                    <ul class="menu top_links">
                        {$menu_portal}
                        {$menu_search}
                        {$menu_memberlist}
                        {$menu_calendar}
                        <li><a href="{$mybb->settings['bburl']}/misc.php?action=help" class="help">{$lang->toplinks_help}</a></li>
                    </ul>
                </div>
            </div>
            <div id="panel">
                <div class="upper">
                    <div class="wrapper">
                        {$quicksearch}
                        {$welcomeblock}
                    <!-- </div> in header_welcomeblock_member and header_welcomeblock_guest -->
                <!-- </div> in header_welcomeblock_member and header_welcomeblock_guest -->
            </div>
        </div>
        <div id="content">
            <div class="wrapper">
                {$pm_notice}
                {$remote_avatar_notice}
                {$bannedwarning}
                {$bbclosedwarning}
                {$unreadreports}
                {$pending_joinrequests}
                {$awaitingusers}
                <navigation>
                <br />
                    
<div class=googlesb>
<script>
 (function() {
   var cx = '013981424964457603749:ejpys8iwla4';
   var gcse = document.createElement('script');
   gcse.type = 'text/javascript';
   gcse.async = true;
   gcse.src = 'https://cse.google.com/cse.js?cx=' + cx;
   var s = document.getElementsByTagName('script')[0];
   s.parentNode.insertBefore(gcse, s);
 })();
</script>
<gcse:search></gcse:search>
</div>
[Image: 51.jpg]
We11World [ Winning Eleven ] , Blog , Archive Forums
Reply


Possibly Related Threads...
Thread Author Views Last Post
Bug MyBB 1.8.x Mod  Add Google Custom Search to Header [Edit Core File] DiegoPino 412 05-17-2018, 02:15 AM
Last Post: DiegoPino

Forum Jump:


Users browsing this thread: 1 Guest(s)