Foros del Web » Creando para Internet » Diseño Gráfico »

tag MAP no valida, WHY?

Estas en el tema de tag MAP no valida, WHY? en el foro de Diseño Gráfico en Foros del Web. Código: <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="es"> <head> <title>basura</title> <link rel="stylesheet" href="a.css" type="text/css"/> </head> <body> <div id="background"> <img src="principal.jpg" id="imgw" ...
  #1 (permalink)  
Antiguo 03/08/2007, 17:04
 
Fecha de Ingreso: febrero-2005
Ubicación: MEXICO
Mensajes: 455
Antigüedad: 19 años, 2 meses
Puntos: 5
tag MAP no valida, WHY?

Código:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 

"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> 

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="es"> 

<head>
<title>basura</title>
<link rel="stylesheet" href="a.css" type="text/css"/>
</head>



<body>

<div id="background">
<img src="principal.jpg" id="imgw" usemap="#map" title="Presiona &Prime;entrar&Prime; en la 

imagen, para acceder al sitio" alt="" />

<map name="map">
<area shape="rect" coords="389.4,303.6,510.6,339.7" href="principal.html" alt="Click para 

entrar" />
</map>
</div>

</body>
</html>
This page is not Valid XHTML 1.0 Strict!

Result: Failed validation, 1 Error
File: upload://Form Submission
Encoding: utf-8
Doctype: XHTML 1.0 Strict
Root Element: html
Root Namespace: http://www.w3.org/1999/xhtml

Line 21, Column 15
: required attribute "id" not specified.<map name="map">
The attribute given above is required for an element that you've used, but you have omitted it. For instance, in most HTML and XHTML document types the "type" attribute is required on the "script" element and the "alt" attribute is required for the "img" element.
Typical values for type are type="text/css" for <style> and type="text/javascript" for <script>.


Entiendo que no le pongo ID, pero, porque lo necesita?, es decir, no le quiero dar un 'estilo' a un mapa de imagen, para que lo necesitaria?
__________________

  #2 (permalink)  
Antiguo 05/08/2007, 21:16
Avatar de PatomaS
Colaborador
 
Fecha de Ingreso: marzo-2004
Ubicación: En alguna otra parte
Mensajes: 4.656
Antigüedad: 20 años, 1 mes
Puntos: 63
Re: tag MAP no valida, WHY?

Hola

Esta pregunta está muy relacionada con este otro tema que tienes abierto.

El problema, es que en la especificación del xhtml 1.1, en la etiqueta map se ha eliminado el atributo name como puedes ver aquí.

Felicidad
__________________
¡ hey, hou, hou, hey !
  #3 (permalink)  
Antiguo 06/08/2007, 18:40
 
Fecha de Ingreso: febrero-2005
Ubicación: MEXICO
Mensajes: 455
Antigüedad: 19 años, 2 meses
Puntos: 5
Re: tag MAP no valida, WHY?

ok, gracias, tenias razon, el charset lo deje igual y reemplaze name por id, pero aunque ya es valido, firefox no lo reconoce, es decir, no me reconoce el area..
no entiendo, (siendo valido) en todo caso entenderia que ie no lo reprecentara


PD: por cierto, ese ID no tiene nada que ver con CSS, verdad?
(por que sino tiene nada que ver, no crearia alguna confusion respecto asi se le esta aplicando un estilo, no?...como yo me confundi..o a caso si es un estilo?...)
__________________

  #4 (permalink)  
Antiguo 06/08/2007, 20:42
Avatar de PatomaS
Colaborador
 
Fecha de Ingreso: marzo-2004
Ubicación: En alguna otra parte
Mensajes: 4.656
Antigüedad: 20 años, 1 mes
Puntos: 63
Re: tag MAP no valida, WHY?

Hola

El id es un atributo de las etiquetas.

La relación con las hojas de estilo, es que siendo un atributo de todas las etiquetas, es perfecto para usarlo como selector.

Felicidad
__________________
¡ hey, hou, hou, hey !
  #5 (permalink)  
Antiguo 07/08/2007, 11:34
 
Fecha de Ingreso: febrero-2005
Ubicación: MEXICO
Mensajes: 455
Antigüedad: 19 años, 2 meses
Puntos: 5
Re: tag MAP no valida, WHY?

thanks. :)
__________________

Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 02:05.