承接 milkyway/silverstripe-microdata 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

milkyway/silverstripe-microdata

Composer 安装命令:

composer require milkyway/silverstripe-microdata

包简介

Add the ability to add Microdata via templates

README 文档

README

This module allows you to add Microdata via your templates. This module uses schema.org, but you can easily change the url using the yaml config.

About microdata

Microdata are additional attributes and tags added to describe and provide additional information about the content of your web page.

Some search engines (in particular Google) have adopted this technology and use it to enhance their search engine results (and the appearance of your search engine result as well!)

For more information see: Google Webmaster Tools - About microdata

Requirements

  • SilverStripe 3.1

Author

Install using composer

composer require milkyway/silverstripe-microdata:*

Example Code

Page.ss

<div class="product" $microData.Product>
    <div class="description" $microData.Description>Description</div>
    <div class="pricing" $microData.Offers>
        <strong $microData.Price>$Price</strong>
        <% if $inStock %>$microData.InStock<% else %>$microData.NoStock<% else %>
    </div>
</div>

<% loop $Reviews %>
<div class="review" $microData.getAttributes('review','Review',1)>
    $Content
    $microData.metaTag('rating','9.5/10')
</div>
<% end_loop %>

This module adds a new variable: $microData to the global scope that creates all the necessary attributes. Some are predefined, but there are methods provided allowing you to add custom attributes. If you use a variable that does not exist on the MicrodataProvider class, it will assume it is an itemprop attribute and will add the attribute accordingly.

统计信息

  • 总下载量: 58
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 6
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 6
  • Watchers: 2
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: BSD-3-Clause
  • 更新时间: 2014-01-14

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固