Changes
Jump to navigation
Jump to search
← Older edit
Newer edit →
MediaWiki:Common.js
(view source)
Revision as of 18:38, 2 August 2021
64 bytes added
,
18:38, 2 August 2021
no edit summary
Line 1:
Line 1:
/* Any JavaScript here will be loaded for all users on every page load. */
/* Any JavaScript here will be loaded for all users on every page load. */
−
$('#wagon-configurator-list li').click(function(){
+
$(document).ready(function(){
−
$(this).addClass('selected');
+
var wagonSelection;
−
$(this).siblings().removeClass('selected');
+
−
var wagonSelection = this.
wagonClass
[0];
+
$('#wagon-configurator-list li').click(function(){
−
});
+
$(this).addClass('selected');
+
$(this).siblings().removeClass('selected');
+
var wagonSelection = this.
classList
[0];
+
});
−
$('#wagon-configurator li.wagon-slot').click(function(){
+
$('#wagon-configurator li.wagon-slot').click(function(){
−
alert("You selected " + wagonSelection);
+
alert("You selected " + wagonSelection
);
+
}
);
});
});
Stencil
Bureaucrats
,
Interface administrators
,
Administrators
519
edits
Navigation menu
Personal tools
Create account
Log in
Namespaces
Message
Discussion
Variants
Views
Read
View source
View history
More
Search
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Tools
Special pages
Printable version