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


PHP form_value函数代码示例

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


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

示例1: tpl_content

function tpl_content()
{
    global $page, $webimroot;
    ?>

<?php 
    echo getlocal("page.preview.intro");
    ?>
<br />
<br />

<form name="preview" method="get" action="<?php 
    echo $webimroot;
    ?>
/operator/themes.php">
	<div>
<?php 
    print_tabbar();
    ?>
	<div class="mform"><div class="formtop"><div class="formtopi"></div></div><div class="forminner">

	<div class="fieldForm">
		<div class="field">
			<div class="flabel"><?php 
    echo getlocal("page.preview.choose");
    ?>
</div>
			<div class="fvaluenodesc">
				<select name="preview" onchange="this.form.submit();"><?php 
    foreach ($page['availablePreviews'] as $k) {
        echo "<option value=\"" . $k . "\"" . ($k == form_value("preview") ? " selected=\"selected\"" : "") . ">" . $k . "</option>";
    }
    ?>
</select>
			</div>
		</div>
		<div class="field">
			<div class="flabel"><?php 
    echo getlocal("page.preview.choosetpl");
    ?>
</div>
			<div class="fvaluenodesc">
				<select name="template" onchange="this.form.submit();"><?php 
    foreach ($page['availableTemplates'] as $k) {
        echo "<option value=\"" . $k . "\"" . ($k == form_value("template") ? " selected=\"selected\"" : "") . ">" . $k . "</option>";
    }
    ?>
</select>
			</div>
		</div>
<?php 
    if ($page['canshowerrors']) {
        ?>
		<div class="field">
			<div class="flabel"><?php 
        echo getlocal("page.preview.showerr");
        ?>
</div>
			<div class="fvaluenodesc">
				<input type="checkbox" name="showerr" value="on"<?php 
        echo form_value_cb('showerr') ? " checked=\"checked\"" : "";
        ?>
 onchange="this.form.submit();"/>
			</div>
		</div>
<?php 
    }
    foreach ($page['previewList'] as $pp) {
        ?>
		<div class="field">
			<div class="flabel">
			<?php 
        echo htmlspecialchars($pp['label']);
        ?>
			<a href="<?php 
        echo $page['showlink'];
        echo $pp['id'];
        ?>
" target="_blank" title="in separate window" onclick="this.newWindow = window.open('<?php 
        echo $page['showlink'];
        echo $pp['id'];
        ?>
', '<?php 
        echo $pp['id'];
        ?>
', 'toolbar=0,scrollbars=0,location=0,statusbar=1,menubar=0,width=<?php 
        echo $pp['w'];
        ?>
,height=<?php 
        echo $pp['h'];
        ?>
,resizable=1');this.newWindow.focus();this.newWindow.opener=window;return false;">link</a>
			</div>
			<div class="fvalueframe">
			<iframe id="sample<?php 
        echo $pp['id'];
        ?>
" width="<?php 
        echo $pp['w'];
        ?>
//.........这里部分代码省略.........
开发者ID:paulcn,项目名称:mibew,代码行数:101,代码来源:themes.php

示例2: tpl_content

function tpl_content()
{
    global $page, $webimroot;
    ?>

<?php 
    echo getlocal("page.translate.descr");
    ?>
<br />
<br />

<form name="translateForm" method="get" action="<?php 
    echo $webimroot;
    ?>
/operator/translate.php">
	
	<div class="mform"><div class="formtop"><div class="formtopi"></div></div><div class="forminner">

	<div class="packedFormField">
		<?php 
    echo getlocal("translate.direction");
    ?>
<br/>
		<select name="source" onchange="this.form.submit();"><?php 
    foreach ($page['availableLocales'] as $k) {
        echo "<option value=\"" . $k["id"] . "\"" . ($k["id"] == form_value("source") ? " selected=\"selected\"" : "") . ">" . $k["name"] . "</option>";
    }
    ?>
</select>
		=&gt;
		<select name="target" onchange="this.form.submit();"><?php 
    foreach ($page['availableLocales'] as $k) {
        echo "<option value=\"" . $k["id"] . "\"" . ($k["id"] == form_value("target") ? " selected=\"selected\"" : "") . ">" . $k["name"] . "</option>";
    }
    ?>
</select>
	</div>
	
	<div class="packedFormField">
		<?php 
    echo getlocal("translate.sort");
    ?>
<br/>
		<select name="sort" onchange="this.form.submit();"><?php 
    foreach ($page['availableOrders'] as $k) {
        echo "<option value=\"" . $k["id"] . "\"" . ($k["id"] == form_value("sort") ? " selected=\"selected\"" : "") . ">" . $k["name"] . "</option>";
    }
    ?>
</select>
	</div>
	
	<div class="packedFormField">
		<?php 
    echo getlocal("translate.show");
    ?>
<br/>
		<select name="show" onchange="this.form.submit();"><?php 
    foreach ($page['showOptions'] as $k) {
        echo "<option value=\"" . $k["id"] . "\"" . ($k["id"] == form_value("show") ? " selected=\"selected\"" : "") . ">" . $k["name"] . "</option>";
    }
    ?>
</select>
	</div>
	
	<br clear="all"/>
	
	</div><div class="formbottom"><div class="formbottomi"></div></div></div>
</form>
<br/>


<?php 
    if ($page['pagination']) {
        if ($page['pagination.items']) {
            echo generate_pagination($page['pagination'], false);
        }
        ?>

<table class="translate">
<thead>
	<tr class="header"><th>
		Key
	</th><th>
		<?php 
        echo topage($page['title1']);
        ?>
	</th><th>
		<?php 
        echo topage($page['title2']);
        ?>
	</th></tr>
</thead>
<tbody>
<?php 
        if ($page['pagination.items']) {
            foreach ($page['pagination.items'] as $localstr) {
                ?>
	<tr>
		<td>
			<a href="<?php 
//.........这里部分代码省略.........
开发者ID:laiello,项目名称:cartonbank,代码行数:101,代码来源:translatelist.php

示例3: form_value

            </div>
            <div class="row">
                <input type="text" name="txtConfirmEmail" size="50" value="<?php 
echo form_value('txtConfirmEmail');
?>
" placeholder="<?php 
echo _t('Re-type your email *');
?>
" />
            </div>
            <div class="row">
                <textarea name="txaComment" rows="7" cols="60" placeholder="<?php 
echo _t('Enter comment *');
?>
"><?php 
echo form_value('txaComment');
?>
</textarea>
            </div>
            <div class="row">
                <input type="submit" name="btnSubmit" value="<?php 
echo _t('Post Comment');
?>
" class="button green" />
            </div>
        </div>
        <?php 
form_token();
?>
    </form>
    <?php 
开发者ID:phplucidframe,项目名称:phplucidframe,代码行数:31,代码来源:view.php

示例4: form_input

function form_input($type, $name, $values = array(), array $errors = array(), array $attributes = array(), $class = '')
{
    $class .= error_class($errors, $name);
    $html = '<input type="' . $type . '" name="' . $name . '" id="form-' . $name . '" ' . form_value($values, $name) . ' class="' . $class . '" ';
    $html .= implode(' ', $attributes) . '/>';
    if (in_array('required', $attributes)) {
        $html .= '<span class="form-required">*</span>';
    }
    $html .= error_list($errors, $name);
    return $html;
}
开发者ID:antonivargas,项目名称:bkpsite,代码行数:11,代码来源:helper.php

示例5: tpl_content

function tpl_content()
{
    global $page, $webimroot, $errors;
    ?>

<?php 
    echo getlocal("page.notifications.intro");
    ?>
<br />
<br />
<?php 
    require_once 'inc_errors.php';
    ?>

<form name="notifyFilterForm" method="get" action="<?php 
    echo $webimroot;
    ?>
/operator/notifications.php">
	
	<div class="mform"><div class="formtop"><div class="formtopi"></div></div><div class="forminner">

	<div class="packedFormField">
		<?php 
    echo getlocal("notifications.kind");
    ?>
<br/>
		<select name="kind" onchange="this.form.submit();"><?php 
    foreach ($page['allkinds'] as $k) {
        echo "<option value=\"" . $k . "\"" . ($k == form_value("kind") ? " selected=\"selected\"" : "") . ">" . getlocal("notifications.kind." . ($k ? $k : "all")) . "</option>";
    }
    ?>
</select>
	</div>

	<div class="packedFormField">
		<?php 
    echo getlocal("notifications.locale");
    ?>
<br/>
		<select name="lang" onchange="this.form.submit();"><?php 
    foreach ($page['locales'] as $k) {
        echo "<option value=\"" . $k["id"] . "\"" . ($k["id"] == form_value("lang") ? " selected=\"selected\"" : "") . ">" . $k["name"] . "</option>";
    }
    ?>
</select>
	</div>
	
	<br clear="all"/>
	
	</div><div class="formbottom"><div class="formbottomi"></div></div></div>
</form>
<br/>

<?php 
    if ($page['pagination']) {
        ?>

<table class="list">
<thead>
<tr class="header">
<th>
	<?php 
        echo getlocal("notifications.head.to");
        ?>
</th><th>
	<?php 
        echo getlocal("notifications.head.subj");
        ?>
</th><th>
	<?php 
        echo getlocal("notifications.head.msg");
        ?>
</th><th>
	<?php 
        echo getlocal("notifications.head.time");
        ?>
</th>
</tr>
</thead>
<tbody>
<?php 
        if ($page['pagination.items']) {
            foreach ($page['pagination.items'] as $b) {
                ?>
	<tr>
	<td class="notlast">
		<a href="<?php 
                echo $webimroot;
                ?>
/operator/notification.php?id=<?php 
                echo $b['id'];
                ?>
" target="_blank" onclick="this.newWindow = window.open('<?php 
                echo $webimroot;
                ?>
/operator/notification.php?id=<?php 
                echo $b['id'];
                ?>
', '', 'toolbar=0,scrollbars=1,location=0,status=1,menubar=0,width=720,height=520,resizable=1');this.newWindow.focus();this.newWindow.opener=window;return false;" class="<?php 
                echo $b['vckind'] == 'xmpp' ? 'xmpp' : 'mail';
//.........这里部分代码省略.........
开发者ID:paulcn,项目名称:mibew,代码行数:101,代码来源:notifications.php

示例6: tpl_content

function tpl_content()
{
    global $page, $mibewroot, $errors;
    ?>

<?php 
    if ($page['saved']) {
        ?>
	<?php 
        echo getlocal2("page_ban.sent", array(safe_htmlspecialchars($page['address'])));
        ?>

	<script type="text/javascript"><!--
		setTimeout( (function() { window.close(); }), 1500 );
	//--></script>
<?php 
    } else {
        ?>

<?php 
        echo getlocal("page_ban.intro");
        ?>
<br/>
<br/>
<?php 
        require_once 'inc_errors.php';
        ?>


<?php 
        if ($page['thread']) {
            ?>
	<?php 
            echo getlocal2("page_ban.thread", array(safe_htmlspecialchars($page['thread'])));
            ?>
<br/>
	<br/>
<?php 
        }
        ?>

<form name="banForm" method="post" action="<?php 
        echo $mibewroot;
        ?>
/operator/ban.php">
<?php 
        print_csrf_token_input();
        ?>
<input type="hidden" name="banId" value="<?php 
        echo safe_htmlspecialchars($page['banId']);
        ?>
"/>
<?php 
        if ($page['threadid']) {
            ?>
<input type="hidden" name="threadid" value="<?php 
            echo safe_htmlspecialchars($page['threadid']);
            ?>
"/>
<?php 
        }
        ?>
	<div class="mform"><div class="formtop"><div class="formtopi"></div></div><div class="forminner">
	
	<div class="fieldForm">
		<div class="field">
			<div class="flabel"><?php 
        echo getlocal('form.field.address');
        ?>
<span class="required">*</span></div>
			<div class="fvalue">
				<input type="text" name="address" size="40" value="<?php 
        echo form_value('address');
        ?>
" class="formauth"/>
			</div>
			<div class="fdescr"> &mdash; <?php 
        echo getlocal('form.field.address.description');
        ?>
</div>
			<br clear="all"/>
		</div>

		<div class="field">
			<div class="flabel"><?php 
        echo getlocal('form.field.ban_days');
        ?>
<span class="required">*</span></div>
			<div class="fvalue">
				<input type="text" name="days" size="4" value="<?php 
        echo form_value('days');
        ?>
" class="formauth"/>
			</div>
			<div class="fdescr"> &mdash; <?php 
        echo getlocal('form.field.ban_days.description');
        ?>
</div>
			<br clear="all"/>
		</div>
//.........这里部分代码省略.........
开发者ID:kuell,项目名称:chat,代码行数:101,代码来源:ban.php

示例7: tpl_content

function tpl_content()
{
    global $page, $mibewroot, $errors;
    ?>

	<?php 
    if ($page['saved']) {
        ?>
	<?php 
        echo getlocal("page.translate.done");
        ?>

	<script type="text/javascript"><!--
		if(window.opener && window.opener.location) {
			window.opener.location.reload();
		} 
		setTimeout( (function() { window.close(); }), 500 );
	//--></script>
<?php 
    }
    if (!$page['saved']) {
        ?>

<?php 
        echo getlocal("page.translate.one");
        ?>
<br/>
<br/>
<?php 
        require_once 'inc_errors.php';
        ?>

<form name="translateForm" method="post" action="<?php 
        echo $mibewroot;
        ?>
/operator/translate.php">
<?php 
        print_csrf_token_input();
        ?>
<input type="hidden" name="key" value="<?php 
        echo safe_htmlspecialchars($page['key']);
        ?>
"/>
<input type="hidden" name="target" value="<?php 
        echo safe_htmlspecialchars($page['target']);
        ?>
"/>
	<div class="mform"><div class="formtop"><div class="formtopi"></div></div><div class="forminner">

	<div class="fieldForm">
		<div class="field">
			<div class="flabel"><?php 
        echo safe_htmlspecialchars($page['title1']);
        ?>
</div>
			<div class="fvaluenodesc">
				<textarea name="original" disabled="disabled" cols="20" rows="5" class="wide"><?php 
        echo form_value('original');
        ?>
</textarea>
			</div>
		</div>

		<div class="field">
			<div class="flabel"><?php 
        echo safe_htmlspecialchars($page['title2']);
        ?>
</div>
			<div class="fvaluenodesc">
				<textarea name="translation" cols="20" rows="5" class="wide"><?php 
        echo form_value('translation');
        ?>
</textarea>
			</div>
		</div>

		<div class="fbutton">
			<input type="image" name="save" value="" src="<?php 
        echo $mibewroot . safe_htmlspecialchars(getlocal("image.button.save"));
        ?>
" alt="<?php 
        echo safe_htmlspecialchars(getlocal("button.save"));
        ?>
"/>
		</div>
	</div>

	</div><div class="formbottom"><div class="formbottomi"></div></div></div>
</form>

<?php 
    }
    ?>

<?php 
}
开发者ID:kuell,项目名称:chat,代码行数:96,代码来源:translate.php

示例8: tpl_content

function tpl_content()
{
    global $page, $webimroot, $errors;
    ?>

	<?php 
    if ($page['saved']) {
        ?>
	<?php 
        echo getlocal("cannededit.done");
        ?>

	<script><!--
		if(window.opener && window.opener.location) {
			window.opener.location.reload();
		} 
		setTimeout( (function() { window.close(); }), 500 );
	//--></script>
<?php 
    }
    if (!$page['saved']) {
        ?>

<?php 
        echo $page['key'] ? getlocal("cannededit.descr") : getlocal("cannednew.descr");
        ?>
<br/>
<br/>
<?php 
        require_once 'inc_errors.php';
        ?>

<form name="cannedForm" method="post" action="<?php 
        echo $webimroot;
        ?>
/operator/cannededit.php">
<?php 
        print_csrf_token_input();
        ?>
<input type="hidden" name="key" value="<?php 
        echo $page['key'];
        ?>
"/>
<?php 
        if (!$page['key']) {
            ?>
<input type="hidden" name="lang" value="<?php 
            echo $page['locale'];
            ?>
"/>
<input type="hidden" name="group" value="<?php 
            echo $page['groupid'];
            ?>
"/>
<?php 
        }
        ?>
	<div class="mform"><div class="formtop"><div class="formtopi"></div></div><div class="forminner">

	<div class="fieldForm">
		<div class="field">
			<div class="flabel"><?php 
        echo getlocal("cannededit.message");
        ?>
</div>
			<div class="fvaluenodesc">
				<textarea name="message" cols="20" rows="5" class="wide"><?php 
        echo form_value('message');
        ?>
</textarea>
			</div>
		</div>
	
		<div class="fbutton">
			<input type="image" name="save" value="" src='<?php 
        echo $webimroot . getlocal("image.button.save");
        ?>
' alt='<?php 
        echo getlocal("button.save");
        ?>
'/>
		</div>
	</div>
	
	</div><div class="formbottom"><div class="formbottomi"></div></div></div>
</form>

<?php 
    }
    ?>

<?php 
}
开发者ID:paulcn,项目名称:mibew,代码行数:93,代码来源:cannededit.php

示例9: tpl_content

function tpl_content()
{
    global $page, $webimroot, $errors;
    ?>

<?php 
    echo getlocal("page_avatar.intro");
    ?>
<br />
<br />
<?php 
    require_once 'inc_errors.php';
    ?>

<form name="avatarForm" method="post" action="<?php 
    echo $webimroot;
    ?>
/operator/avatar.php" enctype="multipart/form-data">
<input type="hidden" name="op" value="<?php 
    echo $page['opid'];
    ?>
"/>
	<div>
<?php 
    print_tabbar();
    ?>
	<div class="mform"><div class="formtop"><div class="formtopi"></div></div><div class="forminner">

	<p>
		<b><?php 
    echo $page['currentop'];
    ?>
&lrm;</b>
	</p>

	<div class="fieldForm">

<?php 
    if ($page['avatar']) {
        ?>
		<div class="field">
			<div class="flabel"><?php 
        echo getlocal('form.field.avatar.current');
        ?>
</div>
			<div class="fvalue">
				<img src="<?php 
        echo $page['avatar'];
        ?>
" alt="cannot load avatar"/><br/>
<?php 
        if ($page['canmodify']) {
            ?>
                <a class="formauth" href='<?php 
            echo $webimroot;
            ?>
/operator/avatar.php?op=<?php 
            echo $page['opid'];
            ?>
&amp;delete=true'>
                    <?php 
            echo getlocal("page_agent.clear_avatar");
            ?>
                </a>
<?php 
        }
        ?>
			</div>
			<div class="fdescr"> &mdash; <?php 
        echo getlocal('form.field.avatar.current.description');
        ?>
</div>
			<br clear="all"/>
		</div>
<?php 
    } else {
        if (!$page['canmodify']) {
            ?>
		<div class="field">
			<div class="fvaluenodesc">
				No avatar
			</div>
		</div>
<?php 
        }
    }
    ?>

<?php 
    if ($page['canmodify']) {
        ?>
		<div class="field">
			<div class="flabel"><?php 
        echo getlocal('form.field.avatar.upload');
        ?>
<span class="required">*</span></div>
			<div class="fvalue">
				<input type="file" name="avatarFile" size="40" value="<?php 
        echo form_value('avatarFile');
        ?>
//.........这里部分代码省略.........
开发者ID:laiello,项目名称:cartonbank,代码行数:101,代码来源:avatar.php

示例10: h

<p>
	<input type="text" class="span12" name="blog[subject]" id="input_subject" placeholder="제목*" value="<?php 
echo h(form_value($this, 'blog', 'subject'));
?>
">
</p>
<p>
	<textarea class="span12" rows="10" name="blog[content]" id="input_contents" placeholder="내용*"><?php 
echo h(form_value($this, 'blog', 'content'));
?>
</textarea>
</p>
开发者ID:utumdol,项目名称:codeseed,代码行数:12,代码来源:_form.php

示例11: checkbox_checked

 function checkbox_checked($data, $key, $value, $default = '')
 {
     $v = form_value($data, $key, $default);
     return $value == $v ? 'checked' : '';
 }
开发者ID:ice-gyx,项目名称:transfer,代码行数:5,代码来源:Validation.php

示例12: form_input

                                    <?php 
echo form_input(array('class' => 'form-control', 'name' => 'country', 'value' => form_value('country', $user)));
?>
                                </div>
                                <div class="clearfix"></div>
                            </div>
                            <br />
                            <div class="field-row row-fluid">
                                <div class="col-md-4">
                                    <?php 
echo form_label(__('Phone', true), 'phone');
?>
                                </div>
                                <div class="col-md-8">
                                    <?php 
echo form_input(array('class' => 'form-control', 'name' => 'phone', 'autocomplete' => 'off', 'value' => form_value('phone', $user)));
?>
                                </div>
                                <div class="clearfix"></div>
                            </div>
                        </div>
                    </div>
                </div>

            </div>
        </div>
        <div class="panel-footer">
            <div class="col-md-12 text-right">
                <?php 
echo isset($user->id) ? form_hidden('id', $user->id) : '';
?>
开发者ID:NaszvadiG,项目名称:bootigniter,代码行数:31,代码来源:profile-form.php

示例13: form_value

	</div>
</div>
<div class="control-group">
	<label class="control-label" for="input_repassword"><i class="icon-check"></i> 비밀번호 확인</label>
	<div class="controls">
		<input type="password" name="user[repassword]" id="input_repassword" placeholder="비밀번호 확인" value="<?php 
echo form_value($this, 'user', 'repassword');
?>
">
	</div>
</div>
<div class="control-group">
	<label class="control-label" for="input_nickname"><i class="icon-check"></i> 별명</label>
	<div class="controls">
		<input type="text" name="user[nickname]" id="input_nickname" placeholder="별명" value="<?php 
echo form_value($this, 'user', 'nickname');
?>
">
	</div>
</div>

<script type="text/javascript">
function make_nickname() {
	$('#input_nickname').val($('#input_email').val().split('@')[0]);
}

$(function() {
	$('#input_email').keyup(function() {
		$('#input_nickname').val($('#input_email').val().split('@')[0]);
	})
	$('#input_email').blur(function() {
开发者ID:utumdol,项目名称:codeseed,代码行数:31,代码来源:_form.php

示例14: isset

?>
                                        </div>
                                        <div class="clearfix"></div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
                <div class="panel-footer">
                    <div class="col-md-12 text-right">
                        <?php 
echo isset($user->id) ? form_hidden('id', $user->id) : '';
?>
                        <a href="<?php 
_u('admin/users/index/' . form_value('gid', $user));
?>
" class="btn btn-default">
                            <i class="fa fa-arrow-circle-left"></i>
                            <?php 
__('Cancel');
?>
                        </a>
                        <button type="submit" class="btn btn-primary">
                            <i class="fa fa-save"></i>
                            <?php 
__('Save');
?>
                        </button>
                    </div>
                    <div class="clearfix"></div>
开发者ID:NaszvadiG,项目名称:bootigniter,代码行数:31,代码来源:form.php

示例15: h

<section>
	<div class="page-header">
		<h3>비밀번호&nbsp;찾기</h3>
	</div>
	<div class="alert">
		이메일 주소를 입력하시면 임시 비밀번호가 해당 이메일 주소로 발송됩니다.<br>
		로그 인 후 임시 비밀번호를 반드시 변경해 주세요.
	</div>
	<form id="form" class="form-horizontal" method="post">
		<div class="control-group">
			<label class="control-label" for="input_email"><i class="icon-check"></i> 이메일</label>
			<div class="controls">
				<input type="email" name="user[email]" id="input_email" placeholder="이메일" value="<?php 
echo h(form_value($this, 'user', 'email'));
?>
">
			</div>
		</div>
		<div class="form-actions">
			<button type="button" class="btn btn-large btn-primary" id="button_submit">임시 비밀번호 발송</button>
			<button type="button" class="btn btn-large" id="button_cancel">취소</button>
		</div>
	</form>
</section>
<script type="text/javascript">
function cancel() {
	window.history.back();
}

function submit() {
	$('#form').attr('action', '/user/send_password');
开发者ID:utumdol,项目名称:codeseed,代码行数:31,代码来源:send_password_form.php


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