How i can replace icon with text when i resize browser

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • hetal nirmal
    New Member
    • Aug 2014
    • 1

    How i can replace icon with text when i resize browser

    when i add address on website make it responsive i want to text to be resized in icon how can i do it with css
  • Exequiel
    Contributor
    • Jul 2012
    • 288

    #2
    you can hide the text or set display:none; on the text element that you want to to change by icon, and show the icon using ur css code, set display:block; to the icon, but the icon must be in a display:none; in your css.

    Comment

    • Exequiel
      Contributor
      • Jul 2012
      • 288

      #3
      You can try this code. :)
      Code:
      <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
      <html xmlns="http://www.w3.org/1999/xhtml">
      <head>
      <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
      <title>Zick Sample</title>
      <style>
      img.icon{display:block; width:55px; height:55px;}
      p{display:none;}
      @media only screen and (max-width: 600px) {
      	img.icon{display:none;}
      	p{display:block;}
      }
      
      </style>
      </head>
      
      <body>
      	<img src="GCC new logo - Copy.bmp" class="icon"/>
          <p>Text</p>
      </body>
      </html>
      
      </html>

      Comment

      • Exequiel
        Contributor
        • Jul 2012
        • 288

        #4
        goodluck, I hope it helps. :)

        Comment

        Working...