xhtml

Problems with parsing XHTML page via javascript

There is some xhtml page, the source of this page was parsed before loading in the browser, to find some XPath positions. Then this page was loaded into browser, and i want via JAvaScript(on some action) insert some text in XPath positions, that already have been found. Problem is, that in JavaScript(jQuery) i can get only innerHTML (HTM...

Overuse of nested DIVs. Bad practice or bad for search engine indexing?

I am working on a website frontend and found myself constantly nesting divs for layout purposes. Without using tables for layout it seems like the natural option to layout boxes within boxes. However looking at my completed source code its not unusual to see 3 or 4 layers deep of nested divs... Is this a problem and should I bother sp...

Comment reply procedure using jquery and php?

I have Commenting system in my app. For a single video entry anyone can post a comment and someone else can post reply to that comment and replies, cannot have thier further reples, similar to StackOverflow is doing (1 Answer, and thier 1 or more replies). I want the similar functionality what SO has, Let's I have the following HTML <...

How will a browser differentiate between XHTML 1.0 and XHTML 5?

By my understanding, neither XHTML (1.0, 1.1) nor XHTML 5 required a DTD. If this is true, how will a browser differentiate between the two? I can only assume that when the browser vendors support (X)HTML 5, all XHTML will be interpreted under XHTML 5 rules (assuming XHTML 5 is a superset of XHTML 1.0). Is this how it's going to work? ...

javascript jquery grabbing nested attributes

This is a kind of a random thing I need. Basically my setup is something like this: <div class="classname"> <h3> <a class="anchor_classname" title="some_title">..</a> </h3> </div> The above html segment gets repeated on the page for all existing records. What I need to do is this: using Jquery, I want to grab the tooltip t...

Meaning of attributes & parameters in HTML flash tag?

In the below code can anyone explain me the all the parameters and attributes used, why all these are used and whats their meaning here. What parameters and attributes are recommended and what are not to use with a flash tag in a HTML page. <object id="vf_flash" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpd...

How to force XPath to use UTF8?

I have an XHTML document being passed to a PHP app via Greasemonkey AJAX. The PHP app uses UTF8. If I output the POST content straight back to a textarea in the AJAX receiving div, everything is still properly encoded in UTF8. When I try to parse using XPath $dom = new DOMDocument(); $dom->loadHTML($raw2); $xpath = new DOMXPath($dom); ...

Data between elements

Hi, I'm trying to retrieve data that's put outside element blocks. Sample; <td> <b>abc</b> 123 <b>def</b> 456 <b>ghi</b> </td> So from this sample I would like to get the 123 and 456. On this site I found some samples with a not() and that seems to work a bit in the right direction but then 123 & 456 are removed because he only sh...

How to send HTML/CSS emails?

Most email clients have problems reading CSS in HTML emails (including Gmail and Hotmail). I often use this service to convert my HTML/CSS to proper email format so that everything looks normal on the user's end. Basically what it does is convert all CSS to inline styles: http://premailer.dialect.ca/ Do any of you have any other method...

XHTML Not Displaying in IE6, 7, 8 or FF3.5.1 - but ok in Firefox 3.0.1.

I have an XML file that references an XSL file (like ya do) that until lately has generated perfectly acceptable HTML output, regardless of browser. A new requirement has come down from on high for XHTML output for compatibility with another product. Ok, fine - I reworked my stylesheet to produce (W3C Validated) XHTML. Previously, I w...

Setting the style of a Table <td> in php dynamically.

Hi All, I am using php with code igniter. I am designing a website with php. I have a requirement in brief described as below: I have a view page with table in it. I load this view from many different controller .php files. Now i want one of the item in the table to appear with different colors when loaded from different .php controll...

IE6 float sidepanel bug

Hi, Im trying to fix a bug that only appears in internet explorer 6. The problem is that the side panel moved below the footer of the page in Ie6. Can anybody help? http://www.perfectclaims.com/houses4cash/ie6.php ...

XHTML template programming

Hi Everyone, Its been a while since I've done any hard core web design, so I have a question for you. I'm pretty sure that there is a feature of xhtml that allows you to create a template and include that template in your other xhtml pages. What I'm trying to do is create a "main links" template that allows any page to reference the mai...

Anyone know a good tool for validating XHTML/CSS offline?

I'd like to find a command-line tool for Linux that will validate both XHTML and CSS. As silly as this may sound, I'd like it to be able to operate offline. ...

ALT text for images in HTML

Hi, We are working on a website that has tons of images and one of the requirement is to have ALT text for each image (JPG, JPEG, PNG, GIF etc). So whenever the HTML shows and image the ALT text for that image is also written to HTML along with IMG SRC. After our discussion with developers the solutions that turned up are 1) Create a...

Javascript that automatically sets font-size on element so that text doesn't overflow? (autofit)

You know what I mean? Like let's say we have: <div style="width:100px;font-size:10px">Some Text</div> But then we could also possibly have a much longer text string in that div, in that case I would want that div to have font-size:7px or whatever, so that the whole string fits without overflowing. I'm sure there's already something l...

jQuery difficulties in FireFox & XHTML

I have recently made the switch from HTML to XHTML... don't get me started on the "why" - let's just say it wasn't an option. Anyhoo... This function worked fine in IE and FF when I was HTML, but now with XHTML I get the following error in FF: heightElement is undefined now here is the statement where I define heightElement functio...

What is the easiest way to convert existing PHP web application to mobile application?

Suppose I have developed one web portal in PHP/MySQL. I want to make it work in mobile also. What is the easiest way to do this? Can we use PHP with any mobile based mark up languages like WML or XHTML i.e. as we can use PHP with HTML in web applications used to view in normal web browsers? ...

weird CSS behaviour

I installed a template on blogger, but it's not showing the background image. in the main blog here you can see that there is no background image (the orange one) now visiting this one which is the blog I do test the template on first, shows normally the background. the weird result is that if you go back to the first website now and ...

How many is too many includes in <HEAD>?

I've done some searching on this but can't find any sort of best practice or recommendation -- and perhaps that's because there isn't any. I'm using all sorts of jQuery plugins on my site, in addition to TinyMCE and some other plugins, and my site's specific JS file. On top of that, I have three stylesheets ..... and there's more comin...