使用 DNS 将域指向特定页面?
我知道这个问题看起来很简单,但我很难在谷歌/其他论坛上找到任何答案。
客户在网络解决方案上停放了一些域名 - 未附加到任何托管帐户。我计划将最近购买的域名之一指向我们主网站(在其他地方托管)的子目录 - 作为正在进行的特别促销活动的一部分。
不过,Network Solutions 现在对 Web 转发收费。为了避免额外收费,我想我应该使用 DNS 设置将 IP 指向该网站 - 但这只会将用户带到主网站的主页 --- 而不是我需要的特定子目录到。
由于域名只是停放 - 并且不与托管帐户关联,因此我无法访问 .htaccess 文件来处理 301 转发或其中的任何内容。
有什么想法吗?提前致谢!
I know this question seems pretty straight-forward, but I'm having a hard time pulling up any answers on Google / Other Forums.
A client has a few domains parked on Network Solutions - not attached to any hosting account. I'm planning to point one of the recently purchased domains to a sub-directory of our main site (hosted elsewhere) - as part of a special promotion that's running.
However, Network Solutions now charges for Web Forwarding. In hopes of avoiding an additional charge I thought I'd use the DNS settings to point the IP to the site - but that just takes the user to the main website's home-page --- and not the specific sub-directory I need it to.
Since the domains are just parked - and not associated with a hosting account, I don't have access to a .htaccess file to deal with 301 forwarding or anything there.
Any ideas? Thanks in advance!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
只需将 DNS 指向您的服务器并为每个新域设置虚拟主机即可。然后,放入一行 JS 或 PHP 索引文件(或 mod_rewrite 规则)以重定向到主站点上所需的页面。
Just point the DNS to your server and set up vhosts for each of the new domains. Then, drop in a one-line JS or PHP index file (or mod_rewrite rule) to redirect to the desired page on your main site.