Feature RTC PR-5.2-dev Pending

User tests: Successful: Unsuccessful:

avatar conseilgouz
conseilgouz
1 Mar 2024

( see discussion #42920)

Summary of Changes

When vote plugin is enabled, Rich results are created but are rejected by Google Rich Results tool.

Testing Instructions

Enable Vote plugin.
Enable Voting in Articles component configuration.
Vote for one or more articles
Set different schemaorg type for your articles
Check your articles using https://search.google.com/test/rich-results

Actual result BEFORE applying this Pull Request

Google Rich Results check gives an error
Review snippets shows 2 errors :
rich_snippet_error

Expected result AFTER applying this Pull Request

Google Rich Results check is OK
rich_snippet_ok

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:

  • No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

Votes

# of Users Experiencing Issue
1/1
Average Importance Score
3.00

avatar conseilgouz conseilgouz - open - 1 Mar 2024
avatar conseilgouz conseilgouz - change - 1 Mar 2024
Status New Pending
avatar joomla-cms-bot joomla-cms-bot - change - 1 Mar 2024
Category Front End Plugins
avatar conseilgouz conseilgouz - change - 1 Mar 2024
The description was changed
avatar conseilgouz conseilgouz - edited - 1 Mar 2024
avatar ManuelVoileux
ManuelVoileux - comment - 1 Mar 2024

Thanks for raising hand.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42933.
avatar conseilgouz
conseilgouz - comment - 1 Mar 2024

This fix works with Joomla! 5.0 but, as there won't be any more 5.0 release, I put it in 5.1 branch.

avatar ManuelVoileux
ManuelVoileux - comment - 1 Mar 2024

I have experienced the same issue.
I have activated the Vote plugin, and I have used vote on an article.
When I check with the Google validation tool I get a critical error. itemReviewed field missing.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42933.
avatar ManuelVoileux
ManuelVoileux - comment - 1 Mar 2024
avatar ManuelVoileux
ManuelVoileux - comment - 1 Mar 2024

AFTER applying this Pull Request I got green light from Google
Screenshot 2024-03-01 at 13-30-10

avatar sandewt
sandewt - comment - 1 Mar 2024

This issue also concerns Joomla 4.

avatar richard67
richard67 - comment - 1 Mar 2024

AFTER applying this Pull Request I got green light from Google

@ManuelVoileux Does that mean a successful test? If so, please go to the issue tracker here https://issues.joomla.org/tracker/joomla-cms/42933 and mark your test result by using the blue "Test this" button at the top left corner, then selecting the appropriate test result (success) and submit.

Every pull request needs 2 successful human tests, and it needs to submit the test result with the issue tracker so the tests are properly counted.

Thanks in advance.

avatar richard67
richard67 - comment - 1 Mar 2024

This issue also concerns Joomla 4.

@conseilgouz If this is right, it would need to make this pull request for the 4.4-dev branch. Later maintainers will merge it up into the 5.1-dev branch when the 4.4-dev PR will have been tested and merged.

avatar brianteeman
brianteeman - comment - 1 Mar 2024

This solution is correct for J4 which uses itemprop etc
This solution is not correct for J5 which used jsonld

avatar ManuelVoileux ManuelVoileux - test_item - 1 Mar 2024 - Tested successfully
avatar ManuelVoileux
ManuelVoileux - comment - 1 Mar 2024

I have tested this item ✅ successfully on ceb86b1


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42933.

avatar Fedik
Fedik - comment - 1 Mar 2024

Not that easy.

The page does not contain Product, how it can have the product rating then?
I mean having an empty Product is invalid also.

Just try https://search.google.com/test/rich-results?hl=en

<div itemscope="itemscope" itemtype="https://schema.org/Product"> 
<p class="visually-hidden" itemprop="aggregateRating" itemscope itemtype="https://schema.org/AggregateRating">
   <meta itemprop="ratingCount" content="5">
   <meta itemprop="worstRating" content="1">
   <span itemprop="ratingValue">5</span>
   <span itemprop="bestRating">5</span>
</p>
</div>

It will ask you for full product information.

avatar Fedik
Fedik - comment - 1 Mar 2024

A better fix would be to remove all HTML schema from layout plugins/content/vote/tmpl/rating.php
And add it with schema plugin, as part of the content schema.

avatar ManuelVoileux
ManuelVoileux - comment - 1 Mar 2024

Not that easy.
The page does not contain Product, how it can have the product rating then? I mean having an empty Product is invalid also.
Just try https://search.google.com/test/rich-results?hl=en

<div itemscope="itemscope" itemtype="https://schema.org/Product"> ...  </div>

It will ask you for full product information.

If the Schema tab is filled in, the itemscope, itemtype should be taken from the schema type, and the rating result should be merged in the schema output.

avatar Fedik
Fedik - comment - 1 Mar 2024

If the Schema tab is filled in, the itemscope, itemtype should be taken from the schema type, and the rating result should be merged in the schema output.

Correct, that what I mean in #42933 (comment)

avatar conseilgouz
conseilgouz - comment - 1 Mar 2024

The page does not contain Product, how it can have the product rating then?

I had a doubt about Product type. This idea comes from JED pages : if you take a look at https://extensions.joomla.org/extension/cg-isotope/ source code, it's done this way and Google search gives me nice stars.

avatar conseilgouz
conseilgouz - comment - 1 Mar 2024

google_search

avatar conseilgouz
conseilgouz - comment - 1 Mar 2024

This issue also concerns Joomla 4.

@conseilgouz If this is right, it would need to make this pull request for the 4.4-dev branch. Later maintainers will merge it up into the 5.1-dev branch when the 4.4-dev PR will have been tested and merged.

Same code, same issue in Joomla 4.4.

@richard67 : is 4.4-dev PR a new PR ?

@conseilgouz You can rebase this PR here by changing the base branch with use of the "Edit" button right beside the title on GitHub, or you make a new one for the 4.4-dev branch, whatever is easier for you.

avatar conseilgouz conseilgouz - change - 1 Mar 2024
Labels Added: PR-5.1-dev
avatar conseilgouz conseilgouz - change - 1 Mar 2024
Status Pending Closed
Closed_Date 0000-00-00 00:00:00 2024-03-01 16:40:51
Closed_By conseilgouz
avatar conseilgouz
conseilgouz - comment - 1 Mar 2024

closed, move to 4.4-dev branch #42934

avatar conseilgouz conseilgouz - close - 1 Mar 2024
avatar sandewt
sandewt - comment - 1 Mar 2024

closed, move to 4.4-dev branch #42934

You could have changed the branche here to move to 4.4

avatar Fedik
Fedik - comment - 1 Mar 2024

I had a doubt about Product type. This idea comes from JED pages : if you take a look at
https://extensions.joomla.org/extension/cg-isotope/ source code, it's done this way and Google search gives me nice stars.

No, that not correct example.
That whole page is about Product, and there it is correct.
Hovewer what you trying here, is incorect, sorry. Because here no product exists.

avatar conseilgouz
conseilgouz - comment - 2 Mar 2024

No, that not correct example.
That whole page is about Product, and there it is correct.
Hovewer what you trying here, is incorect, sorry. Because here no product exists.

Product is a generic type, it could be anything : https://schema.org/Product

In JED page, I did not find any other schema.org line other than reviews and aggregateRating, and Google seems to be happy with this.

avatar conseilgouz
conseilgouz - comment - 2 Mar 2024

You could have changed the branche here to move to 4.4

I tried but I broke it (I'm not a great github user).

avatar sandewt
sandewt - comment - 3 Mar 2024

Product is a generic type, it could be anything : https://schema.org/Product

It may be more applicable to use ?

<div itemprop="review" itemscope itemtype="https://schema.org/Review">

instead of:

<div itemprop="review" itemscope itemtype="https://schema.org/Product">

Customer reviews: (Microdata)
see: https://schema.org/reviewCount
see: https://schema.org/Rating

See examples

avatar conseilgouz conseilgouz - change - 3 Mar 2024
Status Closed New
Closed_Date 2024-03-01 16:40:51
Closed_By conseilgouz
avatar conseilgouz conseilgouz - change - 3 Mar 2024
Status New Pending
avatar conseilgouz conseilgouz - reopen - 3 Mar 2024
avatar joomla-cms-bot joomla-cms-bot - change - 3 Mar 2024
Category Front End Plugins Administration Language & Strings Libraries Front End Plugins
avatar conseilgouz conseilgouz - change - 3 Mar 2024
Labels Added: Language Change
avatar conseilgouz
conseilgouz - comment - 3 Mar 2024

Just to make sure I'm going the correct way, I created a new plugin plugins/schemaorg/aggregaterating.

It adds aggregaterating infos to Recipe type in Json+ld format.
For other types, it adds an aggregateRating lines with product type.

If it sounds correct, I'll continue adding AggregateRating to other schemaorg types.

avatar brianteeman
brianteeman - comment - 3 Mar 2024

Please see #42699 for an example of all the other changes that you need to make to add this new plugin

avatar bembelimen
bembelimen - comment - 3 Mar 2024

You should not add a new plugin, the existing plugin should do what @Fedik said here: #42934 (comment)

avatar conseilgouz
conseilgouz - comment - 3 Mar 2024

You should not add a new plugin, the existing plugin should do what @Fedik said here: #42934 (comment)

sounds easier

avatar joomla-cms-bot joomla-cms-bot - change - 3 Mar 2024
Category Front End Plugins Administration Language & Strings Libraries Libraries Front End Plugins
avatar conseilgouz conseilgouz - change - 3 Mar 2024
Labels Removed: Language Change
avatar conseilgouz conseilgouz - change - 3 Mar 2024
Title
[5.1] Vote : aggregateRating error in Google Rich Results
[5.1] Vote : add aggregateRating in article's schemaorg information
avatar conseilgouz conseilgouz - edited - 3 Mar 2024
avatar conseilgouz
conseilgouz - comment - 4 Mar 2024

Just added Book/Event/Organization types.
After some more testings, JobPosting and Person types are not supposed to have aggregaterating infos.

avatar conseilgouz conseilgouz - change - 4 Mar 2024
The description was changed
avatar conseilgouz conseilgouz - edited - 4 Mar 2024
avatar conseilgouz
conseilgouz - comment - 4 Mar 2024

Added schemaorg type Article

avatar Fedik
Fedik - comment - 4 Mar 2024

That looks better, thanks.
Couple notes:

Please remove the traits, they are not reusable in this implementation. Just keep that code withing the plugin itself.
Add full list of schemes which support aggregateRating https://schema.org/AggregateRating:

Brand, CreativeWork, Event, Offer, Organization, Place, Product, Service

avatar joomla-cms-bot joomla-cms-bot - change - 4 Mar 2024
Category Front End Plugins Libraries Front End Plugins
avatar conseilgouz conseilgouz - change - 5 Mar 2024
Labels Added: Feature
avatar Quy
Quy - comment - 6 Mar 2024

@conseilgouz FYI: It is not necessary to keep updating the branch as it will also reset test results that maintainers have to restore. This will save you/maintainers time. Thank you.

avatar exlemor exlemor - test_item - 23 Mar 2024 - Tested successfully
avatar exlemor
exlemor - comment - 23 Mar 2024

I have tested this item ✅ successfully on 556e59e

I was able to replicate successfully the Expected results of Google Rich Results check is OK (and had the error prior to patch).


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42933.

avatar viocassel viocassel - test_item - 29 Mar 2024 - Tested successfully
avatar viocassel
viocassel - comment - 29 Mar 2024

I have tested this item ✅ successfully on 556e59e


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42933.

avatar Quy Quy - change - 29 Mar 2024
Status Pending Ready to Commit
avatar Quy
Quy - comment - 29 Mar 2024

RTC


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42933.

avatar conseilgouz conseilgouz - change - 6 Apr 2024
Labels Added: RTC
avatar joomla-cms-bot joomla-cms-bot - change - 6 Apr 2024
Category Front End Plugins Libraries Front End Plugins
avatar joomla-cms-bot joomla-cms-bot - change - 6 Apr 2024
Category Front End Plugins Libraries Administration com_joomlaupdate Libraries Front End Plugins
avatar joomla-cms-bot joomla-cms-bot - change - 6 Apr 2024
Category Front End Plugins Libraries Administration com_joomlaupdate Administration com_joomlaupdate Front End Plugins
avatar joomla-cms-bot joomla-cms-bot - change - 6 Apr 2024
Category Front End Plugins Administration com_joomlaupdate Front End Plugins
avatar growunder growunder - test_item - 11 Apr 2024 - Tested successfully
avatar growunder
growunder - comment - 11 Apr 2024

I have tested this item ✅ successfully on 556e59e

Tested successfully. applied patch and fixed the issue


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42933.
avatar cybersalt cybersalt - test_item - 11 Apr 2024 - Tested successfully
avatar cybersalt
cybersalt - comment - 11 Apr 2024

I have tested this item ✅ successfully on 556e59e


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/42933.

avatar conseilgouz
conseilgouz - comment - 12 Apr 2024

@cybersalt @growunder Thank you for your test.
@exlemor and @viocassel already made "human tests", so now we have 4 positive tests.
Unfortunately, Fedik made this a new feature instead of a bug (why ?), so, even if is RTC, it won't be released with 5.1, may be in 5.2...
Pascal

avatar HLeithner
HLeithner - comment - 24 Apr 2024

This pull request has been automatically rebased to 5.2-dev.

avatar HLeithner HLeithner - change - 24 Apr 2024
Title
[5.1] Vote : add aggregateRating in article's schemaorg information
[5.2] Vote : add aggregateRating in article's schemaorg information
avatar HLeithner HLeithner - edited - 24 Apr 2024
avatar pe7er pe7er - change - 26 Apr 2024
Labels Added: PR-5.2-dev
avatar Quy Quy - change - 30 Apr 2024
Labels Removed: PR-5.1-dev
avatar pe7er pe7er - close - 30 Apr 2024
avatar pe7er pe7er - merge - 30 Apr 2024
avatar pe7er pe7er - change - 30 Apr 2024
Status Ready to Commit Fixed in Code Base
Closed_Date 0000-00-00 00:00:00 2024-04-30 15:48:32
Closed_By pe7er
avatar pe7er
pe7er - comment - 30 Apr 2024

Thanks @conseilgouz !

Add a Comment

Login with GitHub to post a comment