Can it be done purely using js and html?
One way that comes to mind is to use the form on page one to pass parameters, and page two to judge the parameters to determine whether p is displayed.
But how are the parameters passed by action received by page 2?
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8"/>
<title></title>
</head>
<body>
<form action="index2.html#p">
<input type="text" name="firstname" value="">
<input type="submit" value="Submit">
</form>
</body>
</html>
Please tell me, seniors, whether this method is feasible? How to do it?
Get url parameters
One more thing, CSS3’s :target pseudo-class selector can also implement this function, mainly using anchor points
Reference: http://css.doyoe.com/selector...