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


PHP tools::getPlatform方法代码示例

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


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

示例1: rules

 /**
  * @return array validation rules for model attributes.
  */
 public function rules()
 {
     // NOTE: you should only define rules for those attributes that
     // will receive user inputs.
     return array(array('uid', 'default', 'setOnEmpty' => true, 'value' => zmf::uid()), array('platform', 'default', 'setOnEmpty' => true, 'value' => tools::getPlatform()), array('uid, logid,content,classify, status, cTime', 'required'), array('status', 'numerical', 'integerOnly' => true), array('uid, touid, logid, commentid, tocommentid, cTime', 'length', 'max' => 11), array('content', 'length', 'max' => 255), array('platform, classify', 'length', 'max' => 16), array('id, uid, touid, logid, commentid, tocommentid, content, platform, classify, status, cTime', 'safe', 'on' => 'search'));
 }
开发者ID:ph7pal,项目名称:naodong,代码行数:9,代码来源:Comments.php

示例2: rules

 public function rules()
 {
     return array(array('uid', 'default', 'setOnEmpty' => true, 'value' => Yii::app()->user->isGuest ? mt_rand(1, 40000) : Yii::app()->user->id), array('uid, logid, content', 'required'), array('status, opencomment, openshare,areaid', 'numerical', 'integerOnly' => true), array('uid, logid, favor, nouse, hits, cTime', 'length', 'max' => 11), array('platform', 'length', 'max' => 16), array('comments, lastupdate,areaid', 'length', 'max' => 10), array('favoruids', 'length', 'max' => 255), array('status', 'default', 'setOnEmpty' => true, 'value' => Posts::STATUS_PASSED), array('cTime,lastupdate', 'default', 'setOnEmpty' => true, 'value' => time()), array('platform', 'default', 'setOnEmpty' => true, 'value' => tools::getPlatform()), array('id, uid, logid,areaid', 'safe', 'on' => 'search'));
 }
开发者ID:ph7pal,项目名称:wedding,代码行数:4,代码来源:Answer.php

示例3: rules

 public function rules()
 {
     // NOTE: you should only define rules for those attributes that
     // will receive user inputs.
     return array(array('uid', 'default', 'setOnEmpty' => true, 'value' => zmf::uid()), array('uid,colid, title, content', 'required'), array('colid', 'chkColid'), array('title', 'chkTitle'), array('status', 'default', 'setOnEmpty' => true, 'value' => Posts::STATUS_PASSED), array('cTime,updateTime', 'default', 'setOnEmpty' => true, 'value' => zmf::now()), array('lat,long', 'default', 'setOnEmpty' => true, 'value' => '0'), array('uid, colid, hits, cTime, updateTime, status, top , favors,mapZoom,classify,comments,areaid,faceimg,favorite,groupid', 'numerical', 'integerOnly' => true), array('title,sourceurl,sourceinfo,keywords,description,redirect,tagids', 'length', 'max' => 255), array('lat,long', 'length', 'max' => 50), array('platform', 'length', 'max' => 16), array('platform', 'default', 'setOnEmpty' => true, 'value' => tools::getPlatform()), array('title', 'safe', 'on' => 'search'));
 }
开发者ID:ph7pal,项目名称:wedding,代码行数:6,代码来源:Posts.php

示例4: rules

 public function rules()
 {
     return array(array('uid', 'default', 'setOnEmpty' => true, 'value' => zmf::uid()), array('uid, title', 'required'), array('title', 'chkTitle'), array('status,areaid', 'numerical', 'integerOnly' => true), array('uid, cTime, favor, favorite, hits, thesame', 'length', 'max' => 11), array('title, content, tagids, likethis', 'length', 'max' => 255), array('platform', 'length', 'max' => 16), array('comments, answers, lastupdate,areaid', 'length', 'max' => 10), array('status', 'default', 'setOnEmpty' => true, 'value' => Posts::STATUS_PASSED), array('cTime,lastupdate', 'default', 'setOnEmpty' => true, 'value' => zmf::now()), array('platform', 'default', 'setOnEmpty' => true, 'value' => tools::getPlatform()), array('id, uid, title, content, platform, cTime, favor, favorite, comments, answers, lastupdate, hits, status, tagids, likethis, thesame,areaid', 'safe', 'on' => 'search'));
 }
开发者ID:ph7pal,项目名称:wedding,代码行数:4,代码来源:Question.php


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