Navigaton使用联系表并选择

时间:2018-11-30 15:08:53

标签: javascript html

我有一个使用select下拉菜单的联系表,我希望选择选项中的On,我希望它导航到其他网站。选择后,我只希望“即将到来”选项导航到其他网站。下面是我的HTML代码:

<div class="container">
            <h2>Contact US</h2>
        <div class="contact-form">

            <div class="col-md-8 contact-grid">
                <form action="form-process.php" method="POST">
                    <input name="name" type="text" value="Name" onfocus="this.value='';" onblur="if (this.value == '') {this.value ='name';}">
                    <br>
                    <input name="email" type="text" value="Email" onfocus="this.value='';" onblur="if (this.value == '') {this.value ='email';}">
                    <br>
                    <select id="contact" name="dropdown" onchange="javascript:handleOption(this)">
                        <option value="crew/gang">Crew/Gang</option>
                        <option value="nc maphia">NC Maphia</option>
                        <option value="reddeadredemption/index">Coming Soon</option>
                    </select><br>
                    <select id="contact" name="dropdown2">
                        <option value="game">Game</option>
                        <option value="grand theft auto v">Grand Theft Auto V</option>
                        <option value="red dead redemption ii">Red Dead Redemption II</option>
                    </select><br>
                    <select id="contact" name="dropdown3">
                        <option value="reason for contacting us">Reason for contacting us?</option>
                        <option value="joining nc maphia">Joining NC Maphia</option>
                        <option value="recruitment requirments">Recruitment Requirments</option>
                        <option value="events">Events</option>
                        <option value="report a member">Report A Member</option>
                        <option value="webmaster">Webmaster</option>
                        <option value="general inquiry">General Inquiry</option>
                    </select><br>
                    <input name="subject" type="text" value="Subject" onfocus="this.value='';" onblur="if (this.value == '') {this.value ='subject';}">
                    <br>
                    <textarea name="message" cols="77" rows="6" value=" " onfocus="this.value='';" onblur="if (this.value == '') {this.value = 'message';}">Message</textarea>
                    <div class="send">
                        <input type="submit" value="Send" >
                    </div>
                </form>
            </div>
            <div class="col-md-4 contact-in">

                    <div class="address-more">
                    <h4>Address</h4>
                        <p>Maze Bank Tower,</p>
                        <p>Los Santos,</p>
                        <p>America </p>
                    </div>
                    <div class="address-more">
                    <h4>Chat With Us</h4>
                        <p>PSN: Kyle-The-Gunman9</p>
                        <p>PSN: NC_Maphia</p>
                        <p>Email:<a href="mailto:info@ncmaphia.co.uk"> info@ncmaphia.co.uk</a></p>
                    </div>

            </div>
            <div class="clearfix"> </div>
        </div>
    </div>
    <script type="text/javascript">
        function handleOption(elm)
        {
            window.location = elm.value+".html";
        }
    </script>
    <div class="map">
            <iframe src="https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d37494223.23909492!2d103!3d55!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x453c569a896724fb%3A0x1409fdf86611f613!2sRussia!5e0!3m2!1sen!2sin!4v1415776049771"></iframe>
        </div>
</div>

预先感谢您的帮助。

0 个答案:

没有答案