我想在jsp中使用localStorage值,因为我要从数据库中获取数据并绘制图形。我该怎么办?
//This will get Value from localStorage:---
<script type="text/javascript">
var tableName = localStorage.getItem("table");
</script>
//Jsp Code;
String tableName1=request.getParameter("tableName");
out.println("Value:--"+tableName1);
// and using this in sql Query
String Query = "select data from " + tableName1 + " where datetime is not
null;";
// in this code that tableName1 is not acceccing value