Advertisement

04.18.2008 at 07:37AM PDT, ID: 23334293
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

9.0

how can I make this search form work?

Asked by flashactions in Hypertext Markup Language (HTML), JavaScript, Search Engines

Tags:

I work In a high school and I am working on a page for the students to do their research from.  I have combined many resources into one page, so the students can get their work done faster.  I am trying to make a search box to  search the us sensus bureau.   I have most of the code in place.  I just cant get it to go.  there are a bunch of .js files included in the head section im not sure if they are all necessary either so if you could help me determine that also that would help keep the page load time down.  
here is the link to the census bureau     http://factfinder.census.gov/home/saff/main.html?_lang=en
here is a link to the page im making.   http://mail.cpsd.us/~jgraham/home%20page.htmlStart Free Trial
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
56:
57:
58:
59:
60:
61:
62:
63:
64:
65:
66:
67:
68:
69:
70:
71:
72:
73:
74:
75:
76:
77:
78:
79:
80:
81:
82:
83:
84:
85:
86:
87:
88:
89:
90:
91:
92:
93:
94:
95:
96:
97:
98:
99:
100:
101:
102:
103:
104:
105:
106:
107:
108:
109:
110:
111:
112:
113:
114:
115:
116:
117:
118:
119:
120:
121:
122:
123:
124:
125:
126:
127:
128:
129:
130:
131:
132:
133:
134:
135:
136:
137:
138:
139:
140:
141:
142:
143:
144:
145:
146:
147:
148:
149:
150:
151:
152:
153:
154:
155:
156:
157:
158:
159:
160:
161:
162:
163:
164:
165:
166:
167:
168:
169:
170:
171:
172:
173:
174:
175:
176:
177:
178:
179:
180:
181:
182:
183:
184:
185:
186:
187:
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<html>
<head>
  <script language="JavaScript"
 src="http://factfinder.census.gov/javascript/string_util.js"
 type="text/javascript"></script>
  <script language="JavaScript"
 src="http://factfinder.census.gov/javascript/openMetadataBrowser.js"
 type="text/javascript"></script>
  <script language="JavaScript"
 src="http://factfinder.census.gov/javascript/openMetadataBrowser.js/javascript/openFeedback.js"
 type="text/javascript"></script>
  <script language="JavaScript"
 src="http://factfinder.census.gov/javascript/openMetadataBrowser.js/javascript/panel_id.js"
 type="text/javascript"></script>
  <script language="JavaScript"
 src="http://factfinder.census.gov/javascript/openMetadataBrowser.js/javascript/epss_open.js"
 type="text/javascript"></script>
  <script language="JavaScript"
 src="http://factfinder.census.gov/javascript/openMetadataBrowser.js/javascript/gotoMainPage.js"
 type="text/javascript"></script>
  <script language="JavaScript"
 src="http://factfinder.census.gov/javascript/openMetadataBrowser.js/javascript/saff/links_acs.js"
 type="text/javascript"></script>
  <script language="JavaScript"
 src="http://factfinder.census.gov/javascript/openMetadataBrowser.js/javascript/common/saffmenu.js"
 type="text/javascript"></script>
  <script language="JavaScript"
 src="http://www.census.gov/main/.in/affusclock.js"
 type="text/javascript"></script>
  <script language="JavaScript" type="text/javascript">
<!--
function hasEnoughData(Fld, minLength) {
return (Fld.value.length > minLength) ? true : (Fld.value.indexOf("*") == -1);
}
function hasValidSearchDataNameSearch(countyFld,stateFld) {
var isValidSearchCriteria = true;
var errMsg = "";
var hasCounty = !stringEmpty(countyFld.value);
var hasState = !stringEmpty(stateFld.value); var hCount = 0;
/* work around ns4 issue; element 0 is "- select a state -" */
if (ns4 && !ns5) {
hasState = (stateFld.selectedIndex != 0);
}
if (errMsg == "" && hasCounty && !hasEnoughData(countyFld, 2)) {
if (!hasState) {
errMsg = "Enter either a state or at least two characters in the city/town, county, or zip field. Click 'Go'.";
isValidSearchCriteria = false; }
}
if (errMsg == "" && !hasCounty && !hasState) {
errMsg = "Enter either a state or at least two characters in the city/town, county, or zip field. Click 'Go'.";
isValidSearchCriteria = false; }
if (!isValidSearchCriteria) {
alert(errMsg);
} return isValidSearchCriteria;
}
function mpGeoSearch() {
var termFld = document.fact_sheet_form._search_term;
var stateFld = document.fact_sheet_form._search_state;
termFld.value = trimStringBothSides(termFld.value, " ");
stateFld.value = trimStringBothSides(stateFld.value, " ");
if (termFld.value == "" && stateFld.value == "") {
alert("Enter information in one or both fields. Click 'Go'.");
return;
}
if (hasValidSearchDataNameSearch(termFld, stateFld)) {
document.hidden_geo_search_form._state.value = stateFld.value;
if (termFld.value.match(/^\d\d\d\d\d$/) ||
termFld.value.match(/^\d\d\dHH$/) ||
termFld.value.match(/^\d\d\dXX$/)) {
document.hidden_geo_search_form._zip.value = termFld.value;
document.hidden_geo_search_form._county.value = termFld.value;
document.hidden_geo_search_form._cityTown.value = termFld.value;
}
else {
document.hidden_geo_search_form._zip.value = '';
document.hidden_geo_search_form._county.value = termFld.value;
document.hidden_geo_search_form._cityTown.value = termFld.value;
}
// work around ns4 issue
if (ns4 && !ns5) {
document.hidden_navigation_form._state.value = stateFld.options[stateFld.selectedIndex].value;
} document.hidden_geo_search_form.submit();
}
return;
}
-->
  </script>
  <title>census</title>
</head>
<body>
<div class="geosearch-mp">
Get a <b style="color: rgb(68, 68, 68);">Fact Sheet</b>
for your community...<br>
<form name="fact_sheet_form" method="get"
 style="display: inline;" action=""
 onsubmit="mpGeoSearch(); return false;">
  <table style="margin-top: 5px;" border="0"
 cellpadding="3" cellspacing="0">
    <tbody>
      <tr>
        <td align="right"><span class="selgeolabel"
 style="line-height: 100%;"><label for="tx_city_cnty">city/
town,<br>
county, or zip</label></span></td>
        <td><input name="_search_term" id="tx_city_cnty"
 value="" size="24" type="text"></td>
      </tr>
      <tr>
        <td align="right"><span class="selgeolabel"
 style="line-height: 100%;"><label for="lb_state">state</label></span></td>
        <td>
        <select name="_search_state" id="lb_state"
 onkeypress="if (isEnterKey(event)) { mpGeoSearch(); }">
        <option value="">-- select a state --</option>
        <option value="04000US01">Alabama</option>
        <option value="04000US02">Alaska</option>
        <option value="04000US04">Arizona</option>
        <option value="04000US05">Arkansas</option>
        <option value="04000US06">California</option>
        <option value="04000US08">Colorado</option>
        <option value="04000US09">Connecticut</option>
        <option value="04000US10">Delaware</option>
        <option value="04000US11">District of Columbia</option>
        <option value="04000US12">Florida</option>
        <option value="04000US13">Georgia</option>
        <option value="04000US15">Hawaii</option>
        <option value="04000US16">Idaho</option>
        <option value="04000US17">Illinois</option>
        <option value="04000US18">Indiana</option>
        <option value="04000US19">Iowa</option>
        <option value="04000US20">Kansas</option>
        <option value="04000US21">Kentucky</option>
        <option value="04000US22">Louisiana</option>
        <option value="04000US23">Maine</option>
        <option value="04000US24">Maryland</option>
        <option value="04000US25">Massachusetts</option>
        <option value="04000US26">Michigan</option>
        <option value="04000US27">Minnesota</option>
        <option value="04000US28">Mississippi</option>
        <option value="04000US29">Missouri</option>
        <option value="04000US30">Montana</option>
        <option value="04000US31">Nebraska</option>
        <option value="04000US32">Nevada</option>
        <option value="04000US33">New Hampshire</option>
        <option value="04000US34">New Jersey</option>
        <option value="04000US35">New Mexico</option>
        <option value="04000US36">New York</option>
        <option value="04000US37">North Carolina</option>
        <option value="04000US38">North Dakota</option>
        <option value="04000US39">Ohio</option>
        <option value="04000US40">Oklahoma</option>
        <option value="04000US41">Oregon</option>
        <option value="04000US42">Pennsylvania</option>
        <option value="04000US72">Puerto Rico</option>
        <option value="04000US44">Rhode Island</option>
        <option value="04000US45">South Carolina</option>
        <option value="04000US46">South Dakota</option>
        <option value="04000US47">Tennessee</option>
        <option value="04000US48">Texas</option>
        <option value="04000US49">Utah</option>
        <option value="04000US50">Vermont</option>
        <option value="04000US51">Virginia</option>
        <option value="04000US53">Washington</option>
        <option value="04000US54">West Virginia</option>
        <option value="04000US55">Wisconsin</option>
        <option value="04000US56">Wyoming</option>
        </select>
        <img src="http://factfinder.census.gov/img/1px.gif"
 alt="" height="1" width="9"><a
 href="javascript:mpGeoSearch()"><img
 src="http://factfinder.census.gov/img/saff/en/go_btn_mp.gif"
 alt="GO" id="btn_fact_sheet_go" align="top"
 border="0" height="19" width="23"></a></td>
      </tr>
    </tbody>
  </table>
  <div style="margin: -1px 20px 0pt 0pt; text-align: right;">
  <a
 href="http://factfinder.census.gov/jsp/saff/SAFFInfo.jsp?_pageId=gn10_select_state"
 class="selgeolabel">or select a state using a map »</a>
  </div>
</form>
</div>
<br>
</body>
</html>
[+][-]04.18.2008 at 07:52AM PDT, ID: 21386302

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 7-day free trial to view this Administrative Comment or ask the Experts your question.

 
[+][-]04.18.2008 at 07:58AM PDT, ID: 21386351

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04.18.2008 at 08:00AM PDT, ID: 21386380

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.18.2008 at 08:05AM PDT, ID: 21386419

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04.18.2008 at 10:50AM PDT, ID: 21388090

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04.19.2008 at 04:07AM PDT, ID: 21391913

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: Hypertext Markup Language (HTML), JavaScript, Search Engines
Tags: html and java
Sign Up Now!
Solution Provided By: tanwaising
Participating Experts: 3
Solution Grade: A
 
 
[+][-]04.19.2008 at 08:17AM PDT, ID: 21392808

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628