I have an application that uses the iframe to redirect the pages without modifying the url. (I understand the consequences of doing this.)
The problem is that updating the page with F5
is redirected to the source page, in the case of the login page, how do you prevent it from being redirected to this page?
Detail looks like a browser-dependent behavior, because the redirect happened only in Chrome, in mozilla and ie normal, or as I wish.
Here is an example for testing:
index.html
<!DOCTYPE html>
<html>
<head>
<title>Router</title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
</head>
<body>
<iframe src="pages/home.html"></iframe>
</body>
</html>
Flame pages / home.html
<!DOCTYPE html>
<html>
<head>
<title>Home</title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
</head>
<body>
<ul>
<li><a href="about.html">About</a></li>
</ul>
</body>
</html>
Calling pages / about.html
<!DOCTYPE html>
<html>
<head>
<title>About</title>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
</head>
<body>
<ul>
<li><a href="home.html">Home</a></li>
</ul>
</body>
</html>
In Chrome, if I go to about.html and hit F5
it goes back to home.html, which is the default iframe file.