This is a migrated thread and some comments may be shown as answers.

Custom Skin won't display images

1 Answer 67 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Greg
Top achievements
Rank 1
Greg asked on 31 Aug 2011, 01:47 PM
Developing in Sharepoint 2007.
Creating a webpart in C#.
Normally  use Windows7 skin, but the user requires adjustments to various settings.
Used the demos phone support pointed me too.  But I'm working with ascx not a aspx so they didn't work.
Used the Visual Style Builder,  I'm going the way of creating the folder for the skin and copying it in and then dragging the css file to the page. 

Ok. The application recognizes the css and is using its settings.  The problem is the images such as the background and controls will not display.  Included them in the folder as well in a sub folder and the css points too them fine.  Even moved the css file around to see if it needed to be in the same folder, just for argument sake, and the path to the images makes its adjustment just fine.

Why won't this display the images? 

.RadGrid_ProBono .rgAdd,
.RadGrid_ProBono .rgRefresh,
.RadGrid_ProBono .rgEdit,
.RadGrid_ProBono .rgDel,
.RadGrid_ProBono .rgFilter,
.RadGrid_ProBono .rgPagePrev,
.RadGrid_ProBono .rgPageNext,
.RadGrid_ProBono .rgPageFirst,
.RadGrid_ProBono .rgPageLast,
.RadGrid_ProBono .rgExpand,
.RadGrid_ProBono .rgCollapse,
.RadGrid_ProBono .rgSortAsc,
.RadGrid_ProBono .rgSortDesc,
.RadGrid_ProBono .rgUpdate,
.RadGrid_ProBono .rgCancel,
.RadGrid_ProBono .rgUngroup,
.RadGrid_ProBono .rgExpXLS,
.RadGrid_ProBono .rgExpDOC,
.RadGrid_ProBono .rgExpPDF,
.RadGrid_ProBono .rgExpCSV,
{
        background-image:url('ProBonoSkin/Grid/sprite.gif');
}

File structure
Solution --> ProBonoSkin --> Grid --> sprite.gif
The ProBonoSkin folder is the root folder and then grid and inside are the images.

Solution --> ProBonoSkin --> CSS File
The CSS sits in the ProBonoSkin folder.

When the CSS file is moved around, as stated earlier, it corrects the path to the images on its own so I wouldn't think this is a '../' issue or anything.

The embedded  theme set to 'false' for the controls.

The  controltemplate  links are setup as well to the images and css file.  At one point this was not the case, but linking them isn't making a difference either. 


Getting the images to show is all that is needed.


Thanks!

1 Answer, 1 is accepted

Sort by
0
Jayesh Goyani
Top achievements
Rank 2
answered on 01 Sep 2011, 02:14 PM
Hello,

Please set hyphen and check.

background-image:url('~/ProBonoSkin/Grid/sprite.gif');

let me know it working or not.

Thanks,
Jayesh Goyani
Tags
General Discussions
Asked by
Greg
Top achievements
Rank 1
Answers by
Jayesh Goyani
Top achievements
Rank 2
Share this question
or