diff options
Diffstat (limited to 'core/views')
-rw-r--r-- | core/views/in_place_edit.html.php | 42 |
1 files changed, 0 insertions, 42 deletions
diff --git a/core/views/in_place_edit.html.php b/core/views/in_place_edit.html.php deleted file mode 100644 index 02f41e19..00000000 --- a/core/views/in_place_edit.html.php +++ /dev/null @@ -1,42 +0,0 @@ -<? defined("SYSPATH") or die("No direct script access."); ?> -<script type="text/javascript"> -// <![CDATA[ -$(document).ready(function() { - ajax_update = function(className, id) { - return function(value, settings) { - var post_data = {'_method': 'put', '_return': settings.name}; - post_data[settings.name] = value; - $.post("<?= url::site("items/__ID__") ?>".replace("__ID__", id), - post_data, - function(data, textStatus) { - if (textStatus == "success") { - $(className).html(data); - } - }, - "html"); - } - } - - var seen_before = {}; - var editable = $("span.gInPlaceEdit"); - for (i = 0; i < editable.length; i++) { - var matches = editable[i].className.match(/gEditField-(\d+)-(\S+)/); - if (matches && matches.length == 3) { - var className = "." + matches[0]; - if (!seen_before[className]) { - $(className).editable( - ajax_update(className, matches[1]), - {indicator : "<?= _("Saving...") ?>", - tooltip : "<?= _("Double-click to edit...") ?>", - event : "dblclick", - style : "inherit", - name : matches[2], - select : true} - ); - seen_before[className] = 1; - } - } - } -}); -// ]]> -</script> |