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


PHP auth::isAdmin方法代码示例

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


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

示例1: mail2secretary

 public static function mail2secretary($data, $action)
 {
     global $mailClass;
     $owner = auth::getGecos($data["owneruid"], 0);
     $pp = self::getFullPpNumber($data["year"], $data["ppn"]);
     return self::sendMail(PP_MAIL_SECRETARY, $pp . " " . $action . " for " . $owner, self::mail_preprint_prettyprinted($data, $owner, $pp, $action), auth::isAdmin());
 }
开发者ID:,项目名称:,代码行数:7,代码来源:

示例2: getPendingPreprints

 public function getPendingPreprints($where = "")
 {
     $outRecord = array();
     $authorUid = auth::getUid();
     //TODO@@@ debug:
     //$authorUid = -1180; // Axel Brandenburg
     //$authorUid = 127105; // Paolo Di Vecchia
     if (empty($authorUid) && !auth::isAdmin()) {
         return array();
     }
     // ----------------------
     $sql = "SELECT " . "  `RowId`," . "  `Id`," . "  `Tm`," . "  `Year`," . "  `Report`," . "  `Status`," . "  `Field`," . "  `Location`," . "  `Authors`," . "  `Title`," . "  `PublIn`," . "  `publ_year`," . "  `label` " . "FROM " . "  " . $this->dbprefix . PP_DATATABLE . " " . "WHERE " . "(Status!='ok') " . "AND (Status!='free') " . (!empty($authorUid) ? " AND (Id = '" . $authorUid . "') " : "") . (!empty($where) ? " AND " . $where . " " : "") . "ORDER BY " . "  Year,Report DESC";
     // ----------------------
     $res = $this->query($sql);
     // includes a call to connect
     if ($this->num_rows($res)) {
         while ($row = $this->next_record_assoc($res)) {
             $outRecord[] = $this->translatePrpFieldsToStandard($row);
         }
         // end while
     }
     // end if
     // ----------------------
     return $outRecord;
 }
开发者ID:,项目名称:,代码行数:25,代码来源:

示例3: function

				request = null;
			}
		};
	}

	ajax(jsonURL,null,drawChart );

	window.onload = function() {
		//ieCanvasInit('includes/iecanvas.htc');
		// draw(); 
	};

</script>

<?php 
if ($CONF_airspaceChecks && auth::isAdmin($userID)) {
    ?>
<script language="javascript">

function toggleAirspace(radioObj) {
	if(!radioObj) return "";	
	if(radioObj.checked) {
		showAirspace=1;
        for (var i=0; i<polys.length; i++) {
			map.addOverlay(polys[i]);
        }
	} else {
		showAirspace=0;
        for (var i=0; i<polys.length; i++) {
			map.removeOverlay(polys[i]);
        }
开发者ID:Peter2121,项目名称:leonardoxc,代码行数:31,代码来源:EXT_google_maps_track_old.php


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