Shunze 學園 >電腦資訊學系 >電腦密技 > 《分享》為你的工作平台建立網站名稱 哈囉,還沒有註冊或者登入。請你[註冊|登入]
« 上一篇主題 下一篇主題 » 顯示成列印模式 | 增加到我的最愛
發表新主題 發表回覆
作者
主題
shunze
工友伯伯


註冊日期: 2002 04
來自: 潮汐終止之地
文章: 2370

shunze 離線
《分享》為你的工作平台建立網站名稱引用回覆 編輯/刪除文章 搜尋由  發表的其他文章 回報給版主 IP 位置 回此頁最上方

這是順子在新公司所學到的,分享給大家參考!

一般而言,以IIS建構網站環境時,我們開發平台的網址是以
http://127.0.0.1/ 或是
http://localhost/
來指向本機。

其實你可以有更多選擇!
我們可以在以下檔案中,為自己的開發測試平台建立屬於自己的網址。
C:\WINNT\system32\drivers\etc\hosts

該檔原始內容如下:
# Copyright (c) 1993-1999 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# space.
#
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
#
# For example:
#
# 102.54.94.97 rhino.acme.com # source server
# 38.25.63.10 x.acme.com # x client host

127.0.0.1 localhost


你可以在最後加入自己的設定的網址對應,例如:
127.0.0.1 localhost
127.0.0.1 test.shunze.d2g.com

如此一來,test.shunze.d2g.com 也就可以指向127.0.0.1本機位址了。
這個方法適用於windows 2000及windows XP。


如果你有安裝Norton AntiVirus的話,你可以發現Norton也是利用這個方式將pop3.norton.antivirus指向127.0.0.1機位址。

用這個方向來指定本機網址,是不是方便又好用呢!!

(當然這個方法是方便本機測試,對外可行不通喔!)



♥順子老婆的網拍,請多關照∼

If you don't like something, change it.
If you can't change it, change your attitude.
Don't complain!




2003-10-18, 17:06 shunze 的個人資料 把 shunze 加入好友列表 發送Email給 shunze 瀏覽 shunze 的網站 MSN : shunze@gmail.com
  « 上一篇主題 下一篇主題 »
發表新主題 發表回覆
跳到:

Powered by: Burning Board 1.1.1 2001 WoltLab GbR