xhtml

Page anchors without trailing filetype, ie: www.example.com/sub#mySection

So I need to link to things like a section with id="mySection" at www.example.com/sub/ But since the page generated in wordpress and there is not any actual directory /sub/, nor any index.html or what have you inside it, how can I link to a specific part of the rendered page? Safari does nothing however when I create an anchor like t...

Get parent index with jQuery

<ul class="bullets"> <li><a href="#">item 1</a></li> <li><a href="#">item 2</a></li> <li><a href="#">item 3</a></li> <li><a href="#">item 4</a></li> <li><a href="#">item 5</a></li> </ul> When I click on the <a> element, i'd like to get it's parent <li>'s index number. I'm trying to create a carrousel type function that doesn...

jquery closest() selecting

I am having issues getting my remove element function working. I have this function: //Remove an Item From Any Group function deleteItem (selector) { $(selector).closest("li").fadeOut(500, function() { $(selector).closest("li").remove(); }); } Then this to call it, $("a.delete").live('click', function() { deleteIt...

What does the "me" in the rel attribute mean?

I know the 'nofollow' means to Search Engines "Don't follow this link" (or at least, don't give SEO juice to that link), but what does the "me" mean? I often see it paired up with "nofollow". What is it used for? Where should it be used? What are the advantages? Thanks ...

What improvements to accessibility are offered by HTML5?

What benefits are offered by HTML5 over HTML 4.01 or XHTML 1.0 Strict for accessibility? ...

What XPath selects the next <tr> after a <tr> containing X?

<tr> <td>Blah!</td> <td>X</td> <!-- TR containing X --> <td>Woot!</td> </tr> <tr> <td>Useful Data, contents unknown</td> <!-- Select this TR --> </tr> <tr> <td>Useless data</td> <!-- Don't select this or any subsequent TR --> </tr> <tr> <td>More crap I don't want</td> </tr> <tr> <td>X</td> <!-- Another X --> </tr> <tr> <td>Useful...

xhtml transitional vs strict?

iframes are not supported in xhtml strict. However, in my application I am using php recaptcha which requires the use of iframes. What are the downsides of just switching to xhtml transitional (if any)? ...

How Search Engine Crawler suffer from Nonstructural Tags like Div and Span?

As I read Pro CSS Technique, one point I am very interested in is "Avoiding Nonstructural Tags like Div and Span". Then I just realize that if my site contains more than two hundreds Divs and Spans per page; how does the Search Engine Crawler suffer from those and how does it index my pages? ...

Valid html tag to group definition list items.

I currently have: <dl> <span class="wrapper"> <dt>A title</dt> <dd>A description</dd> </span> <span class="wrapper"> <dt>A title</dt> <dd>A description</dd> </span> </dl> This (or divs instead of spans) doesn't validate. Is there anything I could wrap it with that would? ...

div positioning problem

In FireFox 3.5, the following div does not push the page content down. Rather, it overlaps. IE 8 does not. What can I do as a quick fix? <div style="position:fixed;top:0;width:100%;">blah blah</div> ...

How should I associate server-side data with client-side UI elements in HTML?

I run into this problem constantly while developing AJAX applications. Let's say I want users to be able to click on a "flag" icon associated with each comment on my site, which results in an AJAX request being sent to the server, requesting that the comment be flagged. I need to associate a comment id with the comment on the client side...

Do I need to declare XML on a page using the XHTML doctype?

I've been seeing some conflicting information that an XHTML document must also declare itself as XML. <?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; However, in other places I'm seeing (including w3.org) that the DOCTY...

CSS - Only Horizontal Overflow?

Is it somehow possible to achieve only horizontal overflow in CSS 2.1? overflow: auto; Will cause a block element to have both horizontal and vertical scrollbars, I want a block element (let's say ) which will display only horizontal scrollbars. How to do that? ...

What's the point of valid CSS/HTML?

If I've tested my pages in most major browsers, why would I need to maintain a validated code? I want to use box-shadows and corner radius if they're supported in WebKit browsers and Firefox. I don't care if they don't show up on Internet Explorer. But I keep my HTTP requests down by not including images instead. Are there are advantage...

XHTML and CSS books

I would like to learn moders XHTML and CSS programming. Does someone has any good book suggestions where to start? I would like to have a book where I can learn those languages completely or as much as possible and I can use them if I get trouble on my web-programming projects. And of course I would like that my sites passes web-standard...

Website Quality Assurance Testing

I have recently downloaded an app I have been looking for, for quite some time. It basically spiders a website and shows references to dead links, pages etc: http://home.snafu.de/tilman/xenulink.html. I am finding this very useful for quality assurance of the websites we publish. I was wondering if anyone uses a application that spide...

Regular expression transformation for wiki-like mark-up

Consider the following mark-up input: * Line 1 * Line 2 :* Line 2.1 :* Line 2.2 * Line 3 This is typically coded as: <ul> <li>Line 1</li> <li>Line 2</li> <ul> <li>Line 2.1</li> <li>Line 2.2</li> </ul> <li>Line 3</li> </ul> My questions: What would be a good representation for the same input u...

parsing a non xml file in java

I want to parse a document that is not pure xml. For example my name is <j> <b> mike</b> </j> example 2 my name is <mytag1 attribute="val" >mike</mytag1> and yours is <mytag2> john</mytag2> Means my input is not pure xml. ITs simliar to html but the tags are not html. How can i parse it in java? ...

tabulation spacing

is there an equivalent to the consoles special char '\t' in html ? ...

Mobile device resolution (width, height) screen size header

It seems there is no real standard for specifying "screen-size" in a http header from a user agent. For example, the two headers below: X-UP-devcap-screenpixels: 320x240 or UA-pixels: 320x240 are two commonly used headers. The second is used by Windows Mobile devices mostly. The X-UP looks like it comes from the UP browser gateway...