Home >Web Front-end >HTML Tutorial >When applying the framework, why is it still redirected to the previous website despite changing the href? _html/css_WEB-ITnose
25edfb22a4f469ecb59f1190150159c6101d7feff1edc6e1c59d2ae5b34b1ba3Opportunity Creation5db79b134e9f6b82c0b36e0489ee08edbed06894275b65c1ab86501b08a632eb
href="http://www.baidu.com" target="main">Opportunity View5db79b134e9f6b82c0b36e0489ee08edbed06894275b65c1ab86501b08a632eb
Click on opportunity creation, and you will still be redirected to Baidu.
Test as follows
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" /><title>无标题文档</title><script >window.onload=function(){ var oA=document.getElementById('test'); var oBtn=document.getElementById('btn'); oBtn.onclick=function() { oA.href='http://www.163.com'; } }</script></head><body><a href="http://www.baidu.com" id="test">测试</a><input type="button" value="改变" id="btn" /></body></html>Me I redeployed it, and it worked. Intermittent failure, sometimes just restarting myeclipse works, sometimes it still doesn't work, sometimes it gets better after a while. Originally, the URLs were all set to Baidu. Later, when I changed them one by one as needed, the changed URLs would still jump to Baidu. Thank you