html

Tabbing in text boxes

How can I make a text box that allows users to enter tabs, and does not send the user to the next element when the tab button is pressed? ...

Tab or accordion based page - how is it done in the server side?

I have a web page with tabs or accordion, generated with YUI or jquery or another javascript+css framework. Say an HTML form is processed in one tab. What should the server do? Send back all the tabs, with the tab that submitted the form having the results and all the other tabs unmodified? Or what? ...

Making HTML content expand to fill the window

I have an HTML page divided vertically into Header Body Footer The body in turn is divided horizontally into A large DIV on the left surrounded by scrollbars, displaying a portion of a diagram A form on the right The header and footer are fixed-height. The body should expand vertically to fill the portion of the window not occup...

Writing XSS Filter for (X)HTML Based on White List

Hello, I need to implement a simple and efficient XSS Filter in C++ for CppCMS. I can't use existing high quality filters written in PHP because because it is high performance framework that uses C++. The basic idea is provide a filter that have a while list of HTML tags and a white list of options for these tags. For example. typical H...

IE6 ignoring active link CSS style

The CSS active link style is being correctly applied in IE7, FF, and Safari but is not applied IE6. .side_nav a.active { color:#FFFFFF; background-color:#9F1F63; } Interestingly the background color (background-color:#9F1F63;) is being applied in IE6 but not the font color (color:#FFFFFF;) Any ideas on why this is happening ...

Why does code render in code block?

I want to display HTML in a webpage. I've wrapped in a code block but the last two lines still execute/render. What am I doing wrong? <pre><code> div {background: brown;} div.bluebg {background: blue;} <div>default brown background</div> <div class="base">blue background</div> </code></pre> The last two lines were wrapped in div tag...

How To make a Form and Div have a max width of child elements.

I was wondering How To make a Form and Div have a max width of child elements. Eg in this example both the form and the outerDiv stretch the full width of the page. I would like the form and outerDiv to have a width of 200px. This becomes a problem when I have this page in an iframe, because the width of the page is larger than the ifr...

Using XSLT to output an empty HTML textarea element

When attempting to output an empty textarea element, the .NET XSLT processor collapses the element to its short form. Instead of this: <textarea id="blah" name="blah"></textarea> I get this: <textarea id="blah" name="blah"/> Which causes many web browsers (including IE and Firefox) to render the rest of the page as if it were the c...

Centering two transparent columns using CSS

So, right to the point, here's what I want (minus the poor quality)... http://www.hbperspective.com/alt3/site.jpg And here's what I've got... http://www.hbperspective.com/alt3/ I'm trying to get those two transparent columns to be centered as they are in the pic. With this CSS layout I'm having a heck of a time figuring out how to d...

How can I make an async call in Javascript onunload element?

I have a system where items are locked (with a flag in the database) when a user is vieiwing that item. Currently the item is only unlocked when a user performs a certain action. However, when a user leaves the page through any method, I'd like to make a call to a webservice / ashx page that will unlock the item, but not stop the pag...

Drawing arrows on an HTML page to visualize semantic links between textual spans

I have an HTML page with some textual spans marked up something like this ... <span id="T2" class="Protein">p50</span> ... <span id="T3" class="Protein">p65</span> ... <span id="T34" ids="T2 T3" class="Positive_regulation">recruitment</span> ... I.e. each span has an ID and refers to zero or more spans via their IDs. I would like to ...

What good is new line character?

I don't really get it: what's the purpose of a new line character? If I do this: <?php echo "This is a test. \n"; echo "This is another test."; ?> Code results in both sentences being in the same line. Why doesn't the \n causes the second sentence being in second line? The sentences are each in it's own line, if I do: <?php echo "T...

Adding additional HTML rows: where to put the code?

I have the following situation: <table><tr><td width="50"> <select name="angle"> <option value="1">1</option> <option value="2">2</option> <option value="3">3</option> <option value="4">4</option> <option value="5">5</option> <option value="6">6</option> </select> </td><td> <input type="text" name="what" value="" /> </td></tr></table> <...

Did HTML's loose standards hurt or help the internet

I was reading O'Reilly's Learning XML Book and read the following HTML was in some ways a step backward. To achieve the simplicity necessary to be truly useful, some principles of generic coding had to be sacrificed. ... To return to the ideals of generic coding, some people tried to adapt SGML for the web ... This prove...

Is it valid to have a html form inside another html form

Is it valid html to have the following: <form action="a"> <input.../> <form action="b"> <input.../> <input.../> <input.../> </form> <input.../> </form> So when you submit "b" you only get the fields within the inner form. When you submit "a" you get all fields minus those within "b". If it isn'...

Horiz CSS menu - text shifting on bold hover

Hi there, I created a horizontal CSS menu using HTML lists. i.e <ul id="navigation"> <li id="youarehere"><a href="#">Home</a></li> <li><a href="#">Home</a></li> <li><a href="#">About Us</a></li> </ul> ect... Everything works as it should, expect when you hover over the links. You see, I created a bold hover state for the links, an...

How do I (by default) style different types of labels differently?

In my forms, I want to make HTML labels bold in general, but not bold when they are labelling radio buttons and checkboxes. How can I do that in a CSS that can be imported and works by default, without requiring local overrides of the styling? Example Radio Label (should not be bold) <label for="banana"> <input type="radio" name="bana...

Flex movie overlapping other HTML

Hi, I have a Flex movie that contains a text input box and an (optional) dropdown. The design requires that this dropdown fall below the lower edge of the movie, overlapping the HTML below it. I can set wmode to transparent and can get the dropdown to overlap the HTML fine but then the HTML below is unselectable, even when the dropdown...

Why won't this form validate?

The "onsubmit" statement is not called: <form action="index.php" method="post" onsubmit="return validateSearchKeyword()"> <input class="text_search" id="text_search" name="text_search" type="text" value="search" onfocus="if (this.value=='search') this.value = ''" onBlur="if (this.value=='') this.value = 'search'" /> </form> ...

Hiding entire table resizes it

Having an HTML page with a simple table and js code to do show / hide on it: <html xmlns="http://www.w3.org/1999/xhtml"&gt; <head> <title>title</title> <script type="text/javascript"> function showErrorSteps() { var el = document.getElementById("t1"); if(el.style.display=="none") { ...