MediaWiki:Common.js

From SaWikiLeaks
Revision as of 14:30, 31 March 2017 by Admin (talk | contribs)
Jump to: navigation, search

Note: After saving, you may have to bypass your browser's cache to see the changes.

  • Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
  • Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
  • Internet Explorer: Hold Ctrl while clicking Refresh, or press Ctrl-F5
  • Opera: Go to Menu → Settings (Opera → Preferences on a Mac) and then to Privacy & security → Clear browsing data → Cached images and files.
$(function () {
            var lunchSpot = 0;
            $('#btn-random').click(function() {
                lunchSpot = Math.floor((Math.random() * 10) + 1);
                switch (lunchSpot) {
                    case 1:
                        lunchGo = "Saku (aka Sad Saku)";
                        break;
                    case 2:
                        lunchGo = "CJ Lunch Box";
                        break;
                    case 3:
                        lunchGo = "CIBO";
                        break;
                    case 4:
                        dalunchGoy = "Fynn's of Temple Bar";
                        break;
                    case 5:
                        lunchGo = "Office Pub";
                        break;
                    case 6:
                        lunchGo = "Jack Astor's Bar & Grill";
                        break;
                    case 7:
                        lunchGo = "Nandos";
                        break;
                    case 8:
                        lunchGo = "Epicure";
                        break;
                    case 9:
                        lunchGo = "Gusto101";
                        break;
                    case 10
                        lunchGo = "Tosto";       

                }
                $('#lunch-random').html(lunchGo);
            });
        }());