Trial scenarios
When the server where the WEB Project is deployed has both the Intranet and Internet IP addresses, and the Web project needs to be released in the Intranet and Internet environments, the Intranet user needs to access the application through the Intranet IP address.ProgramYou must use an Internet IP address to access the Internet.
Deployment Method
1. Release the WEB Project under the root directory of the website, and the output folder is the image server under the output virtual directory of the website (that is, the application is http: // [IP]/[Application name]/corresponding output is http: // [IP]/output/, or http: // [IP]: [port]/the corresponding output is http: // [IP]: [port]/output /)
2. Change the Host Name of the access image to ".. /.. /.. /.. /.. /.. /.. /.. /.. /.. /output ", directly modify Supermap is. net installation directory/bin/supermapis. <options output = ".. \ output "website = ".. /.. /.. /.. /.. /.. /.. /.. /.. /../
Output "/>, the number of" ../"is 10,
3. scale control must be set in the web project, for example, default in the default ajaxdemo project. <SMIs: mapscale mapname = "Changchun" scales = "100000,50000, 25000,125 500,"> set aspx to change mapname to Project Map Name and scales to map control scale, if you set multiple maps to multiple SMIs: mapscale nodes to set the Map Name and scale, for the development method of ajaxscripts and iclient rich client, refer to the help documentation of the response to set the map scale.
4. Modify the maphandler address "./".
Principle: 1. map image request format:
{Http: // localhost/} {ajax/World/1.56205255014020.e-8/4/2/256/PNG/0/false/true/map. ashx ?}
In the first braces, the path where maphandler is located, that is, the project release path.
The second braces are the number of depth paths used to access the map cache. /"number, which is 10 here, so the connection" .. the/number is 10. You can use tools such as httpwatch or fiddle to view the path, for example, the request information captured by httpwatch:
2. Notes during debugging:
1. After modification, restart the map server, IIS server.
2. Clear ie Cache
3. Web project cache (default value: C: \ WINDOWS \ Microsoft. NET \ framework \ v2.0.50727
\ Temporary ASP. NET Files directory, with the project name ).
4. constantly adjust the number of ../. This number varies depending on the specific environment. Generally, the depth of the Access Map cache path after the above map request format varies depending on the actual situation.
In the past two days, some colleagues found that the new ideas for solving this problem are much faster than above. The methods listed are as follows:
1. Modify the maphandler address "./".
2. Open Supermap is.. net installation directory. modify website = "http: // localhost/is/output" to website = "/is/output" in the config file, and then restart IIS and the map server.
Pay attention to the following situations when solving problems with the customer based on the above two ideas:
1. If the project network is under a port and the image server is: output is under another port, this is not the case. try to create a new is/output virtual directory on the website to which the WebGIS project belongs, or directly publish the project to the default website. In fact, this does not matter on that website. As long as it is attributed to different application pools, different application pools can be set for different virtual directories, which can be fully used for IIS performance.
2. The maphandler cannot be accessed after being modified to./. In this case, the script can be used.CodeDetermine the address for accessing the website. It is an intranet address. During the map initialization, change the maphandler address to an intranet address. If it is an Internet address, change it to an Internet address.