Common.js

From Young Beethoven
Jump to navigation Jump to search
Line 4: Line 4:
$(function () {
$(function () {
if($('input[name=composer]').length > 0) {
if($('input[name=composer]').length > 0) {
$('#firstHeading').html($($('input[name=composer]')[0]).val()+'<br>'+$('#firstHeading').html());
$('#firstHeading').html($($('input[name=composer]')[0]).val()/*+'<br>'+$('#firstHeading').html()*/);
if($('input[name=title]').length > 0) {
$('#firstHeading').html($('#firstHeading').html()+'<br>'+$('input[name=title]')[0].val());
}
}
}
}());
}());

Revision as of 09:25, 3 August 2023

/* Any JavaScript here will be loaded for all users on every page load. */

// Alter composition page name to feature composer
$(function () {
	if($('input[name=composer]').length > 0) {
		$('#firstHeading').html($($('input[name=composer]')[0]).val()/*+'<br>'+$('#firstHeading').html()*/);
		if($('input[name=title]').length > 0) {
			$('#firstHeading').html($('#firstHeading').html()+'<br>'+$('input[name=title]')[0].val());
		}
	}
}());