Probleme de dimension d'un SVG avec la balise EMBED

Probleme de dimension d'un SVG avec la balise EMBED - HTML/CSS - Programmation

Marsh Posté le 11-11-2004 à 14:21:23    

Bonjour,
j'ai un petit soucis de compatibilité IE/mozilla...
en fait j'aimerai afficher dans ma page un fichier svg mais en taille relative (en pourcentage...)
 
 
je vous fait voir un bout de code :
 


<head>
<style>
html,body
 {
    margin:0;
    text-align:center;
    background-color: black;
    }
    #map{
    width:100%;
    height:90%;
    }
</style>
  <title></title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body>
<embed id="map" src="monfichier.svg"  type="image/svg+xml" >
</embed>


 
 
et en fait ca marche nikel sous IE.
mais sous firefox, j'ai la largeur en 100% mais la hauteur, si elle est pas définie en pixel, ca fonctionne pas
je deviens  :pt1cable: à force de chercher.
si qqn à une solution je lui en serais éternellement reconnaissant

Reply

Marsh Posté le 11-11-2004 à 14:21:23   

Reply

Marsh Posté le 11-11-2004 à 14:39:24    

<embed> ca fait pas partie des normes HTML


---------------
I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box, and replicate and expand beyond their wildest dreams by throwing away the limits imposed by overbearing genetic r
Reply

Marsh Posté le 11-11-2004 à 15:19:31    

ok, et dans ce cas, tu fais koi pour afficher du SVG dans une page html???

Reply

Marsh Posté le 11-11-2004 à 15:23:35    

embed+js, c'est ce que je faisais, j'avais vu ca sur le site de adobe:
http://www.adobe.com/svg/demos/main.html
 

Code :
  1. <SCRIPT LANGUAGE="JavaScript"><!--
  2. emitSVG('src="/svg/demos/svgbubbles/chemical/chemical.svg" name="SVGEmbed" height="140" width="140" type="image/svg-xml"');
  3. // -->
  4. </SCRIPT>
  5. <NOSCRIPT>
  6. <EMBED SRC="/svg/demos/svgbubbles/chemical/chemical.svg" NAME="SVGEmbed" HEIGHT="140" WIDTH="140" TYPE="image/svg-xml" PLUGINSPAGE="http://www.adobe.com/svg/viewer/install/">
  7. </NOSCRIPT


Message édité par uriel le 11-11-2004 à 15:24:17

---------------
IVG en france
Reply

Marsh Posté le 11-11-2004 à 15:40:27    

la balise pour intégrer des éléments externes aux pages, théoriquement, c'est <object> -_-


---------------
I mean, true, a cancer will probably destroy its host organism. But what about the cells whose mutations allow them to think outside the box, and replicate and expand beyond their wildest dreams by throwing away the limits imposed by overbearing genetic r
Reply

Marsh Posté le 11-11-2004 à 15:43:58    

http://wiki.svg.org/?EmbedingSvgInHTML
 
:jap:
 
edit: mais interessant a lire: http://www.alleged.org.uk/pdc/2002/svg-object.html


Message édité par uriel le 11-11-2004 à 15:45:49

---------------
IVG en france
Reply

Sujets relatifs:

Leave a Replay

Make sure you enter the(*)required information where indicate.HTML code is not allowed