- zoesch.de - blitzkiste.net - gruene-hassberge (norbert.zoesch.de) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
22 lines
650 B
JavaScript
22 lines
650 B
JavaScript
/* changeElementType: this function changes element types. e.g. <div> to <ul> */
|
|
(function($) {
|
|
$.fn.changeElementType = function(newType) {
|
|
var attrs = {};
|
|
if (!(this[0] && this[0].attributes))
|
|
return;
|
|
|
|
$.each(this[0].attributes, function(idx, attr) {
|
|
attrs[attr.nodeName] = attr.nodeValue;
|
|
});
|
|
this.replaceWith(function() {
|
|
return $("<" + newType + "/>", attrs).append($(this).contents());
|
|
});
|
|
}
|
|
})(jQuery);
|
|
|
|
/* common issue */
|
|
$(document).ready(function () {
|
|
$('#navbar-menubar .navbar-form').css({'color': $('.dropdown-menu>li>a').css('color')});
|
|
});
|
|
|