H5 realize how close the current page, jump to a new page?

There applet jump method this feature.

So how H5 implement this feature? Very simple.

location.replace ( 'new.html')  This method may be implemented  to close the current page, jump to a new page effects.

The window.location.href = "new.html", this method will retain access to the historical record.

Guess you like

Origin www.cnblogs.com/teamemory/p/10966471.html