Small addition for giving forms unique IDs. Mainly so that javascript has
something to hook onto.
This commit is contained in:
parent
6c3e91e01c
commit
3a4aea45d5
@ -218,13 +218,14 @@ function make_http($link) {
|
||||
|
||||
/**
|
||||
* Make a form tag with relevant auth token and stuff
|
||||
* (Added optional Form ID field for helping jquery.)
|
||||
*
|
||||
* @retval string
|
||||
*/
|
||||
function make_form($target, $method="POST", $multipart=False) {
|
||||
function make_form($target, $method="POST", $multipart=False, $form_id="") {
|
||||
global $user;
|
||||
$auth = $user->get_auth_html();
|
||||
$extra = "";
|
||||
$extra = empty($form_id) ? '' : " id='$form_id'";
|
||||
if($multipart) {
|
||||
$extra .= " enctype='multipart/form-data'";
|
||||
}
|
||||
|
@ -10,7 +10,7 @@ class ImageIOTheme {
|
||||
|
||||
$i_image_id = int_escape($image_id);
|
||||
$html = "
|
||||
".make_form(make_link("image_admin/delete"))."
|
||||
".make_form(make_link("image_admin/delete"),'POST',false,'delete_image')."
|
||||
<input type='hidden' name='image_id' value='$i_image_id'>
|
||||
<input type='submit' value='Delete'>
|
||||
</form>
|
||||
|
Loading…
x
Reference in New Issue
Block a user