old-browser.js 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. $buoop = {
  2. required: { i: 8, f: 25, o: 17, s: 9, c: 22 },
  3. style:"corner",
  4. insecure:false,
  5. // Specifies required browser versions
  6. // Browsers older than this will be notified.
  7. // f:22 ---> Firefox < 22 gets notified
  8. // Negative numbers specify how much versions behind current version.
  9. // c:-5 ---> Chrome < 35 gets notified if latest Chrome version is 40.
  10. // more details (in english)
  11. reminder: 24,
  12. // after how many hours should the message reappear
  13. // 0 = show all the time
  14. reminderClosed: 150,
  15. // if the user explicitly closes message it reappears after x hours
  16. onshow: function (infos) { },
  17. onclick: function (infos) { },
  18. onclose: function (infos) { },
  19. // callback functions after notification has appeared / was clicked / closed
  20. l: false,
  21. // set a fixed language for the message, e.g. "en". This overrides the default detection.
  22. test: false,
  23. // true = always show the bar (for testing)
  24. text: "<b>Your browser ({brow_name}) is out of date.</b><br />This website requires a modern browser to function properly. You can continue using the site with your current browser, but some features will be disabled. <br /><center><a{ignore_but}>Ok</a></center>",
  25. // custom notification text (html)
  26. // Placeholders {brow_name} will be replaced with the browser name, {up_but} with contents of the update link tag and {ignore_but} with contents for the ignore link.
  27. // Example: "Your browser, {brow_name}, is too old: <a{up_but}>update</a> or <a{ignore_but}>ignore</a>."
  28. // more details (in english)
  29. newwindow: true,
  30. // open link in new window/tab
  31. url: null,
  32. // the url to go to after clicking the notification
  33. noclose: false,
  34. // Do not show the "ignore" button to close the notification
  35. nomessage: false,
  36. // Do not show a message if the browser is out of date, just call the onshow callback function
  37. jsshowurl: "/browser-update/scripts/update.show.js",
  38. // URL where the script, that shows the notification, is located. This is only loaded if the user actually has an outdated browser.
  39. container: document.body,
  40. // DOM Element where the notification will be injected.
  41. no_permanent_hide: false
  42. // Do not give the user the option to permanently hide the notification
  43. };
  44. function $buo_f() {
  45. var e = document.createElement("script");
  46. e.src = "/browser-update/scripts/update.js";
  47. document.body.appendChild(e);
  48. };
  49. try { document.addEventListener("DOMContentLoaded", $buo_f, false) }
  50. catch (e) { window.attachEvent("onload", $buo_f) }