Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/css/35.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/xml/12.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Css 试图用XML显示图片_Css_Xml_Image_Xml Namespaces - Fatal编程技术网

Css 试图用XML显示图片

Css 试图用XML显示图片,css,xml,image,xml-namespaces,Css,Xml,Image,Xml Namespaces,一块馅饼的图片应该显示出来,但它不会。图片的代码是个人在视频教程中使用的,我只更改了图片的名称。我问过我的老师,唯一得到的回答是我的照片的大小可能是问题所在。这些图像的大小不超过48 x 48像素,它们也不超过48 x 48像素。我列出的代码只是一个条目。如果你能给我任何帮助,我将不胜感激。谢谢你,蒂莎 <?xml version="1.0"?> <?xml-stylesheet type="text/css" href="pies6.css"?> <pies

一块馅饼的图片应该显示出来,但它不会。图片的代码是个人在视频教程中使用的,我只更改了图片的名称。我问过我的老师,唯一得到的回答是我的照片的大小可能是问题所在。这些图像的大小不超过48 x 48像素,它们也不超过48 x 48像素。我列出的代码只是一个条目。如果你能给我任何帮助,我将不胜感激。谢谢你,蒂莎

<?xml version="1.0"?>



<?xml-stylesheet type="text/css" href="pies6.css"?>
<pies>
<pie>
    <indo>PP12</indo>
    <name>Perfect Pecan</name>
    <factory>Baker</factory>
    <price>$8.30</price>
    <B-S>T</B-S>
    <html:IMG xmlns:html='http://www.w3c.org/TR/REC-html40/' SRC='images/pecan.gif' />
    </pie>
</pies>

我是太累了还是代码中没有看到任何
img src
?假设图片在正确的文件夹中,您声明了查看该图片的路径,但在代码中没有提到要在某处显示它

这适用于Firefox27(linux)、Chrome33(linux)和IE9(win7)


第12页
完美山核桃
面包师
$8.30
T

您将XML加载到哪个软件中?使用Notepad++编辑,我尝试过IE、firefox和chrome。文档显示除图片以外的所有内容。这是用于图片的代码。他说他从未在书中见过它,但在网上找到了它并开始使用它。
pies
{
background-color:#e0f8f7;
width:100%;
}

pie
{
display:block;
margin-bottom:60pt;
}

name
{
display:block;
color:#0b2161;
margin-left:15pt;
font-size:25pt}
<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="pies6.css"?>
<pies>
  <pie>
    <indo>PP12</indo>
    <name>Perfect Pecan</name>
    <factory>Baker</factory>
    <price>$8.30</price>
    <B-S>T</B-S>
    <html xmlns="http://www.w3.org/1999/xhtml">
      <img src="images/pecan.gif" />                                                  
    </html>
  </pie>
</pies>