PDA

View Full Version : How SEO friendly is this menu example ?



Skeewe
02-25-2008, 05:13 AM
This is menu from MS Visual Studio 2008 - Web Developer
Here is example code:

" <td style="white-space:nowrap;width:100%;"><a class="Menu1_1" href="Default2.aspx">Item1</a></td>
</tr>
</table></td>
</tr><tr onmouseover="Menu_HoverDynamic(this)" onmouseout="Menu_Unhover(this)" onkeyup="Menu_Key(this)" id="Menu1n2">
<td><table cellpadding="0" cellspacing="0" border="0" width="100%">
<tr>
<td style="white-space:nowrap;width:100%;"><a class="Menu1_1" href="javascript:__doPostBack('Menu1','Menu2\\Item2')">Item</a></td>
</tr> "

Is this SEO friendly menu? Thanks

KLB
02-25-2008, 09:35 AM
This isn't legal HTML. I think what you showed us is server side code and what we need to see to answer your question is the generated HTML.

Skeewe
02-25-2008, 11:43 AM
I changed it, you we right it was server side , my mistake, sorry.
I guess it's not SEO friendly since its javascript code. Am I right ?

Chris
02-25-2008, 12:04 PM
That code is not SEO friendly. Definitely not.

KLB
02-25-2008, 01:56 PM
In order for menus to be SEO friendly, they MUST include plain old <a href> links. These links can use CSS and Javascript to control their visibility to users, but they must be written into the HTML source as plain links.

jbladeus
03-01-2008, 03:03 AM
Slightly off-topic, but you may also want to design without tables and use <div> for layout. Tables should always be used to display tabular content.

KLB
03-01-2008, 10:54 AM
Slightly off-topic, but you may also want to design without tables and use <div> for layout. Tables should always be used to display tabular content.

While I agree that tables should not be used to control layout. It is very important to note that this has no direct bearing on SEO, which is the topic of this thread.

deathshadow
04-22-2008, 09:22 AM
While I agree that tables should not be used to control layout. It is very important to note that this has no direct bearing on SEO, which is the topic of this thread.
Correct. It may be the most bloated piss-poor way of coding a menu, again being more of 1997 than 2008, but...

That does NOT mean search engines give a hoot in hell what tags are used. (with the possible exception of heading tags - table, td, div - doesn't matter)

Kind of like how most search engines these days IGNORE ATTRIBUTES. (Making title and even alt kind of pointless)

Nested tables = FAIL. Table for a single column or row of data = /FAIL/ hard.

Sending javascripted menus to all browsers when only legacy ones (IE6/earlier) needs it - MASSIVE fail. Code a normal CSS menu for modern browsers, then throw a HTC at IE6/earlier. End of problem.