troubleshooting Question

use image as a background to a master page

Avatar of siddhuoops
siddhuoops asked on
C#
2 Comments1 Solution224 ViewsLast Modified:
Hi there,
            I have a gif image file that I need to use as a background to my master page where all the other pages will inherit. How would I use a image file as a background on a master page? When I add a new page and select that master page, then my new page would have a background of that image file. I tried this but didn't get the image.

rebate.master
<%@ Master Language="C#" AutoEventWireup="true" CodeFile="rebate.master.cs" Inherits="rebate" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>Untitled Page</title>
  </head>
<body>
    <form id="form1" runat="server">
    <div>
        <asp:ContentPlaceHolder ID="Content1" runat="server">
        <asp:Image ID="Image1" runat="server" ImageUrl="~/Cap Cal. Temp..jpg" Width="923px" /></asp:ContentPlaceHolder></div>
    </form>
</body>
</html>

Default.aspx
<%@ Page Language="C#" MasterPageFile="~/rebate.master" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" Title="Untitled Page" %>
<asp:Content ID="Content1" ContentPlaceHolderID="Content1" Runat="Server">

</asp:Content>
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 2 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 2 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros