html

Reset an input control's border color (HTML/Javascript)

Does anyone know how to reset the border color of an input control once you have modified it using javascript? Useful for validation by highlighting fields that have incorrect or invalid data in them etc. E.g. changing the border: document.getElementById('myinput').style.border = '1px solid red'; how to reset? the next line just re...

PHP Input validation for a single input for a url.

I have this very simple script that allows the user to specify the url of any site. The the script replaces the url of the "data" attribute on an object tag to display the site of the users choice inside the object on the HTML page. How could I validate the input so the user can't load any page from my site inside the object because I h...

How do I get my PHP application to re-use the same window for playing music?

Below is the code for my player which will automatically generate a playlist.xml file according to the songs selected by the user. I kept this file as player.php in my root folder, and in the form I give: <form method="post" action="/player.php" target="_blank"> so this player is opening and playing songs according to what is selected...

Regex to read out HTML tags

I'm looking for a regex that matches all used HTML tags in a text consisting of several lines. It should read out "b", "p" and "script" in the following lines: <b> <p class="normalText"> <script type="text/javascript"> Is there such thing? The start I have is that it should start with a "<" and read until it hits a space or a ">", but...

I only want to match the start tags in regex

I am making a regex expression in which I only want to match wrong tags like: <p> *some text here, some other tags may be here as well but no ending 'p' tag* </p> <P>Affectionately Inscribed </P><P>TO </P><P>HENRY BULLAR, </P><P>(of the western circuit)<P>PREFACE</P> In the above same text I want to get the result as <P>(of the west...

i want to match only start tags in regex

i am making a regex expression in which i want to only match wrong tags like <p> *some text here, some other tags may be here as well but no ending 'p' tag* </p> <P>Affectionately Inscribed </P><P>TO </P><P>HENRY BULLAR, </P><P>(of the western circuit)<P>PREFACE</P> like in the above same text i want to get the result as <P>(of th...

reformat a simple html page on an iphone

I have a html called today.html and I use it on my iphone and I have to zoom in to see my tasks how can I have it formated correctly so that I it warps around the screen on the iphone and the text is the right size here is my code <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"&gt; <html ...

Title attribute - useful for making a web page accessible?

The sources I've read on making web pages accessible provide conflicting information on whether the 'title' attribute is actually useful. Some claim that it's best practice to give a web control a title attribute containing a more detailed explanation than the visible text on the control provides. Others claim that the default for most...

Why is my element with position:absolute always showing up underneath position:relative items?

It's all in the question but here's a simple example <!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" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1" /> <ti...

Set Value of a TextArea inside a WebBrowser Control (C# / .NET)

I'm looking to set the value of a TextArea using the .NET WebBrowser Control. I have been able to set the values of textboxes using the following code (replace "username" with the name of the texbox): webBrowser1.Document.All.GetElementsByName("username")[0].SetAttribute("Value", "SomeUser"); I tried using similar code on a TextArea ...

Dude, where's my column?

(Apologies for the title, but that's about how I feel right now.) I've recently been given the… opportunity… to completely redesign the layout of a web site I support. In the interest of keeping my CSS simple and my HTML semantic, I decided to use a modified version of the "holy grail" layout (the main difference is moving the right co...

changing hidden field in client side problem

I have a hidden field and I change the value just before submitting the form using Javascript. But in server side it is null or empty. Request.Form["hidAction"] is empty. <script type="text/javascript" language="javascript"> function DoChange() { document.getElementsByName('hidAction').value = "filter"; alert(d...

Redirect automatically when selecting an item from a select drop-down list

This page does it the way I want it to: http://www.web-source.net/javascript_redirect_box.htm But I want to find a better way using jQuery, can anyone point me to a good script that uses jQuery to accomplish this? ...

wyswyg html form printing

I am starting this web app project (asp.net mvc) It's a document-based system, such that nearly each web page is a model of an official printed form (and users sometimes should be able to produce prints). I am wondering how much cost and time saving it will be if the form could be a wyswyg page that will serve both electronic and paper...

Eclipse Ganymede for OS X contains no HTML formatter. Alternatives?

In Eclipse 3.4 for Windows, the Source -> Format option for formatting Java code was extended to format HTML code. However, for OS X, this option is disabled. Additionally, there are no formatting options in the Preferences. I've downloaded all the Web Tools for Eclipse and the option is still unavailable. Which plugin/feature allows f...

Will HTML be replaced by any new technology?

I see various frameworks being launched that promise Rich Ui and better User experience as they call it. Silverlight, Flash, Yahoo's new framework etc etc. Does this mean that over a period of time these frameworks will replace the existing HTML, JAVASCRIPT CSS based web applications? Wouldn't it be same as opening an application insid...

how to print the contents of a hidden iframe?

i want to print a page which i put in an iframe but dont want the contents to be displayed in the webpage , but the print button doesnt work when i put the iframe to display='none' what i did:- i set the iframe style='none' "name="frame1" > <input type="button" onclick="frames['frame1'].print()" value="print!"> how can i print the ...

CSS question

I have the following code: what i want is using css put the "MYIMAGE" on the most right side. <div style="cursor: pointer;" onclick="javascript:SelectContact('17');" onmouseover="javascript:this.className='onfocus';" onmouseout="javascript:this.className='tempClass';" id="contact_17" class="tempClass"> <input type="chec...

Adding controls in runtime problem ASP.Net

I put a link on a page and onclick i wrote some code to add some controls after clicking, DropDownList newDropdownlist = new DropDownList(); panel.Controls.Add(newDropdownlist); CheckBox newChkbox = new CheckBox(); panel.Controls.Add(newChkbox); TextBox txt = new TextBox(); txt.ID = "txtPhoneValue"; panel.Con...

IE munging pound symbol

I have a html form which goes of to do all sorts of strange back end things. This works fine in firefox. and in most cases it works fine in IE However the (pound sterling) £ sign causes problems, and seems to get munged in the submit. The forms is something like this <form action="*MyFormAction*" accept-charset="UTF-8" method="post"...