From the QQ website to extract the pure JS province city level three linkage

Source: Internet
Author: User

In http://ip.qq.com/'s website has qq own JS province city three level linkage

QQ is used to refer to external JS to achieve three-level linkage. JS as follows: Http://ip.qq.com/js/geo.js

<!DOCTYPE HTML><HTML><Head><title>QQ JS Province Urban three-level linkage</title><!--Direct use of QQ's provincial and municipal data -<!--<script type= "Text/javascript" src= "Http://ip.qq.com/js/geo.js" ></script> -<Scripttype= "Text/javascript"src= "Geo.js"></Script></Head><Bodyonload= "Setup ();p reselect (' Shaanxi province ');p Romptinfo ();">        <form>            <Selectclass= "Select"name= "Province"ID= "S1">              <option></option>            </Select>            <Selectclass= "Select"name= "City"ID= "S2">              <option></option>            </Select>            <Selectclass= "Select"name= "Town"ID= "S3">              <option></option>            </Select>            <inputID= "Address"name= "Address"type= "hidden"value="" />          <inputonclick= "alert (document.getElementById (' address '). value); return false;"type= "Submit"value= "Submit" />        </form><Script>//This function is necessary because this function is called every time the address is changed in the Geo.jsfunctionPromptinfo () {varAddress=document.getElementById ('Address'); varS1=document.getElementById ('S1'); varS2=document.getElementById ('S2'); varS3=document.getElementById ('S3'); Address.value=S1.value+S2.value+S3.value;}</Script></Body></HTML>

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.