2

我正在尝试在我的应用程序中使用 URL 缩短服务。但是,我想公开我的自定义 tinyURL 域而不是服务之一。为此,我做了以下事情:

  1. 我从一个标准的 tinyURL 服务缩短了我的长 URL,并得到了一个缩短的 URL,比如 - http://tinyurl.com/abcdXYZ

  2. 我将网址公开为 http://kk.ly/abcdXYZ(假设 kk.ly 是我拥有的域)

我还进行了从 kk.ly 到 tinyurl.com 的 CNAME 转发

我想知道这种方法是否有任何问题?有没有人尝试过这个 - 任何经验/学习要分享?

谢谢,KK

4

2 回答 2

1

Just 'cause you can setup a cname and redirect traffic to tinyurl.com doesn't mean they'll actually service the requests. Try taking a working tinyurl.com url and replacing the domain name with their IP address and you get a 404 error. A custom cname would probably result in the same.

Google's Short Sites service specifically supports custom cnames, but it is only available for Google Apps.

http://www.labnol.org/internet/setup-tinyurl-like-redirection-service/8333/

于 2010-03-30T20:56:16.900 回答
1

CNAME 意味着连接将被重定向到tinyurl.com,但 HTTP 请求中的 URL 仍将具有kk.ly主机名而不是tinyurl.com. 我不知道 HTTP 服务器tinyurl.com是否会冒犯。此外,管理人员tinyurl.com自己可能会感到被冒犯(基本上,您在使用他们的服务时没有在 URL 中保留他们的名字)。我建议你事先检查一下。

于 2010-03-30T20:55:49.627 回答