<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ namespace Module\Nav\Type; use ModStart\Core\Type\BaseType; class NavOpenType implements BaseType { const CURRENT_WINDOW = 1; const NEW_BLANK = 2; public static function getList() { return array(self::CURRENT_WINDOW => '当前窗口', self::NEW_BLANK => '新窗口'); } public static function getBlankAttributeFromValue($koTED) { goto OpuRP; cj5v4: if (is_array($koTED)) { $koTED = isset($koTED['openType']) ? $koTED['openType'] : null; } goto gvnBe; K9A7U: return ''; goto XhpPw; OpuRP: if (empty($koTED)) { return ''; } goto cj5v4; gvnBe: switch ($koTED) { case self::NEW_BLANK: return 'target="_blank"'; } goto K9A7U; XhpPw: } }