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


PHP CUtil::AddSlashes方法代码示例

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


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

示例1: ActionDoGroup

	function ActionDoGroup($id, $action_id, $add_params='')
	{
		/** @global CMain $APPLICATION */
		global $APPLICATION;
		return $this->table_id.".GetAdminList('".CUtil::AddSlashes($APPLICATION->GetCurPage())."?ID=".CUtil::AddSlashes($id)."&action_button=".CUtil::AddSlashes($action_id)."&lang=".LANGUAGE_ID."&".freetrix_sessid_get().($add_params<>""?"&".CUtil::AddSlashes($add_params):"")."');";
	}
开发者ID:ASDAFF,项目名称:open_bx,代码行数:6,代码来源:admin_lib.php

示例2: foreach

<?php 
foreach ($arModules as $info) {
    ?>
	<tr>
		<td><b><?php 
    echo htmlspecialcharsex($info["MODULE_NAME"]);
    ?>
</b> <?php 
    echo htmlspecialcharsex(strlen($info["MODULE_PARTNER"]) > 0 ? " <b><i>(" . str_replace(array("#NAME#", "#URI#"), array($info["MODULE_PARTNER"], $info["MODULE_PARTNER_URI"]), GetMessage("MOD_PARTNER_NAME")) . ")</i></b>" : "(" . $info["MODULE_ID"] . ")");
    ?>
<br><?php 
    echo $info["MODULE_DESCRIPTION"];
    ?>
</td>
		<td ondblclick="<?php 
    echo htmlspecialcharsbx("DoAction(event, 'version_down', '" . CUtil::AddSlashes($info["MODULE_ID"]) . "')");
    ?>
" id="version_for_<?php 
    echo htmlspecialcharsbx($info["MODULE_ID"]);
    ?>
"><?php 
    echo $info["MODULE_VERSION"];
    ?>
</td>
		<td nowrap><?php 
    echo CDatabase::FormatDate($info["MODULE_VERSION_DATE"], "YYYY-MM-DD HH:MI:SS", CLang::GetDateFormat("SHORT"));
    ?>
</td>
		<td nowrap><?php 
    if ($info["IsInstalled"]) {
        echo GetMessage("MOD_INSTALLED");
开发者ID:k-kalashnikov,项目名称:geekcon_new,代码行数:31,代码来源:module_admin.php

示例3: GetMessage

		$str = GetMessage("MOD_MAIN_DESCRIPTION");
		echo $str;?></td>
		<td ondblclick="<?echo htmlspecialcharsbx("DoAction(event, 'version_down', 'main')")?>" id="version_for_main">0.1</td>
		<td nowrap>xxx</td>
		<td><?php 
echo GetMessage("MOD_INSTALLED");
?>
</td>
		<td>&nbsp;</td>
	</tr>
<?
foreach($arModules as $info) :
?>
	<tr>
		<td><b><?echo htmlspecialcharsex($info["MODULE_NAME"])?></b> <?echo htmlspecialcharsex(strlen($info["MODULE_PARTNER"]) > 0? " <b><i>(".str_replace(array("#NAME#", "#URI#"), array($info["MODULE_PARTNER"], $info["MODULE_PARTNER_URI"]), GetMessage("MOD_PARTNER_NAME")).")</i></b>" : "(".$info["MODULE_ID"].")") ?><br><?echo $info["MODULE_DESCRIPTION"]?></td>
		<td ondblclick="<?echo htmlspecialcharsbx("DoAction(event, 'version_down', '".CUtil::AddSlashes($info["MODULE_ID"])."')")?>" id="version_for_<?echo htmlspecialcharsbx($info["MODULE_ID"])?>"><?echo $info["MODULE_VERSION"]?></td>
		<td nowrap><?echo CDatabase::FormatDate($info["MODULE_VERSION_DATE"], "YYYY-MM-DD HH:MI:SS", CLang::GetDateFormat("SHORT"));?></td>
		<td nowrap><?if($info["IsInstalled"]):?><?echo GetMessage("MOD_INSTALLED")?><?else:?><span class="required"><?echo GetMessage("MOD_NOT_INSTALLED")?></span><?endif?></td>
		<td>
			<form action="<?echo $APPLICATION->GetCurPage()?>" method="GET" id="form_for_<?echo htmlspecialcharsbx($info["MODULE_ID"])?>">
				<input type="hidden" name="action" value="" id="action_for_<?echo htmlspecialcharsbx($info["MODULE_ID"])?>">
				<input type="hidden" name="lang" value="<?echo LANG?>">
				<input type="hidden" name="id" value="<?echo htmlspecialcharsbx($info["MODULE_ID"])?>">
				<?php 
echo freetrix_sessid_post();
?>
				<?if($info["IsInstalled"]):?>
					<input <?if (!$isAdmin || $info["MODULE_ID"] == 'fileman' || $info["MODULE_ID"] == 'intranet') echo "disabled" ?> type="submit" name="uninstall" value="<?echo GetMessage("MOD_DELETE")?>">
				<?else:?>
					<input <?if (!$isAdmin) echo "disabled" ?> type="submit" class="adm-btn-green" name="install" value="<?echo GetMessage("MOD_INSTALL_BUTTON")?>">
				<?endif?>
开发者ID:ASDAFF,项目名称:open_bx,代码行数:31,代码来源:module_admin.php

示例4: OnAdminListDisplay

 public static function OnAdminListDisplay(&$obList)
 {
     global $USER;
     if ($obList->table_id !== "tbl_fileman_admin") {
         return;
     }
     if (!is_object($USER) || !$USER->CanDoOperation("clouds_upload")) {
         return;
     }
     static $clouds = null;
     if (!isset($clouds)) {
         $clouds = array();
         $rsClouds = CCloudStorageBucket::GetList(array("SORT" => "DESC", "ID" => "ASC"));
         while ($arStorage = $rsClouds->Fetch()) {
             if ($arStorage["READ_ONLY"] == "N" && $arStorage["ACTIVE"] == "Y") {
                 $clouds[$arStorage["ID"]] = $arStorage["BUCKET"];
             }
         }
     }
     if (empty($clouds)) {
         return;
     }
     foreach ($obList->aRows as $obRow) {
         if ($obRow->arRes["TYPE"] === "F") {
             $ID = "F" . $obRow->arRes["NAME"];
             $file = $obRow->arRes["NAME"];
             $path = substr($obRow->arRes["ABS_PATH"], 0, -strlen($file));
             $arSubMenu = array();
             foreach ($clouds as $id => $bucket) {
                 $arSubMenu[] = array("TEXT" => $bucket, "ACTION" => $s = "if(confirm('" . GetMessage("CLO_STORAGE_UPLOAD_CONF") . "')) jsUtils.Redirect([], '" . CUtil::AddSlashes("/bitrix/admin/clouds_file_list.php?lang=" . LANGUAGE_ID . "&bucket=" . urlencode($id) . "&path=" . urlencode($path) . "&ID=" . urlencode($ID) . "&action=upload&" . bitrix_sessid_get()) . "');");
             }
             $obRow->aActions[] = array("TEXT" => GetMessage("CLO_STORAGE_UPLOAD_MENU"), "MENU" => $arSubMenu);
         }
     }
 }
开发者ID:rasuldev,项目名称:torino,代码行数:35,代码来源:storage.php

示例5: GenerateInput

	public static function GenerateInput($id, $arInfo, $curVal=false, $context='default')
	{
		$res = '<input type="checkbox" id="'.htmlspecialcharsbx('ACT_'.$id).'" '.($curVal===false?'':'checked').' name="'.htmlspecialcharsbx('OPTIONS['.$context.']['.$id.']').'" value="Y" title="'.GetMessage("CTRLR_GRP_REASSIGN").
			'" onclick="'.htmlspecialcharsbx('document.getElementById(\''.CUtil::AddSlashes($id).'\').disabled=!this.checked;if(this.checked)document.getElementById(\''.CUtil::AddSlashes($id).'\').focus();').'">';
		if($curVal===false)
			$strDis = ' disabled ';
		else
			$strDis = '';

		$arInput = $arInfo[2];
		if($arInput[0]=='checkbox')
		{
			$res .= '<select name="'.htmlspecialcharsbx('OPTIONS['.$context.']['.$id.']').'" id="'.htmlspecialcharsbx($id).'"'.$strDis.'>'.
			'<option value="N">'.GetMessage("CTRLR_GRP_OPT_NO").'</option>'.
			'<option value="Y"'.($curVal!==false && $curVal=='Y'?' selected':'').'>'.GetMessage("CTRLR_GRP_OPT_YES").'</option>'.
			'</select>';
		}
		elseif($arInput[0]=='text')
		{
			$res .= '<input type="text" name="'.htmlspecialcharsbx('OPTIONS['.$context.']['.$id.']').'" '.$strDis.'id="'.htmlspecialcharsbx($id).
				'" size="'.htmlspecialcharsbx($arInput[1]).'" value="'.htmlspecialcharsbx($curVal===false?$arInput[2]:$curVal).'">';
		}
		elseif($arInput[0]=='selectbox')
		{
			$res .= '<select name="'.htmlspecialcharsbx('OPTIONS['.$context.']['.$id.']').'" '.$strDis.'id="'.htmlspecialcharsbx($id).'">';
			foreach($arInput[1] as $enum_id => $enum_value)
			{
				$res .= '<option value="'.htmlspecialcharsbx($enum_id).'"'.
					($curVal!==false && $curVal==$enum_id?' selected':'').
					'>'.htmlspecialcharsEx($enum_value).'</option>';
			}
			$res .= '</select>';
		}
		elseif($arInput[0]=="textarea")
		{
			$res .= '<br><textarea rows="'.htmlspecialcharsbx($arInput[1]).'" cols="'.htmlspecialcharsbx($arInput[2]).'" name="'.htmlspecialcharsbx('OPTIONS['.$context.']['.$id.']').'" '.$strDis.' id="'.htmlspecialcharsbx($id).'">'.htmlspecialcharsbx($curVal===false? $arInput[3]: $curVal).'</textarea>';
		}

		return $res;
	}
开发者ID:ASDAFF,项目名称:bxApiDocs,代码行数:40,代码来源:controllergroup.php

示例6: htmlspecialcharsbx

		}
		if ($safe_for_html)
		{
			$name = htmlspecialcharsbx($name);
			$description = htmlspecialcharsbx($description);
		}
	}
}

/***************************************************************************
							Обработка GET | POST
****************************************************************************/
$arrUsers = array();
$TICKET_LIST_URL = strlen($TICKET_LIST_URL)>0? CUtil::AddSlashes(htmlspecialcharsbx((substr($TICKET_LIST_URL, 0, 4) == 'http'?'':'/').$TICKET_LIST_URL)) : "ticket_list.php";
$TICKET_EDIT_URL = strlen($TICKET_EDIT_URL)>0? CUtil::AddSlashes(htmlspecialcharsbx((substr($TICKET_EDIT_URL, 0, 4) == 'http'?'':'/').$TICKET_EDIT_URL)) : "ticket_edit.php";
$TICKET_MESSAGE_EDIT_URL = strlen($TICKET_MESSAGE_EDIT_URL)>0? CUtil::AddSlashes(htmlspecialcharsbx((substr($TICKET_MESSAGE_EDIT_URL, 0, 4) == 'http'?'':'/').$TICKET_MESSAGE_EDIT_URL)) : "ticket_message_edit.php";

if (strlen($tf)<=0)
{
	$tf = ${COption::GetOptionString("main", "cookie_name", "BITRIX_SM")."_TICKET_FILTER"};
}
if (strlen($tf)<=0)
{
	$tf = "none";
}



$sTableID = "t_ticket_list";

if ($bADS)
开发者ID:ASDAFF,项目名称:bitrix-5,代码行数:31,代码来源:ticket_list.php

示例7: empty

    echo empty($str_MESSAGE) ? 'style="display: none;"' : '';
    ?>
>
				<td>&nbsp;</td>
				<td>
					<?php 
    $arEmailFromList = \Bitrix\Sender\MailingChainTable::getEmailFromList();
    ?>
					<?php 
    echo GetMessage("sender_chain_edit_field_email_from_last");
    ?>
					<?php 
    foreach ($arEmailFromList as $email) {
        ?>
					<a class="sender-link-email" onclick="SetAddressToControl('EMAIL_FROM', '<?php 
        echo CUtil::AddSlashes(htmlspecialcharsbx($email));
        ?>
')">
						<?php 
        echo htmlspecialcharsbx($email);
        ?>
						</a><?php 
        echo end($arEmailFromList) == $email ? '' : ',';
        ?>
					<?php 
    }
    ?>
				</td>
			</tr>

			<tr class="hidden-when-show-template-list" <?php 
开发者ID:mrdeadmouse,项目名称:u136006,代码行数:31,代码来源:mailing_wizard.php

示例8: GetFinderItemStructureItem

    private static function GetFinderItemStructureItem($arParams, $arItem)
    {
        $arResult['PROVIDER'] = CUtil::AddSlashes($arParams['PROVIDER']);
        $arResult['ID'] = CUtil::AddSlashes($arItem['ID']);
        $arResult['AVATAR'] = CUtil::AddSlashes($arItem['AVATAR']);
        $arResult['NAME'] = htmlspecialcharsEx($arItem['NAME']);
        $arResult['DESC'] = empty($arItem['DESC']) ? '&nbsp;' : htmlspecialcharsEx($arItem['DESC']);
        $html = '<a href="#' . $arResult['ID'] . '" class="bx-finder-company-department-employee bx-finder-element" rel="' . $arResult['ID'] . '" onclick="return BX.Finder.onAddItem(\'' . $arResult['PROVIDER'] . '\', \'structure\', this, \'' . $arResult['ID'] . '\')" hidefocus="true">
						<div class="bx-finder-company-department-employee-icon"></div>
						<div class="bx-finder-company-department-employee-info">
							<div class="bx-finder-company-department-employee-name">' . $arResult['NAME'] . '</div>
							<div class="bx-finder-company-department-employee-position">' . $arResult['DESC'] . '</div>
						</div>
						<div style="' . (strlen($arResult['AVATAR']) > 0 ? 'background:url(\'' . $arResult['AVATAR'] . '\') no-repeat center center' : '') . '" class="bx-finder-company-department-employee-avatar"></div>
					</a>';
        return $html;
    }
开发者ID:k-kalashnikov,项目名称:geekcon_new,代码行数:17,代码来源:finder.php

示例9: GetMessage

					<span class="adm-fn"><?=GetMessage('sender_chain_edit_field_email_from_desc')?></span>
				</td>
				<td>
					<input type="text" id="EMAIL_FROM" name="EMAIL_FROM" value="<?=$str_EMAIL_FROM?>">
				</td>
			</tr>

			<tr class="hidden-when-show-template-list" <?=(empty($str_MESSAGE) ? 'style="display: none;"' : '')?>>
				<td>&nbsp;</td>
				<td>
					<?
					$arEmailFromList = \Bitrix\Sender\MailingChainTable::getEmailFromList();
					?>
					<?echo GetMessage("sender_chain_edit_field_email_from_last")?>
					<?foreach($arEmailFromList as $email):?>
					<a class="sender-link-email" onclick="SetAddressToControl('EMAIL_FROM', '<?=CUtil::AddSlashes(htmlspecialcharsbx($email))?>')">
						<?=htmlspecialcharsbx($email)?>
						</a><?=(end($arEmailFromList)==$email ? '' : ',')?>
					<?endforeach?>
				</td>
			</tr>

			<tr class="hidden-when-show-template-list" <?=(empty($str_MESSAGE) ? 'style="display: none;"' : '')?>>
				<td colspan="2">&nbsp;</td>
			</tr>

			<tr class="adm-detail-required-field hidden-when-show-template-list" <?=(empty($str_MESSAGE) ? 'style="display: none;"' : '')?>>
				<td colspan="2" align="left">
					<div class="adm-detail-content-item-block">
						<span class="adm-detail-content-item-block-span"><?=GetMessage("sender_chain_edit_field_message")?></span>
						<?=\Bitrix\Sender\TemplateTable::initEditor(array(
开发者ID:nycmic,项目名称:bittest,代码行数:31,代码来源:mailing_wizard.php


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