$(document).ready(function() { /* *** Call Theme Config Driver *** */ $.get('themes/MasterControlProgram/conf/sbs_conf.php', function(data){ console.log(data); } ); /* *** Cutting Title *** */ $('.logo h2').text($('.logo h2').text().substring(0, $('.logo h2').text().lastIndexOf(" [") + 1)); /* *** Remove CSS and JS Files *** */ $('link[href="css/global.css"]').remove(); $('link[href="js/bootstrap/css/bootstrap-combined.min.css"]').remove(); /* *** Removing Chars from Links *** */ $('a:not(.user_menu_link), a span').each(function(){ $(this).html($(this).html().replace('[','').replace(']','')); }); /* *** Several Class and Style Stuff *** */ $(window).load(function () { $('tr, td, div:not([class*="nicEdit"])').css("background-color", ""); $('div:not([class*="nicEdit"], #refreshed-0)').css("border", "").css("height", ""); $('input').css("width", ""); if($.trim($("div").text()) == "") { $(this).remove(); } $('.footer.center').removeClass('center'); // $('input[type="submit"]').each(function(){ // $(this).replaceWith(''); // }); }); $('table .first_row > td').each(function(){ $(this).replaceWith(''+$(this).html()+''); }); $('.magnificContentsDiv').bind("DOMSubtreeModified",function(){ $('.updateLink, .ogpAPIActions').addClass('form-control').css('display','inline-block'); $('.copyButton').addClass('btn').addClass('btn-sm').addClass('btn-primary'); }); /* *** Submit Button Replacement *** */ $('input[type="submit"]').each(function(){ var oSubmitButton = $(this); var oForm = oSubmitButton.closest('form'); var sOriginAttrs = ''; $.each(oSubmitButton[0].attributes, function() { if (this.specified) { sOriginAttrs += ' ' + this.name + '="' + this.value + '"'; } }); }); // File Style Hack $.fn.input_file_styling = function() { $('input[type="file"]').each(function(){ if($(this).parent().hasClass('btn-file')==false){ $(this).css('display', 'none'); $(this).wrap('
').wrap('