javascript:location.href="googlechrome"+location.href.substring(4);
2. 隨意打開一個網(wǎng)頁并選擇“添加為書簽”
在書簽欄找到剛添加的書簽并編輯
隨意變個名稱,比如“發(fā)送標簽到Chrome” ;在地址欄將網(wǎng)址清除,將js代碼貼進去
好了,打開網(wǎng)頁,直接點擊“發(fā)送標簽到Chrome” 這個書簽就能看到窗口會自動從Safari切換至Chrome繼續(xù)瀏覽網(wǎng)頁。
如果以上js代碼不適用于你當前的設備,可以嘗試下面兩個代碼:
javascript:location.href=%22googlechrome%22+location.href.substring(4);
https URLs:?javascript:location=location.href.replace(/^https?/, 'googlechrome');
.