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


PHP validHtmlStr函数代码示例

本文整理汇总了PHP中validHtmlStr函数的典型用法代码示例。如果您正苦于以下问题:PHP validHtmlStr函数的具体用法?PHP validHtmlStr怎么用?PHP validHtmlStr使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


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

示例1: outputImageStreamModern

function outputImageStreamModern($id, $src, $width, $height, $title = "")
{
    ?>
  <img id="<?php 
    echo $id;
    ?>
" class="monitor-stream-image" src="<?php 
    echo $src;
    ?>
" alt="<?php 
    echo validHtmlStr($title);
    ?>
" width="<?php 
    echo $width;
    ?>
" height="<?php 
    echo $height;
    ?>
" onerror="imgError(this);">
  <?php 
}
开发者ID:OverByThere,项目名称:modern,代码行数:21,代码来源:framefetcher.php

示例2: xhtmlHeaders

function xhtmlHeaders($file, $title)
{
    $skinCssFile = getSkinFile('css/skin.css');
    $skinCssPhpFile = getSkinFile('css/skin.css.php');
    $skinJsFile = getSkinFile('js/skin.js');
    $skinJsPhpFile = getSkinFile('js/skin.js.php');
    $basename = basename($file, '.php');
    $viewCssFile = getSkinFile('views/css/' . $basename . '.css');
    $viewCssPhpFile = getSkinFile('views/css/' . $basename . '.css.php');
    $viewJsFile = getSkinFile('views/js/' . $basename . '.js');
    $viewJsPhpFile = getSkinFile('views/js/' . $basename . '.js.php');
    extract($GLOBALS, EXTR_OVERWRITE);
    ?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
 <title><?php 
    echo ZM_WEB_TITLE_PREFIX;
    ?>
 - <?php 
    echo validHtmlStr($title);
    ?>
</title>
 <link rel="icon" type="image/ico" href="graphics/favicon.ico"/>
 <link rel="shortcut icon" href="graphics/favicon.ico"/>
 <link rel="stylesheet" href="css/reset.css" type="text/css"/>
 <link rel="stylesheet" href="<?php 
    echo $skinCssFile;
    ?>
" type="text/css" media="screen"/>
 <link rel="stylesheet" href="skins/modern/css/header.css" type="text/css" media="screen"/>
<?php 
    if ($title != 'Zone' && !preg_match("/Feed/", $title)) {
        ?>
 <script type="text/javascript" src="skins/modern/js/jquery-1.4.2.min.js"></script>
 <script type="text/javascript" src="skins/modern/js/jquery-ui-1.8.4.custom.min.js"></script>
<?php 
    }
    ?>
 <link type="text/css" media="screen" rel="stylesheet" href="skins/modern/css/colorbox.css"></link>
 <link type="text/css" media="screen" rel="stylesheet" href="skins/modern/css/jquery/jquery-ui-1.8.custom.css"></link>
<?php 
    if ($title == "Console") {
        ?>
 <script type="text/javascript" src="skins/modern/js/jquery.colorbox.js"></script>
 <script type="text/javascript" src="skins/modern/js/console.colorbox.js"></script>
 <script type="text/javascript" src="skins/modern/js/console.js"></script>
<script type="text/javascript" src="tools/mootools/mootools-core-1.3.2-nc.js"></script>
<script type="text/javascript" src="tools/mootools/mootools-more-1.3.2.1-nc.js"></script>
<?php 
    }
    if ($title == "Monitor") {
        ?>
<script type="text/javascript" src="tools/mootools/mootools-core-1.3.2-nc.js"></script>
<script type="text/javascript" src="tools/mootools/mootools-more-1.3.2.1-nc.js"></script>
  <script type="text/javascript" src="js/mootools.ext.js"></script>
<?php 
    }
    ?>


<?php 
    if ($title == "System Log") {
        ?>
<script type="text/javascript">var $j = jQuery.noConflict();</script>
<script type="text/javascript" src="tools/mootools/mootools-core-1.3.2-nc.js"></script>
<script type="text/javascript" src="tools/mootools/mootools-more-1.3.2.1-nc.js"></script>
  <script type="text/javascript" src="js/mootools.ext.js"></script>
<?php 
    }
    ?>




<?php 
    if ($title == "Zone") {
        ?>
<script type="text/javascript" src="tools/mootools/mootools-core-1.3.2-nc.js"></script>
<script type="text/javascript" src="tools/mootools/mootools-more-1.3.2.1-nc.js"></script>
  <script type="text/javascript" src="js/mootools.ext.js"></script> 
<?php 
    }
    ?>



<?php 
    if (preg_match("/Feed/", $title)) {
        ?>
  <link media="screen" type="text/css" href="skins/classic/views/css/watch.css" rel="stylesheet">
<script type="text/javascript" src="tools/mootools/mootools-core-1.3.2-nc.js"></script>
<script type="text/javascript" src="tools/mootools/mootools-more-1.3.2.1-nc.js"></script>
<?php 
    }
    if ($title == "Admin") {
        ?>
  <script type="text/javascript" src="skins/modern/js/admin.js"></script>
  <script type="text/javascript" src="skins/modern/js/jquery.colorbox.js"></script>
<?php 
//.........这里部分代码省略.........
开发者ID:mondychan,项目名称:modern,代码行数:101,代码来源:functions.php

示例3: makePopupLink

    ?>
            <tr>
              <td class="colId"><?php 
    echo makePopupLink('?view=event&amp;eid=' . $event['Id'] . $filterQuery . $sortQuery . '&amp;page=1', 'zmEvent', array('event', reScale($event['Width'], $scale), reScale($event['Height'], $scale)), $event['Id'] . ($event['Archived'] ? '*' : ''));
    ?>
</td>
              <td class="colName"><?php 
    echo makePopupLink('?view=event&amp;eid=' . $event['Id'] . $filterQuery . $sortQuery . '&amp;page=1', 'zmEvent', array('event', reScale($event['Width'], $event['DefaultScale'], ZM_WEB_DEFAULT_SCALE), reScale($event['Height'], $event['DefaultScale'], ZM_WEB_DEFAULT_SCALE)), validHtmlStr($event['Name']) . ($event['Archived'] ? '*' : ''));
    ?>
</td>
              <td class="colMonitorName"><?php 
    echo $event['MonitorName'];
    ?>
</td>
              <td class="colCause"><?php 
    echo makePopupLink('?view=eventdetail&amp;eid=' . $event['Id'], 'zmEventDetail', 'eventdetail', validHtmlStr($event['Cause']), canEdit('Events'), 'title="' . htmlspecialchars($event['Notes']) . '"');
    ?>
</td>
              <td class="colTime"><?php 
    echo strftime(STRF_FMT_DATETIME_SHORTER, strtotime($event['StartTime']));
    ?>
</td>
              <td class="colDuration"><?php 
    echo gmdate("H:i:s", $event['Length']);
    ?>
</td>
              <td class="colFrames"><?php 
    echo makePopupLink('?view=frames&amp;eid=' . $event['Id'], 'zmFrames', 'frames', $event['Frames']);
    ?>
</td>
              <td class="colAlarmFrames"><?php 
开发者ID:rodoviario,项目名称:ZoneMinder,代码行数:31,代码来源:events.php

示例4: translate

</td>
              <td class="colIds"><?php 
echo translate('All');
?>
</td>
              <td class="colSelect"><input type="radio" name="gid" value="0"<?php 
echo !$selected ? ' checked="checked"' : '';
?>
 onclick="configureButtons( this );"/></td>
            </tr>
<?php 
foreach ($groups as $group) {
    ?>
            <tr>
              <td class="colName"><?php 
    echo validHtmlStr($group['Name']);
    ?>
</td>
              <td class="colIds"><?php 
    echo monitorIdsToNames($group['MonitorIds'], 30);
    ?>
</td>
              <td class="colSelect"><input type="radio" name="gid" value="<?php 
    echo $group['Id'];
    ?>
"<?php 
    echo $group['selected'] ? ' checked="checked"' : '';
    ?>
 onclick="configureButtons( this );"/></td>
            </tr>
<?php 
开发者ID:ralfoide,项目名称:ZoneMinder,代码行数:31,代码来源:groups.php

示例5: dbFetchAll

$monitors = dbFetchAll("select Id,Name from Monitors order by Sequence asc");
$monitorIds = array_flip(explode(',', $newGroup['MonitorIds']));
foreach ($monitors as $monitor) {
    if (visibleMonitor($monitor['Id'])) {
        ?>
                  <option value="<?php 
        echo $monitor['Id'];
        ?>
"<?php 
        if (array_key_exists($monitor['Id'], $monitorIds)) {
            ?>
 selected="selected"<?php 
        }
        ?>
><?php 
        echo validHtmlStr($monitor['Name']);
        ?>
</option>
<?php 
    }
}
?>
                </select>
              </td>
            </tr>
          </tbody>
        </table>
        <div id="contentButtons">
          <input type="submit" value="<?php 
echo translate('Save');
?>
开发者ID:rodoviario,项目名称:ZoneMinder,代码行数:31,代码来源:group.php

示例6: elseif

</td>
<?php 
        } elseif ($_REQUEST['filter']['terms'][$i]['attr'] == "Date") {
            ?>
              <td><?php 
            echo buildSelect("filter[terms][{$i}][op]", $opTypes);
            ?>
</td>
              <td><input name="filter[terms][<?php 
            echo $i;
            ?>
][val]" id="filter[terms][<?php 
            echo $i;
            ?>
][val]" value="<?php 
            echo isset($_REQUEST['filter']['terms'][$i]['val']) ? validHtmlStr($_REQUEST['filter']['terms'][$i]['val']) : '';
            ?>
"/><?php 
            if ($hasCal) {
                ?>
<script type="text/javascript">Calendar.setup( { inputField: "filter[terms][<?php 
                echo $i;
                ?>
][val]", ifFormat: "%Y-%m-%d", showOthers: true, weekNumbers: false });</script><?php 
            }
            ?>
</td>
<?php 
        } elseif ($_REQUEST['filter']['terms'][$i]['attr'] == "Weekday") {
            ?>
              <td><?php 
开发者ID:rodoviario,项目名称:ZoneMinder,代码行数:31,代码来源:filter.php

示例7: parseFilterToTree

if (isset($_REQUEST['filter'])) {
    $tree = parseFilterToTree($_REQUEST['filter']);
} else {
    $tree = false;
}
if (isset($_REQUEST['range'])) {
    $range = validHtmlStr($_REQUEST['range']);
}
if (isset($_REQUEST['minTime'])) {
    $minTime = validHtmlStr($_REQUEST['minTime']);
}
if (isset($_REQUEST['midTime'])) {
    $midTime = validHtmlStr($_REQUEST['midTime']);
}
if (isset($_REQUEST['maxTime'])) {
    $maxTime = validHtmlStr($_REQUEST['maxTime']);
}
if (isset($range)) {
    $halfRange = (int) ($range / 2);
    if (isset($midTime)) {
        $midTimeT = strtotime($midTime);
        $minTimeT = $midTimeT - $halfRange;
        $maxTimeT = $midTimeT + $halfRange;
        if (!($range % 1)) {
            $maxTimeT--;
        }
        $minTime = strftime(STRF_FMT_DATETIME_DB, $minTimeT);
        $maxTime = strftime(STRF_FMT_DATETIME_DB, $maxTimeT);
    } elseif (isset($minTime)) {
        $minTimeT = strtotime($minTime);
        $maxTimeT = $minTimeT + $range;
开发者ID:moeiscool,项目名称:ZoneMinder-video,代码行数:31,代码来源:timeline.php

示例8: translate

            ?>
" size="10" onchange="$('SignalCheckSwatch').setStyle( 'backgroundColor', this.value )"/><span id="SignalCheckSwatch" class="swatch" style="background-color: <?php 
            echo $newMonitor['SignalCheckColour'];
            ?>
;">&nbsp;&nbsp;&nbsp;&nbsp;</span></td></tr>
<?php 
        }
        ?>
            <tr><td><?php 
        echo translate('WebColour');
        ?>
</td><td><input type="text" name="newMonitor[WebColour]" value="<?php 
        echo validHtmlStr($newMonitor['WebColour']);
        ?>
" size="10" onchange="$('WebSwatch').setStyle( 'backgroundColor', this.value )"/><span id="WebSwatch" class="swatch" style="background-color: <?php 
        echo validHtmlStr($newMonitor['WebColour']);
        ?>
;">&nbsp;&nbsp;&nbsp;&nbsp;</span></td></tr>
<?php 
        break;
}
?>
          </tbody>
        </table>
        <div id="contentButtons">
          <input type="submit" value="<?php 
echo translate('Save');
?>
"<?php 
if (!canEdit('Monitors')) {
    ?>
开发者ID:jbudding,项目名称:ZoneMinder,代码行数:31,代码来源:monitor.php

示例9: validHtmlStr

    echo $_REQUEST['generated'] ? 'infoText' : 'errorText';
    ?>
"><span id="exportProgressText"><?php 
    echo $_REQUEST['generated'] ? $SLANG['ExportSucceeded'] : $SLANG['ExportFailed'];
    ?>
</span><span id="exportProgressTicker"></span></h2>
<?php 
} else {
    ?>
      <h2 id="exportProgress" class="hidden warnText"><span id="exportProgressText"><?php 
    echo $SLANG['Exporting'];
    ?>
</span><span id="exportProgressTicker"></span></h2>
<?php 
}
if (!empty($_REQUEST['generated'])) {
    ?>
      <h3 id="downloadLink"><a href="<?php 
    echo validHtmlStr($_REQUEST['exportFile']);
    ?>
"><?php 
    echo $SLANG['Download'];
    ?>
</a></h3>
<?php 
}
?>
  </div>
</body>
</html>
开发者ID:moeiscool,项目名称:ZoneMinder-video,代码行数:30,代码来源:export.php

示例10: dbFetchMonitor

// along with this program; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
//
if (!canEdit('Monitors')) {
    $view = "error";
    return;
}
$monitor = dbFetchMonitor($_REQUEST['mid']);
$focusWindow = true;
xhtmlHeaders(__FILE__, $SLANG['Function'] . " - " . validHtmlStr($monitor['Name']));
?>
<body>
  <div id="page">
    <div id="header">
      <h2><?php 
echo $SLANG['Function'] . " - " . validHtmlStr($monitor['Name']);
?>
</h2>
    </div>
    <div id="content">
      <form name="contentForm" id="contentForm" method="post" action="<?php 
echo $_SERVER['PHP_SELF'];
?>
">
        <input type="hidden" name="view" value="none"/>
        <input type="hidden" name="action" value="function"/>
        <input type="hidden" name="mid" value="<?php 
echo $monitor['Id'];
?>
"/>
        <p>
开发者ID:mondychan,项目名称:modern,代码行数:31,代码来源:function.php

示例11: xhtmlHeaders

$focusWindow = true;
xhtmlHeaders(__FILE__, $SLANG['OptionHelp']);
?>
<body>
  <div id="page">
    <div id="header">
      <div id="headerButtons">
        <a href="#" onclick="closeWindow();"><?php 
echo $SLANG['Close'];
?>
</a>
      </div>
      <h2><?php 
echo $SLANG['OptionHelp'];
?>
</h2>
    </div>
    <div id="content">
      <h3><?php 
echo validHtmlStr($_REQUEST['option']);
?>
</h3>
      <p class="textblock"><?php 
echo validHtmlStr($optionHelpText);
?>
</p>
    </div>
  </div>
</body>
</html>
开发者ID:mondychan,项目名称:modern,代码行数:30,代码来源:optionhelp.php

示例12: validateForm

    </div>
    <div id="content">
      <form name="contentForm" method="post" action="<?php 
echo $_SERVER['PHP_SELF'];
?>
" onsubmit="return validateForm( this, <?php 
echo empty($newUser['Password']) ? 'true' : 'false';
?>
 )">
        <input type="hidden" name="view" value="<?php 
echo $view;
?>
"/>
        <input type="hidden" name="action" value="user"/>
        <input type="hidden" name="uid" value="<?php 
echo validHtmlStr($_REQUEST['uid']);
?>
"/>
        <input type="hidden" name="newUser[MonitorIds]" value="<?php 
echo $newUser['MonitorIds'];
?>
"/>
        <table id="contentTable" class="major" cellspacing="0">
          <tbody>
<?php 
if (canEdit('System')) {
    ?>
            <tr>
              <th scope="row"><?php 
    echo translate('Username');
    ?>
开发者ID:rodoviario,项目名称:ZoneMinder,代码行数:31,代码来源:user.php

示例13: array

" size="24"/></td></tr>
<?php 
        $types = array('Local' => $SLANG['Local'], 'Remote' => $SLANG['Remote'], 'Ffmpeg' => $SLANG['Ffmpeg'], 'Libvlc' => $SLANG['Libvlc'], 'cURL' => "cURL");
        ?>
            <tr><th scope="row"><?php 
        echo $SLANG['Type'];
        ?>
</th><td><?php 
        echo buildSelect("newControl[Type]", $types);
        ?>
</td></tr>
            <tr><th scope="row"><?php 
        echo $SLANG['Protocol'];
        ?>
</th><td><input type="text" name="newControl[Protocol]" value="<?php 
        echo validHtmlStr($newControl['Protocol']);
        ?>
" size="24"/></td></tr>
            <tr><th scope="row"><?php 
        echo $SLANG['CanWake'];
        ?>
</th><td><input type="checkbox" name="newControl[CanWake]" value="1"<?php 
        if (!empty($newControl['CanWake'])) {
            ?>
 checked="checked"<?php 
        }
        ?>
/></td></tr>
            <tr><th scope="row"><?php 
        echo $SLANG['CanSleep'];
        ?>
开发者ID:moeiscool,项目名称:ZoneMinder-video,代码行数:31,代码来源:controlcap.php

示例14: outputVideoStream

    ?>
', 'watch', <?php 
    echo $monitor->scaleWidth();
    ?>
, <?php 
    echo $monitor->scaleHeight();
    ?>
 );">
<?php 
    if (ZM_WEB_STREAM_METHOD == 'mpeg' && ZM_MPEG_LIVE_FORMAT) {
        $streamSrc = $monitor->getStreamSrc(array("mode=mpeg", "scale=" . $scale, "bitrate=" . ZM_WEB_VIDEO_BITRATE, "maxfps=" . ZM_WEB_VIDEO_MAXFPS, "format=" . ZM_MPEG_LIVE_FORMAT));
        outputVideoStream("liveStream" . $monitor->Id(), $streamSrc, reScale($monitor->Width(), $scale), reScale($monitor->Height(), $scale), ZM_MPEG_LIVE_FORMAT);
    } else {
        $streamSrc = $monitor->getStreamSrc(array("mode=jpeg", "scale=" . $scale, "maxfps=" . ZM_WEB_VIDEO_MAXFPS));
        if (canStreamNative()) {
            outputImageStream("liveStream" . $monitor->Id(), $streamSrc, reScale($monitor->Width(), $scale), reScale($monitor->Height(), $scale), validHtmlStr($monitor->Name()));
        } else {
            outputHelperStream("liveStream" . $monitor->Id(), $streamSrc, reScale($monitor->Width(), $scale), reScale($monitor->Height(), $scale));
        }
    }
    ?>
            </div>
<?php 
    if (!ZM_WEB_COMPACT_MONTAGE) {
        ?>
            <div id="monitorState<?php 
        echo $monitor->index();
        ?>
" class="monitorState idle"><?php 
        echo translate('State');
        ?>
开发者ID:schrorg,项目名称:ZoneMinder,代码行数:31,代码来源:montage.php

示例15: validHtmlStr

              <th scope="row"><?php 
echo $SLANG['Name'];
?>
</th>
              <td><input type="text" name="newDevice[Name]" value="<?php 
echo validHtmlStr($newDevice['Name']);
?>
"/></td>
            </tr>
            <tr>
              <th scope="row"><?php 
echo $SLANG['KeyString'];
?>
</th>
              <td><input type="text" name="newDevice[KeyString]" value="<?php 
echo validHtmlStr($newDevice['KeyString']);
?>
"/></td>
            </tr>
          </tbody>
        </table>
        <div id="contentButtons">
          <input type="submit" value="<?php 
echo $SLANG['Save'];
?>
"<?php 
if (!canEdit('Devices')) {
    ?>
 disabled="disabled"<?php 
}
?>
开发者ID:moeiscool,项目名称:ZoneMinder-video,代码行数:31,代码来源:device.php


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