diff options
author | Tim Almdal <tnalmdal@shaw.ca> | 2008-12-15 03:49:48 +0000 |
---|---|---|
committer | Tim Almdal <tnalmdal@shaw.ca> | 2008-12-15 03:49:48 +0000 |
commit | b2107c37344a6013cedfcbff824accebd99c6112 (patch) | |
tree | c635234d22e594954ab37ffb794145d3d4dddb10 /modules | |
parent | 119344d9db9873918995886af938f968cd21b922 (diff) |
1) Move the deletion of the vars into module::delete helper
2) remove the watermark_add_form.html.php
Diffstat (limited to 'modules')
-rw-r--r-- | modules/watermark/helpers/watermark_installer.php | 4 | ||||
-rw-r--r-- | modules/watermark/views/watermark_add_form.html.php | 46 |
2 files changed, 0 insertions, 50 deletions
diff --git a/modules/watermark/helpers/watermark_installer.php b/modules/watermark/helpers/watermark_installer.php index 617c505c..a5f07202 100644 --- a/modules/watermark/helpers/watermark_installer.php +++ b/modules/watermark/helpers/watermark_installer.php @@ -29,10 +29,6 @@ class watermark_installer { } public static function uninstall() { - $module = module::get("watermark"); - - $db = Database::instance(); - $db->query("DELETE FROM vars WHERE module_id = '{$module->id}';"); module::delete("watermark"); } } diff --git a/modules/watermark/views/watermark_add_form.html.php b/modules/watermark/views/watermark_add_form.html.php deleted file mode 100644 index b5c50697..00000000 --- a/modules/watermark/views/watermark_add_form.html.php +++ /dev/null @@ -1,46 +0,0 @@ -<? defined("SYSPATH") or die("No direct script access."); ?> -<? if (empty($_FILES)): ?> -<script> -$("document").ready(function() { - ajaxify_form(); -}); - -function ajaxify_form() { - $("#gUploadWatermarkForm").ajaxForm({ - complete:function(xhr, statusText) { - $("#gUploadWatermarkForm").replaceWith(xhr.responseText); - if (xhr.status == 200) { - $("#gUploadWatermarkForm").clearForm(); - } - ajaxify_form(); - } - }); -} -</script> -<? endif ?> -<form action="<?= url::site("watermark/load")?>" method="post" id="gUploadWatermarkForm" - enctype="multipart/form-data"> - <fieldset> - <legend><?= _("Upload Watermark")?></legend> - <ul> - <li <? if (isset($errors["file"])): ?>class ="gError"<? endif ?>> - <label for="file"><?= _("File")?></label> - <input type="file" id="file" name="file" class="upload" - value="<?= $fields["file"] ?>"> - <? if (isset($errors["file"]["type"])): ?> - <p><?= _("Invalid File Type") ?></p> - <? elseif (isset($errors["file"]["size"])): ?> - <p><?= _("File too large") ?></p> - <? elseif (isset($errors["file"]["valid"])): ?> - <p><?= _("Upload failed") ?></p> - <? endif ?> - <? if (isset($success)): ?> - <p><?= $success ?></p> - <? endif ?> - </li> - <li> - <button type="submit" class="submit"><?= _("Upload") ?></button> - </li> - </ul> - </fieldset> -</form>
\ No newline at end of file |