Recently, WAP2.0 is working on a mobile WAP. When writing back to the previous page, it started to use history. Go (-1 );
We found that only some machines on the mobile phone can be like Windows Mobile, while other machines, such as Nokia and ophone
This is not easy to use. After thinking about it, I finally thought of a method to solve this rogue problem...
The mobile phone's return function is not used directly. Instead, the mobile phone's return to the previous page is implemented by reading the link of the previous page on the referrer.
CodeAs follows:
JavaScript code
/* Return to the previous page */<br/> function return_prepage () <br/> {<br/> if(window.w.doc ument. referrer = "" | zookeeper Doc ument. referrer = Window. location. href) <br/>{< br/> window. location. href = "{Dede: Type} [field: typelink/] {/Dede: Type}"; <br/>}else <br/>{< br/> too many location.href?##doc ument. referrer; <br/>}</P> <p>}
Direct call where needed;
Javascript: return_prepage ();