My English is not good enough so I hope you understand what's my problem...
I have a page 'A' with a form. When I click Submit, I want it to open/redirect to a page 'B', and I want to show on page 'B' the data of the form in page 'A'... I want to do this with JavaScript, not with jQuery or so. I've tried with window.opener
or things like that... Next, the example code is shown.
Page 'A':
<html>
<head>
</head>
<body>
<form method="post" name="form1" id="form1">
<input type="text" name="field1">
<input type="submit" name="submit" onclick="window.open('show.html');">
</form>
</body>
</html>
Page 'B':
<html>
<head>
</head>
<body>
<script>
var x = opener.document.forms["form1"]["field1"].value;
document.write(x);
</script>
</body>
</html>
It's really important that page 'B' can show data from the form on page 'A'. I can't use PHP or another technology... :/
I hope you understand what I'm asking. Thanks!
**UPDATE
The solution (at least for me) is localStorage, as Sagar Hani indicated. Anyway, thanks to people who answered!
Can't be PHP? With PHP you can also send the info to page B and display to user all the info. In fact, is more user friendly because it's a server side process.
Following is the exact solution that you want.
Page 'A' (a.html)
Page 'B' (b.html)