[英]How do I make it so that a drop-down menu only shows at half or quarter window size?
Like on IGN I would like to make it so that within my E-Magazine I can change the top tabs from the line layout, to a drop down menu, like IGN does when the website window is made too small.就像在IGN 上一样,我想在我的电子杂志中将顶部选项卡从行布局更改为下拉菜单,就像 IGN 在网站窗口过小时所做的那样。
I haven't tried this, I have researched it but haven't found anything that I have felt comfortable trying.我没有尝试过这个,我已经研究过它,但没有发现任何让我感到舒服的尝试。 However, here is the current code I have:但是,这是我拥有的当前代码:
<h5 id="tabdiv"> <a href="index.html">Home</a>    <a href="reviews.html">Reviews</a>    <a href="interviews.html">interviews</a>    <a href="apply.html">Apply</a>    <a href="login register.html">Login / Sign Up</a>
Here is an example of how to make a dropdown with HTML这是如何使用 HTML 创建下拉列表的示例
select.example { max-width: 15%; }
<select class="example"> <option value="stackoverflow">Stackoverflow</option> <option value="google">Google</option> <option value="yahoo">Yahoo</option> <option value="wired">Wired</option> <option value="theoatmeal">The Oatmeal</option> </select>
With your stuff being in an E-zine, the style=""
tag will probably have to be utilized.如果您的内容在电子杂志中,则可能必须使用style=""
标签。 <select class="example" style="max-width: 15%;">
Without knowing more all I can do it give you basics that you should honestly know before you even post here.在不了解更多信息的情况下,我可以为您提供一些基础知识,您甚至在在这里发帖之前就应该诚实地了解这些基础知识。 You have to learn and make your own attempt so we can see what you need exactly.您必须学习并进行自己的尝试,这样我们才能准确了解您的需求。
Posting un-related code that is contrary to what you're trying to do doesn't really help us help you much.发布与您正在尝试做的事情相反的不相关代码并不能真正帮助我们为您提供多少帮助。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.