This is probably something really simple but I cant see what! Any images I have in a masterpage aren't showing up in child pages, all I get is the box with the red cross in it.
I don't think Ive done anything different from usual and it's not something that's happened in other sites so im kinda scratchin my head with it. Any ideas are appreciated!
The master page establishes a layout and includes one or more ContentPlaceHolder controls for replaceable text and controls. The content page includes only the text and controls that are merged at run time with the master page's ContentPlaceHolder controls.
To access the master page controls we need to use the Master key word then call the Property method of control. As we use Master. EnterNameTextBox() to access the master page EnterName textbox and Master. SendDataToContentPageButton() method is used to acees master page button.
Kevin's got the essence of the problem right - your URL in your master page is likely relative to the location of the master page, and when it's included in the child page, the relative reference isn't correct anymore. The simplest solution for this sort of thing is to have your master page URLs be relative to the site, not the page. In other words, if you've been doing
<img src="images/picture1.gif">
You need to replace that with
<img src="/images/picture1.gif">
or something similar.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With