Skip to content

Commit

Permalink
ref: EC-CUBE#4807 canonical url追加
Browse files Browse the repository at this point in the history
  • Loading branch information
tao-s committed Dec 18, 2020
1 parent 8e12f67 commit 5dd881e
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/Eccube/Resource/template/default/default_frame.twig
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,14 @@ file that was distributed with this source code.
{% if Page.meta_tags is not empty %}
{{ include(template_from_string(Page.meta_tags)) }}
{% endif %}
{# canonical url #}
{% if Category is defined %}
<link rel="canonical" href="{{url('product_list')}}?category_id={{Category.id}}" />
{% elseif Product is defined %}
<link rel="canonical" href="{{url('product_detail',{"id":Product.id})}}" />
{% elseif Page is defined %}
<link rel="canonical" href="{{url(Page.url)}}" />
{% endif %}
<link rel="icon" href="{{ asset('assets/img/common/favicon.ico', 'user_data') }}">
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css" integrity="sha384-HSMxcRTRxnN+Bdg0JdbxYKrThecOKuH5zCYotlSAcp1+c8xmyTe9GYg1l9a69psu" crossorigin="anonymous">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.3.1/css/all.css" integrity="sha384-mzrmE5qonljUremFsqc01SB46JvROS7bZs3IO2EmfFsd15uHvIt+Y8vEf7N7fWAU" crossorigin="anonymous">
Expand Down

0 comments on commit 5dd881e

Please sign in to comment.