国内流行的内容管理系统(CMS)多端全媒体解决方案 https://www.dedebiz.com
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

68 lines
2.0KB

  1. var $ = jQuery;
  2. var thespeed = 5;
  3. var navIE = document.all && navigator.userAgent.indexOf("Firefox") == -1;
  4. var myspeed = 0;
  5. $(function () {
  6. //左侧菜单开关
  7. LeftMenuToggle();
  8. //全部功能开关
  9. AllMenuToggle();
  10. //取消菜单链接虚线
  11. $(".head").find("a").click(function () { $(this).blur() });
  12. $(".menu").find("a").click(function () { $(this).blur() });
  13. }).keydown(function (event) {//快捷键
  14. if (event.keyCode == 116) {
  15. }
  16. if (event.keyCode == 27) {
  17. $("#qucikmenu").slideToggle("fast")
  18. }
  19. });
  20. function LeftMenuToggle() {//左侧菜单开关
  21. $("#togglemenu").click(function () {
  22. if ($("body").attr("class") == "showmenu") {
  23. $("body").attr("class", "hidemenu");
  24. $(this).html("显示菜单");
  25. } else {
  26. $("body").attr("class", "showmenu");
  27. $(this).html("隐藏菜单");
  28. }
  29. });
  30. }
  31. function AllMenuToggle() {//全部功能开关
  32. mask = $(".pagemask,.iframemask,.allmenu");
  33. $("#allmenu").click(function () {
  34. mask.show();
  35. });
  36. mask.click(function () { mask.hide(); });
  37. }
  38. function AC(act) {
  39. mlink = $("a[id='" + act + "']");
  40. if (mlink.size() > 0) {
  41. box = mlink.parents("div[id^='menu_']");
  42. boxid = box.attr("id").substring(5, 128);
  43. if ($("body").attr("class") != "showmenu") $("#togglemenu").click();
  44. if (mlink.attr("_url")) {
  45. $("#menu").find("div[id^=menu]").hide();
  46. box.show();
  47. mlink.addClass("thisclass").blur().parents("#menu").find("ul li a").not(mlink).removeClass("thisclass");
  48. if ($("#mod_" + boxid).attr("class") == "") {
  49. $("#nav").find("a").removeClass("thisclass");
  50. $("#nav").find("a[id='mod_" + boxid + "']").addClass("thisclass").blur();
  51. }
  52. main.location.href = mlink.attr("_url");
  53. } else if (mlink.attr("_open") && mlink.attr("_open") != undefined) {
  54. window.open(mlink.attr("_open"));
  55. }
  56. }
  57. }
  58. /*********************
  59. * 滚动按钮设置
  60. *********************/
  61. function scrollwindow() {
  62. parent.frames['menu'].scrollBy(0, myspeed);
  63. }
  64. function initializeIT() {
  65. if (myspeed != 0) {
  66. scrollwindow();
  67. }
  68. }