1. 程式人生 > 其它 >JSP連線資料庫實現註冊登入

JSP連線資料庫實現註冊登入

<!DOCTYPE html> <html lang="en">   <head>     <meta charset="UTF-8" />     <meta http-equiv="X-UA-Compatible" content="IE=edge" />     <meta name="viewport" content="width=device-width, initial-scale=1.0" />     <title>Document</title>   </head>   <body>     <script>       var obj = [         {           id: 5.008134315509367,           direction: 1,           directionValue: "道路1",           along: [             {               id: 3.8197476423951704,               laneno: "1",               feature: 1,               attribute: 1,               attributeValue: "進口",               movement: 11,               movementValue: "直行",               designFlow: 1600,             },             {               id: 3.4973827451609374,               laneno: "2",               feature: 1,               attribute: 1,               attributeValue: "進口",               movement: 11,               movementValue: "直行",               designFlow: 2000,             },           ],           inverse: [             {               id: 8.659490225538937,               laneno: "",               feature: 1,               attribute: 2,               attributeValue: "出口",               movement: 11,               movementValue: "直行",             },             {               id: 4.95249030613696,               laneno: "",               feature: 1,               attribute: 2,               attributeValue: "出口",               movement: 11,               movementValue: "直行",             },           ],           sidewalk: [             {               id: 3.848716923399995,               laneno: 28,               feature: null,               attribute: null,               attributeValue: null,               movement: 39,               movementValue: "人行道",             },             {               id: 4.957695466666687,               laneno: 29,               feature: null,               attribute: null,               attributeValue: null,               movement: 39,               movementValue: "人行道",             },           ],           uiConfig: {             offset: {               x: 0,               y: 0,             },             rotation: 0,             scaleX: 1,             scaleY: 1,             x: 1012,             y: 653,             radianX: 1018,             radianY: 866,             roadWide: 52,             roadLength: 400,           },         },         {           id: 6.8493000505898305,           direction: 1,           directionValue: "道路2",           along: [             {               id: 7.064828471650966,               laneno: "1",               feature: 1,               attribute: 1,               attributeValue: "進口",               movement: 11,               movementValue: "直行",               designFlow: 1600,             },             {               id: 6.493711027062039,               laneno: "2",               feature: 1,               attribute: 1,               attributeValue: "進口",               movement: 11,               movementValue: "直行",               designFlow: 2000,             },           ],           inverse: [             {               id: 1.6253939060885059,               laneno: "",               feature: 1,               attribute: 2,               attributeValue: "出口",               movement: 11,               movementValue: "直行",             },             {               id: 3.3160255628650748,               laneno: "",               feature: 1,               attribute: 2,               attributeValue: "出口",               movement: 11,               movementValue: "直行",             },           ],           sidewalk: [             {               id: 8.41887911305095,               laneno: 28,               feature: null,               attribute: null,               attributeValue: null,               movement: 39,               movementValue: "人行道",             },             {               id: 2.5596377387505864,               laneno: 29,               feature: null,               attribute: null,               attributeValue: null,               movement: 39,               movementValue: "人行道",             },           ],           uiConfig: {             offset: {               x: 0,               y: 0,             },             rotation: 90,             scaleX: 1,             scaleY: 1,             x: 855,             y: 1017,             radianX: 634,             radianY: 1021,             roadWide: 52,             roadLength: 400,           },         },         {           id: 2.8909594588184184,           direction: 1,           directionValue: "道路3",           along: [             {               id: 9.567443751442484,               laneno: "1",               feature: 1,               attribute: 1,               attributeValue: "進口",               movement: 11,               movementValue: "直行",               designFlow: 1600,             },             {               id: 3.773191787288539,               laneno: "2",               feature: 1,               attribute: 1,               attributeValue: "進口",               movement: 11,               movementValue: "直行",               designFlow: 2000,             },           ],           inverse: [             {               id: 9.222901428032664,               laneno: "",               feature: 1,               attribute: 2,               attributeValue: "出口",               movement: 11,               movementValue: "直行",             },             {               id: 2.5472352547694954,               laneno: "",               feature: 1,               attribute: 2,               attributeValue: "出口",               movement: 11,               movementValue: "直行",             },           ],           sidewalk: [             {               id: 3.3923864176672747,               laneno: 28,               feature: null,               attribute: null,               attributeValue: null,               movement: 39,               movementValue: "人行道",             },             {               id: 4.991722591877544,               laneno: 29,               feature: null,               attribute: null,               attributeValue: null,               movement: 39,               movementValue: "人行道",             },           ],           uiConfig: {             offset: {               x: 0,               y: 0,             },             rotation: 180,             scaleX: 1,             scaleY: 1,             x: 489,             y: 860,             radianX: 487,             radianY: 653,             roadWide: 52,             roadLength: 400,           },         },         {           id: 9.773597087719079,           direction: 1,           directionValue: "道路4",           along: [             {               id: 8.220782335384467,               laneno: "1",               feature: 1,               attribute: 1,               attributeValue: "進口",               movement: 11,               movementValue: "直行",               designFlow: 1600,             },             {               id: 4.531208882928592,               laneno: "2",               feature: 1,               attribute: 1,               attributeValue: "進口",               movement: 11,               movementValue: "直行",               designFlow: 2000,             },           ],           inverse: [             {               id: 1.5799755323465692,               laneno: "",               feature: 1,               attribute: 2,               attributeValue: "出口",               movement: 11,               movementValue: "直行",             },             {               id: 8.462445154699115,               laneno: "",               feature: 1,               attribute: 2,               attributeValue: "出口",               movement: 11,               movementValue: "直行",             },           ],           sidewalk: [             {               id: 0.6067705124044442,               laneno: 28,               feature: null,               attribute: null,               attributeValue: null,               movement: 39,               movementValue: "人行道",             },             {               id: 4.492333699806901,               laneno: 29,               feature: null,               attribute: null,               attributeValue: null,               movement: 39,               movementValue: "人行道",             },           ],           uiConfig: {             offset: {               x: 0,               y: 0,             },             rotation: 270,             scaleX: 1,             scaleY: 1,             x: 645,             y: 492,             radianX: 857,             radianY: 482,             roadWide: 52,             roadLength: 400,           },         },       ];
      console.log("before", obj);
      obj.map((item) => {         Object.keys(item.uiConfig).map((keys) => {           console.log(keys);           if (keys !== "offset" && keys !== "rotation") {             item.uiConfig[keys] = item.uiConfig[keys] * 0.3;             console.log(item.uiConfig[keys] * 0.3);           }         });       });       console.log("after", obj);     </script>   </body> </html>