l*0
2 楼
Hi,
I'm using JAVA URL to download some data from U.S Census. I have a problem.
http://factfinder.census.gov/servlet/AGSGeoAddressServlet?_MapEvent=&_category=&_subcategory=&_stateSelectedFromDropDown=Pennsylvania&context=ags&programYear=50%3A420&street=1383%2BLONG%2BRUN%2BRD&city=FRIEDENSBURG&states=Pennsylvania&zip=17933&geo_id=&_p
if you copy the above url and put them into the explore. you will find the
Census
website would pop up a window saying "Factfinder cannot locate the address
you
ent
I'm using JAVA URL to download some data from U.S Census. I have a problem.
http://factfinder.census.gov/servlet/AGSGeoAddressServlet?_MapEvent=&_category=&_subcategory=&_stateSelectedFromDropDown=Pennsylvania&context=ags&programYear=50%3A420&street=1383%2BLONG%2BRUN%2BRD&city=FRIEDENSBURG&states=Pennsylvania&zip=17933&geo_id=&_p
if you copy the above url and put them into the explore. you will find the
Census
website would pop up a window saying "Factfinder cannot locate the address
you
ent
g*g
4 楼
When you talk about popup, check javascript in that page.
【在 l*****0 的大作中提到】![](/moin_static193/solenoid/img/up.png)
: Hi,
: I'm using JAVA URL to download some data from U.S Census. I have a problem.
: http://factfinder.census.gov/servlet/AGSGeoAddressServlet?_MapEvent=&_category=&_subcategory=&_stateSelectedFromDropDown=Pennsylvania&context=ags&programYear=50%3A420&street=1383%2BLONG%2BRUN%2BRD&city=FRIEDENSBURG&states=Pennsylvania&zip=17933&geo_id=&_p
: if you copy the above url and put them into the explore. you will find the
: Census
: website would pop up a window saying "Factfinder cannot locate the address
: you
: ent
【在 l*****0 的大作中提到】
![](/moin_static193/solenoid/img/up.png)
: Hi,
: I'm using JAVA URL to download some data from U.S Census. I have a problem.
: http://factfinder.census.gov/servlet/AGSGeoAddressServlet?_MapEvent=&_category=&_subcategory=&_stateSelectedFromDropDown=Pennsylvania&context=ags&programYear=50%3A420&street=1383%2BLONG%2BRUN%2BRD&city=FRIEDENSBURG&states=Pennsylvania&zip=17933&geo_id=&_p
: if you copy the above url and put them into the explore. you will find the
: Census
: website would pop up a window saying "Factfinder cannot locate the address
: you
: ent
l*0
10 楼
in its page source code:
function checkAddressValidity() {
if (document.mapForm.IS_ADDRESS_VALID.value == "N" && document.mapForm.
street.value != "") {
alert("Factfinder cannot locate the address you entered.");
document.mapForm.street.focus()
}
what's the corresponding status code in JAVA? i mean, which class and which
method can do that?
【在 g*****g 的大作中提到】![](/moin_static193/solenoid/img/up.png)
: Usually it will return some status code and when javascript finds that
: status
: it pops up. So in java code you check that status code too.
function checkAddressValidity() {
if (document.mapForm.IS_ADDRESS_VALID.value == "N" && document.mapForm.
street.value != "") {
alert("Factfinder cannot locate the address you entered.");
document.mapForm.street.focus()
}
what's the corresponding status code in JAVA? i mean, which class and which
method can do that?
【在 g*****g 的大作中提到】
![](/moin_static193/solenoid/img/up.png)
: Usually it will return some status code and when javascript finds that
: status
: it pops up. So in java code you check that status code too.
g*g
12 楼
parse the html, that's it.
which
【在 l*****0 的大作中提到】![](/moin_static193/solenoid/img/up.png)
: in its page source code:
: function checkAddressValidity() {
: if (document.mapForm.IS_ADDRESS_VALID.value == "N" && document.mapForm.
: street.value != "") {
: alert("Factfinder cannot locate the address you entered.");
: document.mapForm.street.focus()
: }
: what's the corresponding status code in JAVA? i mean, which class and which
: method can do that?
which
【在 l*****0 的大作中提到】
![](/moin_static193/solenoid/img/up.png)
: in its page source code:
: function checkAddressValidity() {
: if (document.mapForm.IS_ADDRESS_VALID.value == "N" && document.mapForm.
: street.value != "") {
: alert("Factfinder cannot locate the address you entered.");
: document.mapForm.street.focus()
: }
: what's the corresponding status code in JAVA? i mean, which class and which
: method can do that?
g*g
16 楼
document.mapForm.IS_ADDRESS_VALID.value == N
The form value is what you should check, if you don't develop
this website, you can't expect error code.
returned
【在 l*****0 的大作中提到】![](/moin_static193/solenoid/img/up.png)
: the problem with parsing the html is that no matter whether the popup
: windows comes up or not(meaning no matter whether the server found the
: address), the return html page is the same. no error message in the returned
: page.
The form value is what you should check, if you don't develop
this website, you can't expect error code.
returned
【在 l*****0 的大作中提到】
![](/moin_static193/solenoid/img/up.png)
: the problem with parsing the html is that no matter whether the popup
: windows comes up or not(meaning no matter whether the server found the
: address), the return html page is the same. no error message in the returned
: page.
l*0
20 楼
I fixed the problem. Thanks all.
j*e
21 楼
=_=猪背岭。。。。
相关阅读
eclipse remote debug java (tomcat) , has to connect with eclipse for tomcat to start?JVM freezemade a low-level mistake就是这样,附图请教一下Flex+Java的开发环境MidiUnavailableException: No driverTwitter Search is Now 3x Faster using Java server谁给讲讲Java的版本?菜鸟问问题?priorityBlockingQueue with fairness?现在写代码还有人开着API么?昨天公司新来的java大牛终于提出load balance方案了Windows 下 Java console application 的问题Web Seminar hosted by CINAOUG on 2011/06/13 (转载)打一些debug information, 这样算不算有用的optimize?a prepared statement question来问两个HashMap的问题随机读一个大文件中的任意一行newbie question怎么快速掌握J2EE?