Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

HTML Table problem...

Posted on 2003-12-08
6
Medium Priority
?
206 Views
Last Modified: 2010-04-01
All right it might not be the right area to ask this question but I am not sure where else it can be answered:
First let me explain what I am trying to accomplish.....

We have have a enterprize application which uses Grids ( tables) very extensively... I have made a frame work so that these grids can be written without coding anything...
Here is how it works..
First user goes to a HTML page where he/she filles out a form which asks questions like, rows per page, wheather its a Query or a stored procedure call number of columns to be shown, name of these columns and so on...

This information is saved in a XML file at the server upon submit.

At the runtime when grid is requested, This XML file is read and system makes a connection to Host ( AS/400) to get the Resultset, This result set is then converted to XML and then a generic XSL is applied to it to create the HTML output to the browser.
Okay so much for useless details...
Problem is that user may want to hide some columns when the table is displayed ( it might be necessary to have that data for other technical functions but user have no use to it.. for example. record written date or something like this).

now when I try to hide that particular TD of table, it leaves a gray area which messes up the whole layout of table....!!
Since the XSL is generic I can not make every column width specefic..
So is there any way to handle this situation.... Currently I am using a CSS to put the Styling on TDs...
CSS for Hidden column looks something like this..

.gridHidden
{
    visibility: hidden;
    pixelHight:0;
    pixelWidth:0;      
    FONT-FAMILY: verdana,arial,sans-serif;
    FONT-SIZE: 0pt;
    FONT-STYLE: none;
    FONT-WEIGHT: normal;
    LINE-HEIGHT: 0pt;    
   TEXT-INDENT: 0px
}

I can provide you other details as well if needed..
Thanks for all your help in advance!!
0
Comment
Question by:Kuldeepchaturvedi
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
6 Comments
 
LVL 15

Expert Comment

by:jimmack
ID: 9895435
Since you offer to provide more detail, I will ask a question ;-)

I assume that you have some information somewhere that identifies whether a column is hidden or not.  Would it not be possible to simply not display the TD at all, rather than trying to hide it?
0
 
LVL 19

Author Comment

by:Kuldeepchaturvedi
ID: 9895522
Yes it is absolutely possible but then the purpose of hiding it is gone...! It is being hided so that user can not see it but when a function tries to do a cell[8].innerText.. this data should be available for processing.....
If I eliminate the TD altogether then I will loose the information also which is needed for technical processing..
0
 
LVL 15

Expert Comment

by:jimmack
ID: 9895542
I understand ;-)
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
LVL 15

Accepted Solution

by:
jimmack earned 2000 total points
ID: 9895620
Maybe this might help (I'm no CSS expert ;-))

http://www.w3.org/TR/REC-CSS2/tables.html#q4

"If the 'visibility' of a column is set to 'collapse', none of the cells in the column are rendered"
0
 
LVL 19

Author Comment

by:Kuldeepchaturvedi
ID: 9895678
Hmm..........
you know what.... that Collapse thing does not work but don't worry you gave me the pointer in very right direction.....:-)
This is what W3c have to say about it....

The 'visibility' property specifies whether the boxes generated by an element are rendered. Invisible boxes still affect layout (set the 'display' property to 'none' to suppress box generation altogether). Values have the following meanings:


so if I do the
display:none in my CSS the gray area is gone...!!!! ironic thing is that I was using this property already on some of the form elements......It never occured to me that it will work with tables too............


Thanks for your pointers..... so now do you want points for using google....:-) ( just kidding) you were helpfull....

Cheers
0
 
LVL 15

Expert Comment

by:jimmack
ID: 9895717
;-)

Thanx Kuldeepchaturvedi.  It's one of those things.  Sometimes it just helps to explain a problem to someone with no similar experience and see what they come up with.  I'm glad I could at least be of some assistance ;-)
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Read on to get a few ideas on how to promote your next corporate event.
Want to know how to use Exchange Server Eseutil command? Go through this article as it gives you the know-how.
Video by: ITPro.TV
In this episode Don builds upon the troubleshooting techniques by demonstrating how to properly monitor a vSphere deployment to detect problems before they occur. He begins the show using tools found within the vSphere suite as ends the show demonst…
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Suggested Courses

715 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question