html

html input button style CSS3

I saw some results via the related questions but didn't actually seem to show what I want. Looking for a way to simply style the button in all major broswers easily. <input type="file" name="file" id="file" size="29" class="formButton" /> <span class="smalltext">(.txt only)</span> I want the browse button to use the CSS, I have seen...

Javascript, Fire Function on click.

Hi, I'm new to javascript and I am attempting to create an element with certain html inside. This is my code: function newTask() { var newtask = document.CreateElement('li'); newtask.setAttribute('id','newtask'); newtask.innerHTML="DeveloperSnippets"; document.getElementById('newtaskcontainer').appen...

How to replace all empty <img src=""> on a page with JavaScript on dom loaded?

Hey everybody, I need a function, that starts, when the DOM is loaded. In my HTML Page are several empty Image Tags, like and I want to add an Image-Name into the src-property when everything is loaded to get something like <img src="blank.jpg">. Best wishes Chris ...

Is there a library/tool to manage themeable CSS for ASP.NET applications?

Suppose I have an application with multiple instalations that share the same CSS schema. Each of these applications would have the same CSS files with differente colors. I'm thinking of the following solution: Instead of referencing real colors, I'd reference <%variable names%> inside the CSS files. These CSS files, as already mention...

Select a row based on the contents of a cell with xpath

I have a table that consists of multiple rows that each contain 5 cells, like this: <tr> <td></td> <td>123456</td> <td>statusText</td> <td><a>linkText</a></td> <td>editButton</td> </tr> The 123456 could be any string of random letters and numbers. I want to be able to select a link based on the contents of the sec...

Javascript click through element

There is a semitransparent overlay div covering document which destroys on click, but I need somehow to trigger onlick events of the element beneath overlay at the same time. Is there a way to click on specific coordinates with JS, or maybe determine underlying element having absolute x and y positions? Thanks. ...

SEO - is long link content a good idea?

the link: <a href="http://site.com/category/the-post-title"&gt; <img src="http://site.com/image.jpg />Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit lobortis nisl...

Allow users to select an arbitrary element on the page

I'm coding a templating system that is supposed to support easily converting any old html/xhtml form into a format that can be used with my system (it's a template system for my cms). Here's what I'm aiming for: The user clicks a "Zone Define" button for example: "Content", "Sidebar", etc When the user hovers any elements they become ...

incorrect display of input radio when scrolling page

I have layout with two columns. Each column have "radiogroup" - a table with input[type='radio'] on every tr The problem is that some inputs display incorrectly when scrolling the page. Top or bottom of some inputs just dissapear. Look at the screenshot - http://img.skitch.com/20100716-8tjsyy877ms1ar6i5i9fp9qykr.png . The problem appears...

Naming conventions for html/css + MVC?

Are there any good articles on naming comprehensive naming conventions? I'm looking to clean up some code... everything from assets to models (Codeigniter) to HTML and CSS. I'm also curious how to structure the CSS... is it better to give everything a unique class ie search-bar-icon or is it better to repeat classes like .search span.i...

How do I set the first entry of a combo box to empty? PHP/MySQL

My code is retrieving player names from a database and outputting them into a combo box. However I want the first entry of the combo box to be empty, how can I achieve this? If it helps, here is my code. Please note I only have 1 option box code in HTML as I'm editing phpBB. The <-- BEGIN clubplayer --> is a loop. ...

Why is this ul exceeding the size of it's div?

Although li.textmenu has width: 140px, padding: 5px, and div.textmenu has width: 150px, the one list item i've made so far has a big left margin, and extends beyond the right edge of the div by a good 30px. Could someone explain why? http://www.briligg.com/frailty.html css: div.textmenu { background-color: #3b3b3b; ...

Question about text after iframe

Hi, I have this test html page, I tried it in both chrome and firefox. <html> <body> before iframe <iframe width="300" height="300" src="http://www.yahoo.com"/&gt; after iframe </body> </html> But what i see is I see the text 'before iframe', but I don't see the text 'after iframe'. Can you please tell how can I fix it? Thank y...

How to easily, transparently, serve gzipped html files to the user's browser?

The user, when he clicks a link, needs to get my compressed html file that his browser will uncompress automatically, without any fuss. What must I do on the server side to accomplish this? Thanks! -- ben ...

how to find html tags that dont have closing tags - is there a free html editor that can help with this?

ive been editing a lot of html pages with basic text editor, notepad. and now when i went to validate them the validation service is saying theres a div tag that is not closed. i tend to find automatic error reports such as these dont tend to be too reliable, i.e they will give you a line number and the error but often times the error is...

Why are the font sizes different

I've got the following html and css In Firefox the computed font size is 16.66667px In Chrome the computed font size is 13px Needless to say there is a good bit of difference in these two sizes, one is too small to read, one is nicely sized. I guess one way to work around it is to set the font size to 16.67px but why is this the case. ...

How would you pick the best image from a webpage in a crawler?

If you were given any random webpage on the internet and had the html source only. What method would use to give you the most accurate image that would best describe that webpage? Assume that there are no meta tags or hints. Facebook does something similar when you post a link but they give you choices of n images to chose from, they d...

How to save current aspx page as html

Please tell me how to save current page as a html page on button click. My page contains only labels which I fill on page load event. I am using the code below for this, but it's not saving (in HTML) all of the values that I see when my page is loaded (I think it converts before the values get loaded on the page). private void saveCur...

Add more behavior to existing onclick attribute in javascript

Hi, how can i add more behaviour to existing onclick events e.g. if the existing object looks like <a href="http://abc" onclick="sayHello()">link</a> <script> function sayHello(){ alert('hello'); } function sayGoodMorning(){ alert('Good Morning'); } </script> how can i add more behavior to the onclick that would do also the ...

why we use <html> tag although my website runs perfect without <html> tag.

Hello, I need to know what is the use of <html> tag from the beginning of the webpage although website runs perfectly without these <html> </html> tags. I knew that doctype is required but why this <html> tag is required. ...