summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorBharat Mediratta <bharat@menalto.com>2010-01-29 10:13:10 -0800
committerBharat Mediratta <bharat@menalto.com>2010-01-29 10:13:10 -0800
commit0d73738099f7c12f2185018a29b647763c9d36ce (patch)
tree6ba2b3f03f7ac2c1464f0991be0a1eda82a0ed46 /modules
parent743fbe76965b00087d8e091f742acd61d3a740d0 (diff)
Stop using obsolete form::close()
Update the way we include the hidden CSRF field for InPlaceEdit.
Diffstat (limited to 'modules')
-rw-r--r--modules/digibug/views/digibug_form.html.php2
-rw-r--r--modules/gallery/libraries/InPlaceEdit.php1
-rw-r--r--modules/gallery/views/in_place_edit.html.php5
3 files changed, 4 insertions, 4 deletions
diff --git a/modules/digibug/views/digibug_form.html.php b/modules/digibug/views/digibug_form.html.php
index c6994cbe..f7b34e16 100644
--- a/modules/digibug/views/digibug_form.html.php
+++ b/modules/digibug/views/digibug_form.html.php
@@ -3,7 +3,7 @@
<body>
<?= form::open("http://www.digibug.com/dapi/order.php") ?>
<?= form::hidden($order_parms) ?>
- <?= form::close() ?>
+ </form>
<script type="text/javascript">
document.forms[0].submit();
</script>
diff --git a/modules/gallery/libraries/InPlaceEdit.php b/modules/gallery/libraries/InPlaceEdit.php
index 67ab3805..04a2e9a5 100644
--- a/modules/gallery/libraries/InPlaceEdit.php
+++ b/modules/gallery/libraries/InPlaceEdit.php
@@ -70,7 +70,6 @@ class InPlaceEdit_Core {
public function render() {
$v = new View("in_place_edit.html");
- $v->hidden = array("csrf" => access::csrf_token());
$v->action = url::site($this->action);
$v->form = $this->form;
$v->errors = $this->errors;
diff --git a/modules/gallery/views/in_place_edit.html.php b/modules/gallery/views/in_place_edit.html.php
index 45cf1d8c..b556829c 100644
--- a/modules/gallery/views/in_place_edit.html.php
+++ b/modules/gallery/views/in_place_edit.html.php
@@ -1,5 +1,6 @@
<?php defined("SYSPATH") or die("No direct script access.") ?>
-<?= form::open($action, array("method" => "post", "id" => "g-in-place-edit-form", "class" => "g-short-form"), $hidden) ?>
+<?= form::open($action, array("method" => "post", "id" => "g-in-place-edit-form", "class" => "g-short-form")) ?>
+ <?= access::csrf_form_field() ?>
<ul>
<li<? if (!empty($errors["input"])): ?> class="g-error"<? endif ?>>
<?= form::input("input", $form["input"], " class=\"textbox\"") ?>
@@ -9,7 +10,7 @@
</li>
<li><a href="#" class="g-cancel"><?= t("Cancel") ?></a></li>
</ul>
-<?= form::close() ?>
+</form>
<? if (!empty($errors["input"])): ?>
<div id="g-in-place-edit-message" class="g-error"><?= $errors["input"] ?></div>
<? endif ?>