SELECT下拉菜单,无需JavaScript即可重定向 [英] SELECT Dropdown that redirects without Javascript

查看:109
本文介绍了SELECT下拉菜单,无需JavaScript即可重定向的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

可以创建一个下拉列表,当用户选择没有javascript的选项时,可以重定向用户?

Is it possible to create a dropdown that redirects the user when he selects an option without javascript?

当用户在下拉列表A中选择类别时,我会显示下拉列表B(有子类)与Javascript。我想让它的工作类似的用户没有Javascript。我的想法是在第一个下拉菜单中选择一个选项时将用户重定向到不同的页面。

When the user selects a category in dropdown A, I display dropdown B (which has subcategories) with Javascript. I want to make it work similarly for users without Javascript. My idea is to redirect users to different pages when they choose an option in the first dropdown.

这是不是没有javascript?怎么办? (如果可能的话,建议不要)

Is this possible without javascript? How can it be done? (if not if possible suggest something)

推荐答案

最简约的解决方案是在HTML中使用内联JS。

No. The most minimalistic solution is using inline JS in the HTML.

注意:您要支持哪种浏览器?即使IE7具有您需要的JS支持。

Note: which kind of browser do you want to support? Even IE7 has the JS support you need.

这篇关于SELECT下拉菜单,无需JavaScript即可重定向的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆