html

How to render narrow non-breaking spaces in HTML for Windows?

In French, typography requires that we use narrow non-breaking space (U+202F) at various places (“Comme ça !”). Apparently every browser on windows fails to support that and they all display a weird character instead. This works on most browsers on Mac OS X as well as Linux. Does anyone know how to make Windows browsers render it corre...

Is it possible to append to innerHTML without destroying descendants' onclick functions?

In the following example code, I attach an onclick handler to the span containing the text "foo". The handler is an anonymous function that pops up an alert(). However, if I append to the parent node's innerHTML, this onclick handler gets destroyed -- clicking "foo" fails to pop up the alert box. Is this fixable? <html> <head> <scri...

Configure Rails to output HTML output instead of XHTML

How do I configure Ruby on Rails to output standard HTML code instead of XHTML when using helpers (form, javascript, css, etc.)? I don't want to have the slash at the end: <input name="email" type="text" /> ...

Link in popup window does not close the window?

I have this bit of html code, but when I click the link, it does not close: <html> <head> <title></title> </head> <body> <h2>Members Only</h2> <p>You must be a member.</p> <p>Please Sign In or Create an Account.</p> <a href="javascript: self.close ()">Close this Window</a> </body> </html> ...

Popup window keeps opening after I close it and refresh the page?

I have an aspx.cs page with the following code: hypPopup.Attributes.Add("onclick", "window.open('Popup.aspx', '', 'height=650, width=800, location=no, toolbar=no, st...

3D models on HTML page

I have 3D CAD model that I want to show on a web page. I'd like to show it in a form like a <img> tag (e.g. inline with everything else rather than as a separate page) and I want the visitor to be able to rotate the model to view it from different perspectives. What options do I have? Things I'm thinking of/looking at VRML 3DXML flas...

How can I print background images in FF or IE?

Is there any way to set ff and ie to print background images? I am using stars image to classify some skills and I set it as a background image and positioning to either set one start, two, three, etc. When I try to print the page the images disappear. So is there any way to make them appear when I print the page or at least have a w...

How do you overcome the html form nesting limitation

I know that xhtml doesn't support nested form tags and I have already read other answers here in stackoverflow regarding this subject, but I still haven't figured out an elegant solution to the problem. Some say you don't need it and that they can't think of a scenario were this would be needed. Well, personally I can't think of a sce...

How do I get a "central column" effect without a background image?

I am designing a website layout in which all of the content is held in a central column of a fixed width. I want this central column to have a different background color than the rest of the page. I also want the central column to extend from the very top of the browser to the very bottom. I am able to successfully do this using a backg...

How to match a text node then follow parent nodes using XPath

I'm trying to parse some HTML with XPath. Following the simplified XML example below, I want to match the string 'Text 1', then grab the contents of the relevant content node. <doc> <block> <title>Text 1</title> <content>Stuff I want</content> </block> <block> <title>Text 2</title> <content>S...

What is the easiest way to detect if at least one field has been changed on an HTML form?

I have an HTML form with over 20 fields. I also have a couple of links on the page which will lead the user away from the form... potentially without having saved any changes. I want to warn (JS confirm) the user onClick of these links if any of the form fields have changed, but I don't want to create a huge switch statement that I the...

Generation PDF from HTML (component for .NET)

Can you please point me to open source or a reasonably priced comercial product capable of generating PDF from HTML? ...

AJAX Function to populate a field in a form?

Hey, I was looking through W3's tutorial on AJAX and I decided to make a javascript function that would populate a form field based on the response of a page. I took all their functions and tried to create the below one. Can anyone see why it wont work? function populateForm(myForm,formField,PageFrom,infoToSend) { var xmlHttp; try { ...

Convert HTML Character Back to Text Using Java Standard Library

Hello all, I would like to convert some HTML characters back to text using Java Standard Library. I was wondering whether any library would achieve my purpose? /** * @param args the command line arguments */ public static void main(String[] args) { // TODO code application logic here // "Happy & Sad" in HTML form. String ...

problem accessing an iframe that was called using ajax

hi, i called an iframe using ajax onto the current page and tried to print the page but is printing blank page can somebody help me with this what i did was: current page: <input type="button" onclick=verifyControl('1001') > <div id='pa_print'></div> js file function: function verifyControl(rNo) { xmlHttp=GetXmlHttpObject(); ...

css background color disappears with doctype

I'm trying to set background colours on a few different elements in an html page, but whenever I apply a doctype declaration the colours get ignored. Other styles seem unaffected. I'm sure I'm being an idiot. It happens on IE7, FF3 and Chrome. With Strict and Transitional html 4 Doctype. Body and Div backgrounds are affected. A minimal ...

How do i allow the user to select more than one file for upload?

Gmail just released an update to their interface allowing the user to select more than one file for upload by using the CTRL-button. How do they do that? You can read about the new feature and see a screen shot here: http://gmailblog.blogspot.com/2009/02/updates-to-attachments-multi-select-and.html ...

Does HTML allow for embedded encoding of images by stream?

Example: <div id="sampleimage"> ***Stream or Serialize JPEG Image from Server Here w/o Sending another Request*** </div> So basically, send everything in a single response. ...

Having PHP receive the days you're available without tons of variables

Here's my situation: I'm building a small website where, when registring, you can select which days you're available for something. Mondaymorning Mondayafternoon Tuesdaymorning Tuesdayafternoon etc... All the way to sundayafternoon. I'm formchecking this offcourse, in PHP, and I need to declare 14 variables and go over each one to det...

Marquee in html....

I want a "Continuous marquee text" over and over again... back to back... i dont want the text to finish scrolling completely before the next one starts... i want the same text to start scrolling and continue... ...