Haben Sie ein wenig Geduld.
Die Datei wird hochgeladen.
');
$('#ok_cms_op_loadFileDiv').fadeIn('fast');
});
}
function hideLoadFile(){
$('#ok_cms_op_loadFileDiv').fadeOut('fast', function() {
document.body.removeChild(document.getElementById("ok_cms_op_loadFileDiv"));
$('#ok_cms_overlay').fadeOut('fast');
});
}
function getAjaxBox(item,tableName,fieldName,whereClause){
if($(item).val().length>1){
var ajaxBoxDiv = create("div",{id:"ajaxBoxDiv",onmouseover:"ajaxBoxMouseOver=true",onmouseout:"ajaxBoxMouseOver=false"},'');
document.body.appendChild(ajaxBoxDiv);
$('#ajaxBoxDiv').css("background-image","url(/img/animations/ajax-loader-small.gif)");
$.ajax({
url: "https://ihr-hauskoch.de/ajaxJobs/getAjaxBox.php",
type: "POST",
data: {'item': item, 'value': $(item).val(),'tableName': tableName,'fieldName': fieldName,'whereClause': whereClause},
context: document.body,
error: function(xhr, ajaxOptions, thrownError){
alert('Errorcode: '+xhr.status);
if(thrownError) alert('Errorcode: '+thrownError);
},
success: function(data){
if(data){
$('#ajaxBoxDiv').css("background-image","none");
$('#ajaxBoxDiv').css({"left": $(item).offset().left,"top": ($(item).offset().top + $(item).height()) });
$('#ajaxBoxDiv').width($(item).width());
$('#ajaxBoxDiv').attr("innerHTML",data);
$('#ajaxBoxDiv').show();
} else {
$('#ajaxBoxDiv').hide();
ajaxBoxMouseOver=false;
}
}
});
} else {
$('#ajaxBoxDiv').hide();
ajaxBoxMouseOver=false;
}
return true;
}
function setAjaxBox(item,value){
$(item).val(value);
$('#ajaxBoxDiv').hide();
ajaxBoxMouseOver=false;
return true;
}
function hideAjaxBox(item,value){
if(!ajaxBoxMouseOver) {
$('#ajaxBoxDiv').hide();
ajaxBoxMouseOver=false;
}
}
function showTab(id, callBack){
if(id!=tabShown){
if(tabShown) $('#tab_'+tabShown).slideUp('fast');
$('#tab_'+id).slideDown('fast', function(){$('#'+id).css('background-image','url(/img/buttons/up.png)'); $('#'+id).addClass('hover'); $('#'+tabShown).css('background-image','url(/img/buttons/down.png)',$('#'+tabShown).removeClass('hover')); tabShown=id; if(typeof callBack == 'function') callBack.call()});
$.ajax({
url: "https://ihr-hauskoch.de/ajaxJobs/saveTabSession.php",
type: "GET",
data: {'varName':tabSessionVariable,'tabId': id},
context: document.body
});
}
}
function showTab1(id, callBack){
$('#'+id).hide();
$('#tab1_'+id).slideDown('fast', function(){if(typeof callBack == 'function') callBack.call()});
}
function hideTab1(id, callBack){
$('#'+id).show();
$('#tab1_'+id).slideUp('fast', function(){if(typeof callBack == 'function') callBack.call()});
}
function showItemMap(lat,lng,mapZoom,marker){
initialize_map(lat,lng,mapZoom);
if(marker) map.addOverlay(new GMarker(new GLatLng(lat,lng)));
}
function clearFormFileds(formName){
$(':input',formName)
.not(':button, :submit, :reset, :hidden')
.val('');
$('input[placeholder],textarea[placeholder]').placeholder();
}
function activateTinyMCE(){
}
function activateTinyMCElight(mode, element){
tinyMCE.init({
mode : mode ? mode : "textareas",
language : "de",
elements : element,
theme : "advanced",
skin : "o2k7",
skin_variant : "silver",
plugins : "safari,advhr,advlink,emotions,contextmenu,paste,directionality,visualchars,nonbreaking,xhtmlxtras,inlinepopups",
// Theme options
theme_advanced_buttons1 : "bold,italic,underline,strikethrough,justifyleft,justifycenter,justifyright,justifyfull,fontsizeselect,cut,copy,paste,pastetext,pasteword,selectall",
theme_advanced_buttons2 : "bullist,numlist,undo,redo,link,unlink,forecolor,backcolor,code",
theme_advanced_buttons3 : "",
theme_advanced_toolbar_location : "top",
theme_advanced_toolbar_align : "left",
theme_advanced_resizing : false,
// Example content CSS (should be your site CSS)
content_css : "/css/tinyMCE-content.css",
force_br_newlines : true,
forced_root_block : '',
paste_create_paragraphs : false,
paste_create_linebreaks : false,
paste_use_dialog : true,
paste_auto_cleanup_on_paste : true,
paste_strip_class_attributes : true,
paste_remove_spans : true,
paste_remove_styles : true,
paste_remove_styles_if_webkit : true,
paste_convert_middot_lists : false,
paste_unindented_list_class : "unindentedList",
paste_convert_headers_to_strong : true,
//Mad File Manager
relative_urls : true,
remove_script_host : true,
file_browser_callback : MadFileBrowser
});
}
function activateTinyMCEeasy(mode, element){
tinyMCE.init({
mode : mode ? mode : "textareas",
language : "de",
elements : element,
theme : "advanced",
skin : "o2k7",
skin_variant : "silver",
plugins : "safari,advhr,advlink,emotions,contextmenu,paste,directionality,visualchars,nonbreaking,xhtmlxtras,inlinepopups",
// Theme options
theme_advanced_buttons1 : "bold,italic,underline,strikethrough,justifyleft,justifycenter,justifyright,justifyfull,fontsizeselect,cut,copy,paste,bullist,numlist,undo,redo,forecolor,backcolor,emotions",
theme_advanced_buttons2 : "",
theme_advanced_buttons3 : "",
theme_advanced_toolbar_location : "top",
theme_advanced_toolbar_align : "center",
theme_advanced_resizing : false,
// Example content CSS (should be your site CSS)
content_css : "/css/tinyMCE-content.css",
force_br_newlines : true,
forced_root_block : '',
paste_create_paragraphs : false,
paste_create_linebreaks : false,
paste_use_dialog : true,
paste_auto_cleanup_on_paste : true,
paste_strip_class_attributes : true,
paste_remove_spans : true,
paste_remove_styles : true,
paste_remove_styles_if_webkit : true,
paste_convert_middot_lists : false,
paste_unindented_list_class : "unindentedList",
paste_convert_headers_to_strong : true
});
}
function MadFileBrowser(field_name, url, type, win) {
tinyMCE.activeEditor.windowManager.open({
file : "/script/tiny_mce/plugins/mfm.php?field=" + field_name + "&url=" + url + "",
title : 'Dateimanager',
width : 640,
height : 450,
resizable : "no",
inline : "yes",
close_previous : "no"
}, {
window : win,
input : field_name
});
return false;
}
function redrawSelects(){
$.each($('select.rounded'),function(i,k){$(k).selectmenu({style:'dropdown', width: $(k).css('width')});});
}
function goTo(URL, target) {
if (target == null) target = 'parent';
if (navigator.appName == "Netscape") eval('window.' + target + '.location = "' + URL + '"');
else eval('window.' + target + '.navigate("' + URL + '")')
}
function checkFields(elmts, rules, formID) {
var valid = true;
var requredOK = true;
var errorMessage = [];
$.each($((formID?'#'+formID+' ':'')+'.required').get().reverse(),function(i,k){
$(k).removeClass('errorField');
$('#label_' + $(k).attr('id')).removeClass('error');
if($(k).val()=='') {
$('#label_' + $(k).attr('id')).addClass('error');
$(k).addClass('errorField');
if(valid) errorMessage[errorMessage.length] = 'Bitte füllen Sie alle markierte Felder aus!';
valid = valid && false;
requredOK = requredOK && false;
$(k).focus();
}
});
if(elmts.length>0){
elmts.reverse();
rules.reverse();
for (index = 0; index < elmts.length; index++) {
elmt = elmts[index];
$('#label_' + elmt).removeClass('error');
$('#' + elmt).removeClass('errorField');
if (typeof rules[index][0] == 'object') {
for (ind = 0; ind < rules[index][0].length; ind++) {
if (eval(rules[index][0][ind])) {
$('#label_' + elmt).addClass('error');
$('#' + elmt).addClass('errorField');
valid = false;
if(requredOK){
$('#' + elmt).focus();
errorMessage[errorMessage.length] = rules[index][1][ind];
}
break;
}
}
} else if (eval(rules[index][0])) {
$('#label_' + elmt).addClass('error');
$('#' + elmt).addClass('errorField');
valid = false;
if(requredOK){
$('#' + elmt).focus();
errorMessage[errorMessage.length] = rules[index][1];
}
}
}
}
errorMessage.reverse();
return [valid, errorMessage];
}
function checkEmail(eMail) {
var pattern1 = /^[\w-]+(\.[\w-]+)*@([\w-]+\.)+[a-zA-Z]{2,7}([\w-]+\.)+[a-zA-Z]{2,7}$/;
var pattern2 = /^[\w-]+(\.[\w-]+)*@([\w-]+\.)+[a-zA-Z]{2,7}$/;
return (pattern1.test(eMail) || pattern2.test(eMail))
}
function redirectToURL(url) {
if (redirectTimer == 0) {
goTo(url)
} else {
$('#timerContainer').attr('innerHTML', redirectTimer);
setTimeout("redirectToURL('" + url + "')", 1000);
redirectTimer--
}
}
function selectAllRows() {
$('.rowSelect').attr('checked', $('#rowSelectAll:checked').val() == 1)
}
function toInt(x) {
return parseInt(parseFloat(x))
}
function doBlink() {
$('.blink').fadeOut('slow', function () {
$('.blink').fadeIn('slow')
});
setTimeout("doBlink()", 3000)
}
function reloadPage() {
window.location.reload();
return 0
}
function initShowHide(){
$('.showHide').click(function(){
var containerId = '#'+this.rel;
if($(containerId).is(':hidden')) $(containerId).slideDown();
else $(containerId).slideUp();
return false;
});
}