html

What language types are allowed in the HTML script tag?

I was looking at the W3C specs for the script tag, and I noticed you can specify VBScript and TCL as a language type. This is extremely new to me; I've only ever seen Javascript used with the script tag. Why aren't other languages more commonly used, and is there a complete list of languages you can use within this tag? ...

Javascript doesn't change document?

Take a look at this example code, which doesn't work: <?xml version='1.0' encoding='UTF-8' ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"&gt; <html xmlns="http://www.w3.org/1999/xhtml"&gt; <head> <script type="text/javascript"> <!-- function moveMe() { ...

Python: find <title>

I have this: response = urllib2.urlopen(url) html = response.read() begin = html.find('<title>') end = html.find('</title>',begin) title = html[begin+len('<title>'):end].strip() if the url = http://www.google.com then the title have no problem as "Google", but if the url = "http://www.britishcouncil.org/learning-english-gatewa...

start html page scrolled

I have an Html page with an scroll ,and I'd like when the page starts (onload) to put the focus in the 60% parox (y axis) of the page. that means to scroll automatically the 60% of the page. is this possible? thankyou ...

displaytag for rendering html lists instead of tables

Is it possible to generate lists with display tag? I would like to use it to produce something like: <ul> <li>Coffee</li> <li>Milk</li> </ul> with one <li> entry per each item on my list. Is that possible? ...

How to add a toolbar (like google translate) to a webpage opened through a link for saving/processing using html/javascript and php?

Hello, lets say I have bunch of hyperlinks. When link is clicked, I'd like an opened page (in a separate window) to have a google-translator style toolbox that I could use to save the page to a localdisk if I liked it, adding a few tags to the database using php. I understand how to save a file using php, but could You help me with ideas...

Changing the background of other link on hover of the First link.

I have the following mark up. <ul> <li><a><span>link-1</span></a></li> <li><a><span>link-2</span></a></li> <li><a><span>link-3</span></a></li> </ul> When user hover on the first 'a' then the next a tag in LI , we remove the backgorund-image. I hope you are clear what I want to do with this. ...

Why this button doesn't cause triple postback?

We have developed a page with a asp.net and debugging it accidentally we have discovered on our page button with the next code on onclik attribute onclick="__doPostBack('ctl00$FormPlace$m_userTaskMarkAsUnreadButton',''); __doPostBack('ctl00$FormPlace$m_userTaskMarkAsUnreadButton','');WebForm_DoPostBackWithOptions(new WebForm_PostBackOpt...

Convert HTML tag to lowercase

I working on an intranet project for IE6 (i know...) and I need to output some HTML code from a div. I use $('#output').text($('#container').html()); But IE6 outputs all the code in uppercase: <TABLE border=1> <TR> <TD>Test Content</TD> </TR> </TABLE> How can I convert HTML tags to lowercase using jQuery? Would be useful to hav...

jQuery.html() removes scripts and styles

Is there a way to use jQuery.html() and not loose the scripts and styles? or any other non-jQuery way? I'm trying to output the full HTML of the page the user is on. Is this even possible? ...

named anchors not working in safari

Hi there, can anyone explain why named anchor tags would not work in safari but work fine in other browsers: ie, ff, opera, chrome. I have some links to different areas of the same page and nothing happens when clicking on them in safari only. All the other browsers mentioned take me to that area of the page. I have tried using both t...

Empty UL inside LI element

Can anyone explain me why <ul> elementa cannot be empty? And why this HTML: <ul> <li class="header"> <a href="#">Work</a> <ul/> </li> <li class="header"> <a href="#">New</a> <ul/> </li> <li class="header"> <a href="#">Ungrouped</a> <ul/> </li> <li class="header...

Convert plain text list to html

I have a plain text list like this: I am the first top-level list item I am his son Me too Second one here His son His daughter I am the son of the one above Me too because of the indentation Another one And I would like to turn that into: <ul> <li>I am the first top-level list-item <ul> <li>I am his so...

Touch events are not triggered on video tags on safari for iPhone

I want to prevent the scrolling on a safari web page for iphone by binding the preventDefault method on the document element of the DOM, and it works on every elements but the video tag. document.addEventListener("touchmove", function(e){e.preventdefault();}, false); I've tried attaching the event to the video tags, but it seems as if...

How to disable an input type=text with javascript?

Hi, I want to disable writing in an input type text using javascript. The input type text is populated from database that is why I don't want the user to modify its value. Thinks for help. ...

Is there such a thing as a converter from php to html?

Don't think that I'm mad, I understand how php works! That being said. I develop personal website and I usually take advantage of php to avoid repetion during the development phase nothing truly dynamic, only includes for the menus, a couple of foreach and the likes. When the development phase ends I need to give the website in html fi...

Recommended Meta Elements?

Hi everyone! Setting up a "basic framework" for my website projects, I'm wondering which meta elements are really necessary/recommended? In particular, I'd like to know how to deal with the language attribute(s)!? In the following example, I think sth. is repeated unnecessarily... <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"...

What is the syntax for a checked checkbox in HTML?

Sounds like a bit of a silly question, but I am wondering what is the best way of stating that a checkbox is checked/unchecked in HTML. I have seen many different examples: <input type="checkbox" checked="checked" /> <input type="checkbox" /> <input type="checkbox" checked="yes" /> <input type="checkbox" checked="no" /> <input type=...

Alignment with relative and absolute positioning

How could I center the blue box inside the red one ? I see that the left side of the blue box is exactly in the middle of the red box, but I would like to center the whole blue box, not its left side. The dimensions of the boxes are not constant. I want to align regardless of boxes dimensions. Example to play with here. Thanks ! HTML: ...

Creating custom html text boxes

Hi guys Just wondering how you would go about creating the effect as seen in the following image: Image The part i'd like to attempt to recreate is the gradient within the text field itself along with the line border surrounding the text box. Thanks. ...