473,397 Members | 1,961 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,397 software developers and data experts.

Problem with TABLE WIDTH

Ian
I currently have a web site that is reading from a MySQL database and
displays the results of a database search as an HTML TABLE. Everything
works fine but there is an irritation I am trying to work round. Some
of the time all the displayed information in the table will fit into a
screensize of 1024 (or whatever the users browser/screensize is set to)
but on other occasions it doesn't and various fields are then
automatically wrapped round within their cells. One very simple way
round this is to set the table width to be greater than the screensize
but what I would really like to have is that the TABLE is automatically
set to whatever size it needs, irrespective of whether it exceeds the
width of the user's browser screen. Is there any easy way of doing this
?
Jul 23 '05 #1
3 4379
Ian wrote:
I currently have a web site that is reading from a MySQL database and
displays the results of a database search as an HTML TABLE. Everything
works fine but there is an irritation I am trying to work round. Some
of the time all the displayed information in the table will fit
Tabular information - in general - may be difficult to get
to fit in one screenful. How many columns?

into a screensize of 1024
The regulars in this NG "love" pixels...

(or whatever the users browser/screensize is set to)
but on other occasions it doesn't and various fields are then
automatically wrapped round within their cells.
Without seeing your table, two choices: the text clips,
or the text wraps.

One very simple way
round this is to set the table width to be greater than the screensize
What? 105% or 1600px x 1.0000000001 ?

but what I would really like to have is that the TABLE is automatically
set to whatever size it needs, irrespective of whether it exceeds the
width of the user's browser screen. Is there any easy way of doing this
?


Well, that just what html tables do: browsers size
it just that way (whatever size needed). Percentages
may be useful.
--
Juha Häikiö
Jul 23 '05 #2

Ian wrote:

I currently have a web site that is reading from a MySQL database and
displays the results of a database search as an HTML TABLE. Everything
works fine but there is an irritation I am trying to work round. Some
of the time all the displayed information in the table will fit into a
screensize of 1024 (or whatever the users browser/screensize is set to)
but on other occasions it doesn't and various fields are then
automatically wrapped round within their cells. One very simple way
round this is to set the table width to be greater than the screensize
but what I would really like to have is that the TABLE is automatically
set to whatever size it needs, irrespective of whether it exceeds the
width of the user's browser screen. Is there any easy way of doing
this
?


You would have to modify the script that outputs the table in such way
that it will adjust the type size (easier to do it with CSS) when the
amount of symbols combined across all the fields in one row is greater
than a certain number. Can't give you that number because don't know how
many columns and how much text (any graphics?) we are talking about.
Sincerely,
Dmitri
http://www.1-script.com/1_search/
Get search engine for your site
http://www.1-script.com/install/
Check out my CGI scripts installation offer

-------------------------------------


##-----------------------------------------------##
Article posted with Web Developer's USENET Archive
http://www.1-script.com/forums
no-spam read and post WWW interface to your favorite newsgroup -
comp.infosystems.www.authoring.html - 7452 messages and counting!
##-----------------------------------------------##
Jul 23 '05 #3

"Ian" <ia*@nospam.com> wrote in message
news:jc********************************@4ax.com...
I currently have a web site that is reading from a MySQL database and
displays the results of a database search as an HTML TABLE. Everything
works fine but there is an irritation I am trying to work round. Some
of the time all the displayed information in the table will fit into a
screensize of 1024 (or whatever the users browser/screensize is set to)
but on other occasions it doesn't and various fields are then
automatically wrapped round within their cells. One very simple way
round this is to set the table width to be greater than the screensize
but what I would really like to have is that the TABLE is automatically
set to whatever size it needs, irrespective of whether it exceeds the
width of the user's browser screen. Is there any easy way of doing this
?


In CSS:

white-space: nowrap;

http://www.w3.org/TR/CSS2/text.html#white-space-prop

Jul 23 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Max | last post by:
Hello. This is the first time I've posted to a newsgroup, and I do this because I'm in desperate need of help. I'm working a user management system, and when I activate a user that has registered...
3
by: Robert Dell | last post by:
I have a problem comparing strings in an order form i'm writing. I want to give a running total at the bottom of the page and it appears to be working except it doesn't compare correctly (it...
0
by: Thomas Scheiderich | last post by:
I have a table that has 3 image slices. The middle slice changes size based on size of browser window. This works great. My client wants the date to show over the image on the right. So what I...
20
by: Development - multi.art.studio | last post by:
Hello everyone, i just upgraded my old postgres-database from version 7.1 to 7.4.2. i dumped out my 7.1 database (with pg_dump from 7.1) as an sql-file with copy-commands and to one file using...
2
by: nino9stars | last post by:
Hello, I have just started messing with absolute positioning on webpages, and it definitely let's you do some creative things. Well, after much searching and help, I got the images I was using...
1
by: Trev | last post by:
Hi, I'm hoping that someone in this group can shed some light on an issue I'm having with a Formview. I have a Web User Control (.ascx) with a Formview. The Formview contains 2 Multiviews,...
5
by: althafexcel | last post by:
hi everyone Im trying to include an external js in my aspx page under the head tag, it doesn't load or it displays an object expected error whenver the function from the .js is called. Actually...
0
by: sjickells | last post by:
Hi I am having a problem using asp:TextBox's in a transparent table. I have a background image on the page and a table in the middle of the page. I have set the background colour of the table...
1
by: kchaitanya | last post by:
I have created a master page. When I am adding this master page to .aspx files which are in the root directory, it is working fine. When , I am adding master page to .aspx files which are in sub...
3
omerbutt
by: omerbutt | last post by:
hi there i have downloaded a prototype tooltip from http://www.nickstakenburg.com/projects/prototip/ the logic it uses is to call the script after creating the <div> for example i am using the...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.