Go Back   TechArena Community > Software > Software Development
Become a Member!
Forgot your username/password?
Tags Active Topics RSS Search Mark Forums Read

Reply
 
Thread Tools Search this Thread
  #1  
Old 04-08-2009
Member
 
Join Date: Nov 2008
Posts: 97
How to make the javascript style visible

I have a javascript function that basically hides or displays fields according to a filter. and I need to write javascript for those controls for validation. I'm doing this by trying to execute a series of style.visible="visible" & "hidden" statements. Is it possible to generate dynamically a html file which will contain only <div> tags of which contents are hidden from user.
Reply With Quote
  #2  
Old 04-08-2009
Member
 
Join Date: Mar 2008
Posts: 258
Re: How to make the javascript style visible

There are basically two different ways of hiding elements - you can either set their visibility to "hidden", or you can set their display to "none". CSS "visibility" property hides an element but retains its space in the flow of the document.
Reply With Quote
  #3  
Old 04-08-2009
Member
 
Join Date: Jan 2006
Posts: 211
Re: How to make the javascript style visible

Basically there are many ways to Visible/hide, render/not render a control For ASP.NET webcontrols, this is because i have tried it out in ASP.NET and not so aware about the javascript, but am sure that you have the Visible property which can be set to true or false but that's serverside. The visibility option doesn't alter any other elements around or after the element, whereas the display option will "collapse" the element so to speak.
Reply With Quote
  #4  
Old 04-08-2009
Member
 
Join Date: Mar 2008
Posts: 227
Re: How to make the javascript style visible

This could also be done by writing the asp:Button will cause a postback and you can make controls visible property true/false server side. Identify each line with an id or class and turn each one on/off as required. Then you can turn each line on/off using javascript and display:none or hidden as required.
Reply With Quote
Reply

  TechArena Community > Software > Software Development
Tags: , , ,



Thread Tools Search this Thread
Search this Thread:

Advanced Search


Similar Threads for: "How to make the javascript style visible"
Thread Thread Starter Forum Replies Last Post
How to make single page into Landscape page style and rest of them in default style in OpenOffice? Hridayeshu Windows Software 4 19-02-2012 04:29 PM
Does a own Domain Name make your website more visible Kiran25 Technology & Internet 8 24-09-2011 10:24 PM
Cufon javascript replace isn't replacing the correct style in my Luis-Fernando Software Development 6 18-05-2010 12:25 AM
Javascript Change Style Berth Software Development 3 18-09-2009 03:00 PM
How to make Tables visible in Javascript Jannat Software Development 2 13-02-2009 07:44 PM


All times are GMT +5.5. The time now is 02:21 PM.