width

Jquery: add the width of all image elements within a container

Hey everyone, I have an idea of how I might do this but I was wondering if anyone had a better thought or could help me out. I have an unordered list with a varying number of images dynamically generated within them. I'd like to add the width of each image and set the containing unordered list width to that value. For example, if thr...

problem with width:50% when border != none (CSS)

problem with width:50% when border != none take a look http://jsfiddle.net/5nYSf/ result should be like this ...

Is it possible to override the minimum width of a button in Safari on iPad?

I have the following HTML-page: <html> <head><style> * { margin: 0; padding: 0; border: none; } button { width: 14px; background: #F00; } </style></head> <body> <button></button> <button></button> <button></button> </body> </html> When I run this code in any desktop browser, it works perfectly; the buttons are 14 pixels wide...

CSS 100% width on browser resize

Hi all I'm trying to build a layout using CSS and I'm coming up against a strange problem. Well strange for me. I have 3 divs a Header, a Footer and a MainContent area. Header and Footer must remain at a constant width of 100% while the MainContent area must be fixed centrally at 996px; This is all fine however when I resize the browser ...

BlackBerry web app - 100% width not filling screen

Hey everyone, I'm working on a mobile web app and I've noticed on both my test phones, which are BlackBerry 9700 Bold (OS 5.0) and BlackBerry Tour 9630 (OS 4.7) do not render width properly. I have a simple table that I've declared to be width 100%, but the table doesn't expand and take up 100% of the screen. There is a gutter / white...

Div width 100% but want an anchor inside to only be 85px wide??

I have a div at 100%, in order to center things i have an anchor tag inside i only want at 85px width, but it is not recognizing this and will just expand based on the length of text that is in the anchor tag. HTML: <div class="players_names"> <a class="player_name" href="#">34 J. Langenbrunner</a><br /> <a class="team_name" h...

How to have 2 HTML block elements (with varying widths) "inline", covering the entire with of the parent element?

Hi there, how can I have 2 block elements ("block" because I want to apply a background image to one of them) aligned (one on the left, one on the right), where: the width of the left element is defined by the text line it contains (can vary...) the width of the right element takes up the rest of the total width the total width is fix...

how can we make a div take width according to its content automatically

I want to create an effect like that of fieldset and label. When the headings change along the side, the width that the white background of the heading remains the same. If I can make the heading or div element to take the width enough to fit its content, it will give the proper effect. If there is any other solution please let me...

How to view width of element while animating?

Hi. I animate simply object using: $("#progress").animate({width:400},2000) Than i also want to view it's width like that $("#loadingpro").html(pro+"%"); pro = Math.round(procent$("#progress").width()/4); But when I am doing it like that it's start to delay whole cpu so much that it is not possible to do it at all. Any ideas how...

get current width of html form using javascript

I want to get the current width of an html form using javascript. I'm writing this in asp.net Form definition: <form id="form1" runat="server"> What I an trying: document.getElementById('form1').style.width Keep producing a runtime error... Any ideas? Thanks! ...

Jquery: IE window width

my computer screen width is 1280 but why IE says it's 1259 but other browsers say 1280 with widht();? $(document).ready(function(){ alert($(window).width()); }); can it be fixed for IE?? have a look here, http://ec-ener.eu/dump/index3.php Thank, Lau ...

Set Width of WPF DataGridCell individually for each cell?

Hello, I have a DataGrid with ONE column. The ItemsPanelTemplate of the DataGrid is in a WrapPanel so the rows are aligned horizontally. Each Cell of the "Row" has the same width, is it possible that every string in the cell takes only the space it needs so I have cells with a short/long width? ...

setting width of div jquery

I'm trying to set the width of a div using jquery. this is how I'm trying to set the size of the div $('#page').css("width",data[0]['imageWidth']); and this is the div I'm trying to set <div id="page"> </div> any help with this would be much appreciated ...

How do I span two divs side-by-side for the full screen width?

There are a lot of questions regarding side-by-side divs. I didn't miss those. But I need something that spans the whole width of the screen. This is the situation: I need three divs positioned side-by-side. The left, middle, and right divs we'll call them. The middle div holds the header contents of the site and is a fixed width (800px...

get div current (rendered) width with javascript.

Hey, Ive got an php script dragging some images from a database and displaying them using float:left; so they go left to right. However unless in the css i define i width for the container they jump down onto a 2nd line. So the question IS! How for the life of me could I get it to figure out the width of the content and then set the w...

A WPF RichTextBox + Button in a StackPanel => what a mess ?

This code: <StackPanel Orientation="Horizontal"> <RichTextBox /> <Button Content="Dialog" /> </StackPanel> shows the button somewhere on the left side of the StackPanel ONTO the RichTextBox, WHY? edit: Oh I just saw its a width problem. The RTB has nearly no width and the button is righth...

HTML Table column width practices

What are good practices when selecting column widths in a table? Let's say I have four columns, name (variable width), description (long content of text), count (max 3 chars), date (fixed format). What would be a good practice? I'm thinking fixed width for descr., count and width (thus actually also making name "fixed" width). But my re...

How to: Mobile Layout Snaps Width

I am trying to create a mobile web page layout similar to http://m.espn.go.com What is nice about the site is that it re-sizes the width to fit the device's width. It snaps right to the correct size so that the user does not have to zoom in. It also uses a CSS drop-down effect. I have searched around, and everything so far does not wor...

Delphi 6: TImage Width and Height properties report wrong values?

I'm having a fairly strange problem with a TImage component's width and height properties. As a test, I draw a red dot in (what is supposed to be) the center of the TImage component by taking the midpoint of the TImage's width and height and drawing the dot there so that it is centered (centerPoint2D is a TPoint): // The center point i...

Split screen into 4 rectangles with 50% height 50% width

I am having trouble splitting a screen into 4 divs with width and height of 50%. It's no problem to get the 50% width and float them around, but how can I get each of them to have a height of 50% of the screen? ...