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.

temerloh.html 7.6KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161
  1. <!DOCTYPE html>
  2. <html>
  3. <head>
  4. <meta charset="UTF-8">
  5. <!-- https://developer.mozilla.org/en-US/docs/Web/HTTP/CSP -->
  6. <!-- CSP is a PITA ;). Disabled, don't try this at home!-->
  7. <meta http-equiv="Content-Security-Policy" content="">
  8. <title>SIBS 2024</title>
  9. <link rel="stylesheet" href="../node_modules/bootstrap/dist/css/bootstrap.min.css">
  10. <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/5.15.4/css/all.min.css" integrity="sha512-abc123..." crossorigin="anonymous" />
  11. <link rel="stylesheet" href="../css/app.css">
  12. <link rel="stylesheet" href="../css/animate.css">
  13. </head>
  14. <body>
  15. <section class="section animate__animated animate__fadeIn" style="max-height: 100vh;">
  16. <div class=""
  17. style="z-index: 3;background-color: #1F3F6D; min-height: 50px; display: flex; align-items: center;padding-left: 100px;">
  18. <h6 style="color: white;margin-right: 1em;" class=""><a style="color: white;" href="../index.html"><i
  19. class="fas fa-chevron-left"></i></a></h6>
  20. <h6 style="color: white;">Temerloh</h6>
  21. </div>
  22. <div class="text-center pt-5"
  23. style="background-color: white; min-height: 50px; display: flex; justify-content: center; align-items: center; padding-left: 0px;">
  24. <button id="industri_btn" type="button" class="p-1"
  25. style="font-weight: 500; border-top: 4px solid #32A740; border-right: none; border-bottom: none; border-left: none; margin: 0; background-color: transparent;">&emsp;&emsp;Industri&emsp;&emsp;</button>
  26. </div>
  27. <div class="text-center pt-1"
  28. style="background-color: white; min-height: 50px; display: flex; justify-content: center; align-items: center; padding-left: 170px;">
  29. <div class="pt-5 position-relative" style="width: 1000px;height: 100px;margin-top: -700px;">
  30. <svg class="map-svg" version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg"
  31. xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="100 50 850 850"
  32. style="enable-background: new 0 0 1080 1080" xml:space="preserve">
  33. <g>
  34. <a href="#" data-area="jerantut">
  35. <path id="temerloh" class="pahang-tengah"
  36. d="M528.7,494c-16.5-1-31.1-5.4-39.8-21.4c-9.5-17.6-9.5-17.6-29-15c-0.8,0.1-0.8,0.3-0.8,0.4c0.1,0.1,0,0.1,0,0
  37. c-0.1-0.1-0.2-0.1-0.4-0.3c-1.5-1-3.1-2-4.7-2.8c-0.9,0-1.6-0.3-2.1-1.1c-7.2-3.5-14.9-5.7-22.2-9c-1.9,0.3-3.6-0.6-4.8-2.4
  38. c-0.3-0.2-0.6-0.3-0.9-0.5c0,0,0,0,0,0c-7.8-3.1-2.4-13.1-8.1-17.3c-1.9,7.5-8,9.4-14.8,10.2c-7.2,0.8-14.3,2-20.9,5.2
  39. c-9.9,4.9-17.9,11.3-17.9,23.9c0.1,12.8-8.2,22.3-15.3,31.4c-5.9,7.6-8.7,14.9-8.7,24c-0.3,0.7-0.6,1.4-1,2.1
  40. c7.5,6,7.5,9.6,0.6,14.5c-8.6,6-11.2,20.1-4.5,28.7c5.6,7.1,10.3,14.4,12.4,23.2c1.1,4.6,4,6.8,8,9c15.2,8.4,17.6,14.5,13.1,30.8
  41. c-2.7,6.3-2.2,12.6-0.5,19c0.2,1.2,0.2,2.4,0.1,3.6c5,2.2,6.1,8.4,10,11.8c6.6-6.2,42-21.8,46.2-19.1c8.5,5.3,16.2,11.3,26.3,14
  42. c4.9,1.3,8.8,1.2,13.2-0.4c0.4,0.1,0.8,0.2,1.1,0.3c1.5-10.3,9.7-11.3,17.6-11.6c8.1-0.3,15.8,2.2,23.5,4.8
  43. c7.7,2.6,15.5,4.2,23.6,1.6c4.8-1.6,10.2-5.1,8.1-9.5c-5.9-12.6,4-19.2,8.7-27.9c0.4-0.6,0.9-1.2,1.4-1.6
  44. c-5.9-11.6-11.3-22.3-10.3-37.3c1.4-22.8,1.8-46.6-6.1-69.1C528.5,502.3,528.9,498,528.7,494z" />
  45. </a>
  46. </g>
  47. </svg>
  48. <div class="plot animate__animated animate__bounceIn industri-point position-absolute" style="background-color: #32A740; width: 0.8rem; height: 0.8rem;border: 2px solid white;border-radius: 600px;top:574px;left:262px"></div>
  49. </div>
  50. </div>
  51. <div id="industri_plot" class="content-div">
  52. <div class="text-center pt-5"
  53. style="background-color: white; display: flex; justify-content: left; align-items: left; padding-left: 100px;margin-top: 250px;">
  54. <h6>Industri</h6><br>
  55. </div>
  56. <div class="text-center pt-2 flex-wrap"
  57. style="background-color: white; display: flex; justify-content: left; align-items: left; padding-left: 100px; margin-top: 0;gap: 10px;padding-right: 100px;">
  58. <a href="../details/detail_pn16507.html" class="button-23 mb12-2"
  59. style="background-color: #1F9027; color: white; border: none;" role="button">PN 16507</a>
  60. </div>
  61. </div>
  62. </section>
  63. <script>
  64. document.getElementById('pembangun_btn').addEventListener('click', function () {
  65. showDiv('pembangun_plot');
  66. });
  67. document.getElementById('penternakan_btn').addEventListener('click', function () {
  68. showDiv('penternakan_plot');
  69. });
  70. document.getElementById('pertanian_btn').addEventListener('click', function () {
  71. showDiv('pertanian_plot');
  72. });
  73. document.getElementById('industri_btn').addEventListener('click', function () {
  74. showDiv('industri_plot');
  75. });
  76. function showDiv(divId) {
  77. var divs = document.getElementsByClassName('content-div');
  78. for (var i = 0; i < divs.length; i++) {
  79. divs[i].classList.add('hidden');
  80. }
  81. document.getElementById(divId).classList.remove('hidden');
  82. }
  83. </script>
  84. <script>
  85. let temerloh = document.querySelector("#temerloh");
  86. addLabelText(temerloh, "Temerloh");
  87. function addLabelText(bgPath, labelText) {
  88. let bbox = bgPath.getBBox();
  89. let x = bbox.x + bbox.width / 2;
  90. let y = bbox.y + bbox.height / 2;
  91. // Create a <text> element
  92. let textElem = document.createElementNS(bgPath.namespaceURI, "text");
  93. // X axis
  94. if (labelText == "Bentong") {
  95. textElem.setAttribute("x", 286);
  96. } else if (labelText == "Pekan") {
  97. textElem.setAttribute("x", 870);
  98. } else if (labelText == "Cameron") {
  99. textElem.setAttribute("x", 75);
  100. } else {
  101. textElem.setAttribute("x", x);
  102. }
  103. // Y axis
  104. if (labelText == "Rompin") {
  105. textElem.setAttribute("y", 935);
  106. } else if (labelText == "Pekan") {
  107. textElem.setAttribute("y", 650);
  108. } else if (labelText == "Kuantan") {
  109. textElem.setAttribute("y", 440);
  110. } else if (labelText == "Cameron") {
  111. textElem.setAttribute("y", 130);
  112. } else if (labelText == "Highland") {
  113. textElem.setAttribute("y", 155);
  114. } else {
  115. textElem.setAttribute("y", y);
  116. }
  117. // Centre text horizontally at x,y
  118. textElem.setAttribute("text-anchor", "middle");
  119. // Give it a class that will determine the text size, colour, etc
  120. if (labelText == "Cameron" || labelText == "Highland") {
  121. textElem.classList.add("label-text-cameron");
  122. } else {
  123. textElem.classList.add("label-text");
  124. }
  125. // Set the text
  126. textElem.textContent = labelText;
  127. // Add this text element directly after the label background path
  128. bgPath.after(textElem);
  129. }
  130. </script>
  131. </body>
  132. </html>