/* GMLangEdit.js <?php
# --------------------------------------------------------------
# GMLangEdit.js 2011-09-12 gambio
# Gambio GmbH
# http://www.gambio.de
# Copyright (c) 2011 Gambio GmbH
# Released under the GNU General Public License (Version 2)
# [http://www.gnu.org/licenses/gpl-2.0.html]
# --------------------------------------------------------------
?>*/
function GMLangEdit()
{
this.content_backup = '';
this.content_id = '';
$('#constant_edit_needle').ready(function()
{
if(fb)console.log('constant_edit_needle ready');
$('#go_search').click(function(e) {
if(fb)console.log('constant_edit_needle change');
gmLangEdit.find_needle($('#constant_edit_needle').attr('value'));
$('.result_constant_value').unbind();
});
$('#constant_edit_needle').keypress(function(e) {
if(e.keyCode == 13) {
gmLangEdit.find_needle($('#constant_edit_needle').attr('value'));
$('.result_constant_value').unbind();
//gmLangEdit.send_form();
}
});
});
this.activate_edit_field = function()
{
$("#gm_status").fadeIn('fast');
$('.result_constant_value').click(function(e)
{
var content = $(this).html();
if(gmLangEdit.content_id != '') {
$("#" + gmLangEdit.content_id).html(gmLangEdit.content_backup);
}
gmLangEdit.content_backup = content;
gmLangEdit.content_id = $(this).attr("id");
$(this).html('<textarea name="constant_value_content" rows="4" cols="80">'+ content +'</textarea><br/>');
$(this).append('<input style="float:left;margin-right:6px" class="button" id="go_save" type="button" name="go_save" value="Speichern" />');
$(this).append('<input class="button" id="go_cancel" type="button" name="go_cancel" value="Abbrechen" />');
$('.result_constant_value').unbind();
$('#go_save').click(function(e) {
var content = $(this).parent().find('textarea').val();
var content_id = $(this).parent().attr('id');
if(fb)console.log('content_id:' + content_id + ' content: ' + content);
$.ajax({url: '../gm_ajax.php?module=admin_lang_edit&act=save_content&content=' + encodeURIComponent(escape(content)) + '&content_id=' + content_id});
$(this).parent().text(content).html();
$('.result_constant_value').click(function(e) {
gmLangEdit.activate_edit_field();
});
});
$('#go_cancel').click(function(e) {
if(fb)console.log('go_cancel');
var content = $(this).parent().find('textarea').val();
$(this).parent().html(gmLangEdit.content_backup);
$('.result_constant_value').click(function(e) {
gmLangEdit.activate_edit_field();
});
});
});
}
this.send_form = function() {
var content = $('#go_save').parent().find('textarea').val();
var content_id = $('#go_save').parent().attr('id');
if(fb)console.log('content_id:' + content_id + ' content: ' + content);
$.ajax({url: '../gm_ajax.php?module=admin_lang_edit&act=save_content&content=' + escape(content) + '&content_id=' + content_id});
$('#go_save').parent().html(content);
$('.result_constant_value').click(function(e) {
gmLangEdit.activate_edit_field();
});
}
this.find_needle = function(needle)
{
$("#results_box").load('../gm_ajax.php?module=admin_lang_edit&act=search&needle=' + escape(escape(needle)), '', function() {gmLangEdit.activate_edit_field()} );
}
}| nama | waktu | ukuran | owner | perm | aksi |
|---|---|---|---|---|---|
| .. | |||||
| ClearCache.js | 2013-11-12 20:53 | 1.43 KB | 76129f60960:kunden | -xw-x----- | |
| GMFavMaster.js | 2013-11-12 20:53 | 5.4 KB | 76129f60960:kunden | -xw-x----- | |
| GMLangEdit.js | 2013-11-12 20:53 | 3.36 KB | 76129f60960:kunden | -xw-x----- | |
| GMLeftBoxes.js | 2013-11-12 20:53 | 2.24 KB | 76129f60960:kunden | -xw-x----- | |
| LoadPayPalAdminNotification.js | 2013-11-12 20:53 | 1.44 KB | 76129f60960:kunden | -xw-x----- | |
| LoadUrl.js | 2013-11-12 20:53 | 1.47 KB | 76129f60960:kunden | -xw-x----- | |
| PayPalApiCheck.js | 2013-11-12 20:53 | 1.21 KB | 76129f60960:kunden | -xw-x----- | |
| ShowLog.js | 2013-11-12 20:53 | 3.69 KB | 76129f60960:kunden | -xw-x----- | |
| gm_bookmarks.js | 2013-11-12 20:53 | 1.87 KB | 76129f60960:kunden | -xw-x----- | |
| gm_counter.js | 2013-11-12 20:53 | 4.15 KB | 76129f60960:kunden | -xw-x----- | |
| gm_ebay.js | 2013-11-12 20:53 | 742 B | 76129f60960:kunden | -xw-x----- | |
| gm_gprint.js.php | 2013-11-12 20:53 | 2.2 KB | 76129f60960:kunden | -xw-x----- | |
| gm_invoicing.js | 2013-11-12 20:53 | 1.2 KB | 76129f60960:kunden | -xw-x----- | |
| gm_logo.js | 2013-11-12 20:53 | 2.14 KB | 76129f60960:kunden | -xw-x----- | |
| gm_modules.js | 2013-11-12 20:53 | 1.17 KB | 76129f60960:kunden | -xw-x----- | |
| gm_orders.js | 2013-11-12 20:53 | 4.41 KB | 76129f60960:kunden | -xw-x----- | |
| gm_pdf.js | 2013-11-12 20:53 | 5.17 KB | 76129f60960:kunden | -xw-x----- | |
| gm_sitemap.js | 2013-11-12 20:53 | 1.54 KB | 76129f60960:kunden | -xw-x----- | |
| gm_style_edit.js | 2013-11-12 20:53 | 2.46 KB | 76129f60960:kunden | -xw-x----- | |
| google_categories_administration.js | 2013-11-12 20:53 | 8.04 KB | 76129f60960:kunden | -xw-x----- | |
| image_mapper.js | 2013-11-12 20:53 | 47.22 KB | 76129f60960:kunden | -xw-x----- | |
| lettr_de.js | 2013-11-12 20:53 | 2.43 KB | 76129f60960:kunden | -xw-x----- | |
| lightbox_google_admin_categories.js | 2013-11-12 20:53 | 13.2 KB | 76129f60960:kunden | -xw-x----- | |
| lightbox_plugin.js | 2013-11-12 20:53 | 5.91 KB | 76129f60960:kunden | -xw-x----- | |