0

I have researched from google as well as articles from this site but with no help regarding adding a banner on SharePoint 2013. This was easy on 2010 version but 2013 is giving me trouble.

This is what I have done so far:

On Master page: seattle.html I have linked my css file under the themable link. and on my CSS file, I added the following code:

#s4-titlerow {
    background:#F9F9F9 url('/SiteAssets/banner.jpg') repeat-x 0px 0px;
    margin:0;
    min-height:121px;
    overflow-x:hidden;
    padding:30px 0 0 310px;
    word-wrap:break-word;
}

but the banner is not showing when I load the page.

1

Your styles appear to be fine, so I would say you have a problem with the CSS file reference.

you can use CSS Registration

<SharePoint:CSSRegistration ID="CSSReg5" name="<%$SPUrl:~SiteCollection/Style Library/CSS/styles.css%>" After="corev4.css" runat="server"/>

or use AlternateCSSURl

  1. Find "Site Collection Features" setting and enable all features with name "publishing" in it.
  2. Find "Manage Site Features" setting and enable all feature with name "publishing" in it.
  3. Find "Master Page" setting link under "Look and Feel".
  4. Click "Alternate CSS URL". This is where you apply your own CSS file.
  5. Upload a CSS file to any document library. Ideally to "Style Library".
  6. Go to step 4 and choose your uploaded CSS file.

or html reference

<!--SPM:<SharePoint:CssRegistration name="&lt;% $SPUrl:~sitecollection/_catalogs/masterpage/test/style.css %&gt;" runat="server" after="SharepointCssFile" />-->
0

You need to have the full URL for the background image.

#s4-titlerow {
    background:#F9F9F9 url('http://example/sites/company/SiteAssets/banner.jpg') repeat-x 0px 0px;
    margin:0;
    min-height:121px;
    overflow-x:hidden;
    padding:30px 0 0 310px;
    word-wrap:break-word; }

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.