当前位置: 首页>>代码示例>>PHP>>正文


PHP SiteConfig::fetchWindowsPiniconBackgroundColor方法代码示例

本文整理汇总了PHP中SiteConfig::fetchWindowsPiniconBackgroundColor方法的典型用法代码示例。如果您正苦于以下问题:PHP SiteConfig::fetchWindowsPiniconBackgroundColor方法的具体用法?PHP SiteConfig::fetchWindowsPiniconBackgroundColor怎么用?PHP SiteConfig::fetchWindowsPiniconBackgroundColor使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在SiteConfig的用法示例。


在下文中一共展示了SiteConfig::fetchWindowsPiniconBackgroundColor方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: GenerateWindowsPinicon

 /**
  * Generates markup for the Windows pinicon
  *
  * @param SiteConfig $config
  * @param SiteTree $owner
  * @param $metadata
  * @param Image $WindowsPinicon
  *
  * @return void
  */
 protected function GenerateWindowsPinicon(SiteConfig $config, SiteTree $owner, &$metadata, Image $WindowsPinicon)
 {
     // header
     $metadata .= $owner->MarkupComment('Windows Pinned Icon');
     // application name
     $appName = $config->fetchPiniconTitle();
     if (!$appName) {
         $appName = $config->Title;
     }
     $metadata .= $owner->MarkupMeta('application-name', $appName);
     // tile background color
     if ($config->fetchWindowsPiniconBackgroundColor()) {
         $metadata .= $owner->MarkupMeta('msapplication-TileColor', $config->fetchWindowsPiniconBackgroundColor());
     }
     // small tile
     $metadata .= $owner->MarkupMeta('msapplication-square70x70logo', $WindowsPinicon->Fill(70, 70)->getAbsoluteURL());
     // medium tile
     $metadata .= $owner->MarkupMeta('msapplication-square150x150logo', $WindowsPinicon->Fill(150, 150)->getAbsoluteURL());
     // @todo: Implement wide & tall tiles
     // wide tile
     //			$metadata .= $owner->MarkupMeta('msapplication-square310x150logo', $WindowsPinicon->Fill(310,150)->getAbsoluteURL());
     // large tile
     //			$metadata .= $owner->MarkupMeta('msapplication-square310x310logo', $WindowsPinicon->Fill(310,310)->getAbsoluteURL());
 }
开发者ID:graphiques-digitale,项目名称:silverstripe-seo-icons,代码行数:34,代码来源:SEO_Icons_SiteTree_DataExtension.php


注:本文中的SiteConfig::fetchWindowsPiniconBackgroundColor方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。