How to show hidden button with css media query?

Tags: css3,media-queries

Problem :

I have a hidden button it's means display:none. I tried with this.

@media screen and (max-width:1360px) {

Solution :

following code means: "display #menu_btn as inline-block when screen is more or equal to 1360, hide it when screen is less than 1360"


<input id="menu_btn" type="button"/>


@media screen and (min-width:1360px) {
  #menu_btn { display:inline-block; }
@media screen and (max-width:1359px) {
  #menu_btn { display:none; }

PS. remember that you cannot set inline style in html like this: <input id="menu_btn" type="button" style="display:none"/> because it will override style from media query and your button will not be displayed no matter what the screen size will be.

    CSS Howto..

    How do nested vertical margin collapses work?

    How to do HTML/CSS form helpers/popover

    How to get the table (datatable) left aligned?

    How to vertical align top in my case

    How to have menu items streched in full width menu with css for any screen automatically

    CSS - Superfish, how to float 4th level of dropdown

    how to apply transition effect in expand/collapse inside gridview rows

    How to traverse and click on Next & Cancel Button (On PopUp) using selenium webdriver

    Animated HTML,CSS JavaScript. How can I implement this [closed]

    How to avoid CSS selector applying to more than one level of descendants

    How to convert from Powerpoint to HTML / CSS ? (FOSS)

    how do i change the css property for only one row with a custom class with out removing the styles from the other rows?

    how to access anti aliasing method of a font with CSS

    How do I get MS Outlook to accept the CSS style display:block?

    How to check if an element matches the :empty pseudo-class in pure JS?

    How do I make the Android WebView not ignore the 'height' css property?

    How can i integrate php to html table

    How to control child div height of a flex item

    How to display “Classic” fractions in CSS / Javascript

    How to set Bullet colors in UL/LI html lists via CSS without using any images or span tags [duplicate]

    How to make transparent arrow? [duplicate]

    How do I link JS file from other folder to a page?

    How to make both text and image change on rollover via CSS?

    responsive html shows a tablet css design instead of the mobile when on my iphone 4s?

    How to embedded all resources(css,js,images) into one single html file?

    How to prevent left “post” section from dropping off?

    How can i make a site like this by myself? [closed]

    How do you set the scroll bar skin on a single List instance?

    How to get a reference to id=“xxx.yyy” in CSS?

    How to set icon of an page using CSS