【发布时间】:2017-01-31 18:27:19
【问题描述】:
我试图在我的 aspx 页面中显示一个带有图像的 div。图像的名称是“PathFindingMap”(一个 png 文件),位于“images”文件夹中。 “图像”文件夹与 aspx 页面位于同一目录中。但是,页面上没有显示任何内容。
在.aspx页面的客户端,我有以下代码sn-p:
<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="floorPlan.aspx.cs" Inherits="ipsWebs.floorPlan" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
<div class="ClsdrawArea" id="draw_area" style="width: 100%; height:100%; background-image: url('images/PathFindingMap.png'); background-repeat: no-repeat; background-size:cover">
</div>
</asp:Content>
在 chrome 浏览器中,我按下 f5 并检查网络,它显示图像“PathFindingMap”已加载。但是,我在网页上看不到任何内容。我试图复制并粘贴类似的代码“
【问题讨论】:
标签: javascript html css asp.net