Foros del Web » Creando para Internet » HTML »

Iframes en XHTML 1.1

Estas en el tema de Iframes en XHTML 1.1 en el foro de HTML en Foros del Web. Hola, estoy programando una página web en XHTML 1.1, y cuando le pongo un iframe, no me valida. Tengo entendido que este tipo de etiquetas ...
  #1 (permalink)  
Antiguo 21/03/2011, 07:26
Avatar de PWT26  
Fecha de Ingreso: enero-2011
Mensajes: 48
Antigüedad: 13 años, 1 mes
Puntos: 2
Iframes en XHTML 1.1

Hola, estoy programando una página web en XHTML 1.1, y cuando le pongo un iframe, no me valida.

Tengo entendido que este tipo de etiquetas ya no se usan, ¿sustituyo el iframe por <object>? El iframe que quiero insertar es un mapa de Google Maps.
  #2 (permalink)  
Antiguo 21/03/2011, 07:32
Avatar de maycolalvarez
Colaborador
 
Fecha de Ingreso: julio-2008
Ubicación: Caracas
Mensajes: 12.120
Antigüedad: 15 años, 8 meses
Puntos: 1532
Respuesta: Iframes en XHTML 1.1

¿a que te refieres con que no te valida?

hasta donde sé en la api de google maps no hace falta crear un iframe, si es que la api lo usa, la misma lo crea, todo se controla con su api JS

en el caso de los frames, prácticamente no se usan, pero los iframes es otra historia y realmente dudo que los deprecien, al menos hasta que HTML5 esté mucho más consolidado, realmente no falta mucho.
__________________
¡Por favor!: usa el highlight para mostrar código
El que busca, encuentra...
  #3 (permalink)  
Antiguo 21/03/2011, 08:09
Avatar de PWT26  
Fecha de Ingreso: enero-2011
Mensajes: 48
Antigüedad: 13 años, 1 mes
Puntos: 2
Respuesta: Iframes en XHTML 1.1

Paso el código por el validador de la W3C y me da sólo dos errores, los siguientes:

Line 43, Column 13: there is no attribute "src"

<iframe src="http://maps.google.com/maps?f=q&amp;source=embed&amp;hl=ca&amp;geo…



You have used the attribute named above in your document, but the document type you are using does not support that attribute for this element. This error is often caused by incorrect use of the "Strict" document type with a document that uses frames (e.g. you must use the "Transitional" document type to get the "target" attribute), or by using vendor proprietary extensions such as "marginheight" (this is usually fixed by using CSS to achieve the desired effect instead).

This error may also result if the element itself is not supported in the document type you are using, as an undefined element will have no supported attributes; in this case, see the element-undefined error message for further information.

How to fix: check the spelling and case of the element and attribute, (Remember XHTML is all lower-case) and/or check that they are both allowed in the chosen document type, and/or use CSS instead of this attribute. If you received this error when using the <embed> element to incorporate flash media in a Web page, see the FAQ item on valid flash.

Line 43, Column 492: element "iframe" undefined

…0989&amp;spn=0.025695,0.049267&amp;z=14&amp;iwloc =A&amp;output=embed"></iframe>



You have used the element named above in your document, but the document type you are using does not define an element of that name. This error is often caused by:
incorrect use of the "Strict" document type with a document that uses frames (e.g. you must use the "Frameset" document type to get the "<frameset>" element),
by using vendor proprietary extensions such as "<spacer>" or "<marquee>" (this is usually fixed by using CSS to achieve the desired effect instead).
by using upper-case tags in XHTML (in XHTML attributes and elements must be all lower-case).
  #4 (permalink)  
Antiguo 21/03/2011, 08:54
Avatar de zerokilled
Javascripter
 
Fecha de Ingreso: abril-2009
Ubicación: Isla del Encanto, La Borinqueña [+>==]
Mensajes: 8.050
Antigüedad: 14 años, 11 meses
Puntos: 1485
Respuesta: Iframes en XHTML 1.1

buenas...

en xhtml1.1 no existe el elemento <iframe>. piensalo de esta forma, si xhtml1 strict no permite <iframe>, menos aun las subsiguientes versiones.

__________________
la maldad es una virtud humana,
y la espiritualidad es la lucha del hombre contra su maldad.
  #5 (permalink)  
Antiguo 21/03/2011, 15:38
Avatar de PWT26  
Fecha de Ingreso: enero-2011
Mensajes: 48
Antigüedad: 13 años, 1 mes
Puntos: 2
Respuesta: Iframes en XHTML 1.1

¿Hay alguna alternativa para poner los mapas interactivos de Google Maps en mi página? ¿Usando object?

Etiquetas: xhtml, iframe
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 01:47.