大家好,门外汉又来求帮忙了 我想做一个网站relay, 实现 如果用户访问 http://a.com.au/?path=http:/b.com.au/ 那么请求由a.com.au 发起,抓取path后面的变量,然后用curl 发起一个http 请求。 目前 b.com.au 的首页也能正常显示出来。 如果在页面 b.com.au/ 下有个其他页面(/test1/test2/a.htm), 如果把鼠标停在上面, 能看到 默认 指向了 http://a.com.au/test1/test2/a.htm 点击访问肯定出错, 因为页面是在 b.com.au 上, 不在 a.com.au 上。 如果我手工把地址栏的url 改成 http://a.com.au/?path=http://b.com.au/test1/test2/a.htm 页面能正常显示。 请问大家,如何能把上面的url (http://a.com.au/test1/test2/a.htm) 自动重定向到 (http://a.com.au/?path=http://b.com.au/test1/test2/a.htm ) 最好是鼠标停在a.htm 页面上的时候, 跳转url 已经自动指向 (http://a.com.au/?path=http://b.com.au/test1/test2/a.htm ) 而不是 (http://a.com.au/test1/test2/a.htm ) |