How to call this JS? _PHP Tutorial
Jul 13, 2016 am 10:51 AM
How to call this JS?
As shown in the picture, there are two sets of cascading menus for cities across the country: "Departure" and "Destination",
The cascading menu of cities across the country is made into a js file: city.js,
I currently successfully call the city.js file in the cascading menu of the "Departure" group, but failed to call city.js in the cascading menu of the "Destination" group,
May I ask how experts solve this problem?
Thanks! ~! ~
The form code is as follows:
form id="form1" name="search" method="post" action="">
Departure point:
Destination:
[ ]
Let me answer
Attachment: Your user group cannot download or view attachments
D8888D reply content------------------------------------------------- ----------
Thanks for your advice! ~
Please! ~
D8888D reply content------------------------------------------------- ----------
To all the heroes and heroes from all walks of life, please leave your comments as you pass by in a hurry. Thank you! ~! ~
D8888D reply content------------------------------------------------- ----------
I have to sigh deeply, no expert has given me a suggestive reply for two days,
Really disappointed! ~! ~
D8888D reply content------------------------------------------------- ----------
This is the first time I see someone who only posted pictures but no code - -!
D8888D reply content------------------------------------------------- ----------
OK, I'll post the code! ~! ~
D8888D reply content------------------------------------------------- ----------
I want to help you...but I'm a newbie...I really can't help you[img]http://www.111cn.cn/bbs/images/smilies/default/sad.gif[/img]
D8888D reply content------------------------------------------------- ----------
Code like yours may make everyone dizzy, but I have a piece of code that should be more practical. It has high portability. You can refer to it. It is also better maintained and supports unlimited classification: [url=http://yuepin.com /Explore/city.php] The link is marked http://yuepin.com/Explore/city.php[/url]. If you have any questions, you can ask them
I uploaded the file for sharing. Because it is fully JS output, you can also save the page
[ ]
Attachment: Your user group cannot download or view attachments
D8888D reply content------------------------------------------------- ----------
In fact, the implementation is very simple and can be done with ajax. The following technologies are mainly used:
select's ID.options.add(new Option("text",value));
D8888D reply content------------------------------------------------- ----------
Two identical IDs are both s1, which is the reason for failure. I want to help you change it, but this ID is defined, hoho....
Reorganize your object IDs. Too confusing.

Hot Article

Hot tools Tags

Hot Article

Hot Article Tags

Notepad++7.3.1
Easy-to-use and free code editor

SublimeText3 Chinese version
Chinese version, very easy to use

Zend Studio 13.0.1
Powerful PHP integrated development environment

Dreamweaver CS6
Visual web development tools

SublimeText3 Mac version
God-level code editing software (SublimeText3)

Hot Topics

Windows 11: The easy way to import and export start layouts

How to Default 'Show More Options' in Windows 11's Right-Click Menu

How to use Python to call Baidu Map API to implement geographical location query function?

Source code exploration: How are objects called in Python?

ASUS motherboard options compatible with R55600 (including R55600u and 5600h)

Which one is better, Celeron g4900 or i36100? (Which one is better, Celeron g4900 or i34170?)

PHP camera calling skills: How to implement multi-camera switching
