Probleme date structurate google

Plugin-uri, teme, configurare

Moderator: Moderatori

FlaviusTech
New Member
Mesaje: 3
Membru din: Mie Feb 17, 2016 5:08 am

Probleme date structurate google

Mesajde FlaviusTech » Mie Feb 17, 2016 5:22 am

Salutare, sunt nou in domeniul asta si nu am cunostinte in programarea HTML, am facut un website si am inceput cu o thema foarte usoara simple catch, apoi am schimbat tema cu cwp megaresponsive theme si au aparut ceva probleme in structurile de date a vizualizarii de catre google.
Am crezut ca este din vina SEO si am dezinstalat, dar problema tot exista, anexez si un printscreen cu erorile, am verificat si incercat sa modific single.php dintr-o indrumare de pe forum google webmasters dar nu am reusit.
Daca aveti vreo sugestie ce as mai putea sa incerc? Imi place tema asta dar e plina de bug-uri dar e buna si pentru device-uri mobile.
Daca este nevoie si de content-single.php cum pot sa urc fisiere text pe forum?
Multumiri anticipate.
Fişiere ataşate
New Bitmap Image.jpg
New Bitmap Image.jpg (318.69 KiB) Vizualizat de 4271 ori



pont
PHPRomania Supporter
Mesaje: 26
Membru din: Lun Apr 12, 2010 3:45 pm

Re: Probleme date structurate google

Mesajde pont » Sâm Feb 20, 2016 3:46 pm

Ai 2 variante:

1) cauti alta tema.
2) faci o tema child si modifici pe ea:

a) Pentru "lipseste : updated"
I. Cauti in tema unde apelezi functia "the date":

Cod: Selectaţi tot

<?php the_date(); ?>


II. Adaugi un span cu clasa post-date updated:

Cod: Selectaţi tot

<span class="post-date updated"><?php the_date(); ?></span>


b) Pentru "lipseste:autor”

I. Cauti in fisierul single.php unde apare:

Cod: Selectaţi tot

    <?php the_author(); ?>


II. Modifici astfel:

Cod: Selectaţi tot

    <span class="vcard author post-author"><span class="fn"><?php the_author(); ?></span></span>

FlaviusTech
New Member
Mesaje: 3
Membru din: Mie Feb 17, 2016 5:08 am

Re: Probleme date structurate google

Mesajde FlaviusTech » Dum Feb 21, 2016 1:08 am

Multumesc de raspuns.
<?php
the_post();
printf( __( 'Author: %s', 'megaresponsive-lite' ), '<span class="vcard"><a class="url fn n" href="' . esc_url( get_author_posts_url( get_the_author_meta( 'ID' ) ) ) . '" title="' . esc_attr( get_the_author() ) . '" rel="me">' . get_the_author() . '</a></span>' );

Cam asa apare la mine si am gasit abia prin archive.php , cel putin la "the_author" .
Iar la "the_date" care tot in archive.php il gasesc :

<?php
printf( __( 'Month: %s', 'megaresponsive-lite' ), '<span>' . get_the_date( 'F Y' ) . '</span>' );

elseif ( is_year() ) :
$year_archive = get_query_var('year');
?>
<input type="hidden" id="year_id" value="<?php echo $year_archive; ?>" />
<?php
printf( __( 'Year: %s', 'megaresponsive-lite' ), '<span>' . get_the_date( 'Y' ) . '</span>'


Înapoi la “Wordpress”

Cine este conectat

Utilizatori ce ce navighează pe acest forum: Niciun utilizator înregistrat și 7 vizitatori