Current status of the Ning Platform is always available on the Ning Status Blog.

Forum

NC for Hire

Overriding Ning's Sprite Image

Has anyone ever been able to successfully override Ning's default sprite image to produce different icons throughout the network?

I've grown tired of the default Ning sprite image...would love to know if anyone else has explored this...

You need to be a member of Ning Creators Network to add comments!

Join Ning Creators Network

Email me when people reply –

Replies

  • Should be *relatively* simple, just override the one CSS statement that gives the sprite URL with your own url to your image. The tricky bit is creating your own image where all the sprites are the same size and in the same order as Ning's... Otherwise you have a real headache re-defining each sprite's position within your new image.

    On creators, it's this line in the theme css file http://static.ning.com/creators/instances/css/theme-982_1356245232....

    .xg_sprite, .xg_icon, .rich-comment, .rich-comment em, .delete, .smalldelete, .activity-delete, ul.rating-themed, ul.rating-themed a:hover, ul.rating-themed a:active, ul.rating-themed a:focus, ul.rating-themed .current {
    background-image: url(http://static.ning.com/socialnetworkmain/widgets/index/gfx/icons/xg...);
    _background-image: url(http://static.ning.com/socialnetworkmain/widgets/index/gfx/icons/ie...);
    }

    • NC for Hire

      interesting..im gonna see if I can wrap my mind around this when i get back home..thanks Chris..

      • Check out the sprite image. It's one very tall image with loads of small icons. I think there is a large version too, and maybe an icon version, you'll find them with an inspector browsing your site. The positions are critical, as each sprite is simply the whole image as background, positioned exactly e.g.

        .xg_sprite-comment {
             background-position: left -401px;
        }

        slides it up 401px until the comment icon is in view in the element.

        The colour is defined in the png's name in hex, in this case it's 336699, look for the one in your network that matches your theme and go from that. Probably a good day's work in photoshop to replace them all with the images you want.

        • I'm having a stab at this tonight. I'm only weeping a little bit. About halfway through the first file. I'm a little naive when it comes to the way some of this CSS works, but do you think you might know what the difference is between the two files - ie under what circumstances one is used over the other, or do they just complement each other?

          It's horrible to work out, as there appears to be no standard spacing between each icon. You occasionally find that a batch are 16x16, which is convenient, but often there's no logic to them at all. If Ning were still here, I'd ask for a template with guides....

          Did you ever go anywhere with it?
  • Forgive my ignorance....what is the "sprite" image and where is it on Ning sites?

    • The "sprite" image is actually all the little icons you see on the site, all together in one image to make page loading faster and coding simpler. Imagine a very long piece of tape, with lots of little pictures on, all the same size. The envelope icon, the star icon, the alerts icon, the comment icon, the delete, edit, add, view icons and all the rest.  All the little blue pics you see on this page. Then imagine a piece of paper with a hole cut in it, big enough for only one of these images. Hold the paper in front of the tape, and slide the tape up and down. You only see one image at a time. That's how the sprite image is used, with css. See this page for examples http://www.w3schools.com/css/css_image_sprites.asp or open the links in my comment above to see the sprite image for the creators icons. You'll have to zoom in lots as your browser will shrink it to fit in the window... It will be tiny, and on the very left of the page.

  • This reply was deleted.
    • NC for Hire

      ha!  will do.. this post was from 2013 but i suppose others are still interested in it.. great ill check it out John..

This reply was deleted.

Search the Creators Network

Latest Activity

Paul Asher replied to Coach Drew's discussion Paid Migration Off Ning
46 minutes ago
Miche Marie replied to SweetPotato's discussion Ning 3.0 & 2.0 Update: Archiver & Migration
"Thanks SP... I guess because they gave you that answer a few months ago and they haven't Updated ac…"
48 minutes ago
SweetPotato replied to SweetPotato's discussion Ning 3.0 & 2.0 Update: Archiver & Migration
"Miche,
I think the line "Due to this, we are also no longer requiring migrations to happen." answer…"
1 hour ago
SweetPotato replied to Coach Drew's discussion Paid Migration Off Ning
"I have done this for my own site and am available to hire should you need similar. Be warned, thoug…"
1 hour ago
Miche Marie replied to SweetPotato's discussion Ning 3.0 & 2.0 Update: Archiver & Migration
"I'm wondering if someone can't get a confirmation that we won't EVER be required/ forced to go to 3…"
3 hours ago
Anna replied to SweetPotato's discussion Ning 3.0 & 2.0 Update: Archiver & Migration
"2 months on an still no announcement. I asked the support person a couple of times for a date for a…"
4 hours ago
Miche Marie replied to Lucia Steele - CTRNetwork's discussion Question: NING 2.0 vs. 3.0
"EXACTLLY?! I'm another one totally FLIPPING out over this as well! My whole social network and ALL…"
6 hours ago
Strumelia replied to SweetPotato's discussion Ning 3.0 & 2.0 Update: Archiver & Migration
"Kos, I thought they moved Suzie back to her 2.0 again after she complained a lot about her 3.0...? …"
11 hours ago
Tahíta replied to Tahíta's discussion ¿Por qué no se migran yo todas las Ning 02 a 3? in Ning Networks en español
"Ya nadie nos contesta?????"
13 hours ago
Kos replied to SweetPotato's discussion Ning 3.0 & 2.0 Update: Archiver & Migration
"There's no going back once you're in 3.0.  They do not have anything built (nor will they) to allow…"
14 hours ago
mysticpagan replied to SweetPotato's discussion Ning 3.0 & 2.0 Update: Archiver & Migration
"I wonder if I could go back to Ning 2 then seeing as I only moved to Ning 3 as i thought it was ine…"
16 hours ago
John Bizley replied to John Bizley's discussion Stopping the activity feed posts getting squished in smaller views
"We can also do much the same thing with when adding latest, featured etc in the sidepanels for foru…"
16 hours ago
Luke Jones replied to John Bizley's discussion Stopping the activity feed posts getting squished in smaller views
"Awesome John :) "
17 hours ago
Zachary Moonshine replied to SweetPotato's discussion Ning 3.0 & 2.0 Update: Archiver & Migration
"the ability to archive my 3.0 site would definitely make my switch to jamroom more smooth as im sur…"
17 hours ago
Kos replied to John Bizley's discussion Stopping the activity feed posts getting squished in smaller views
"Nice work John"
18 hours ago
Fire-Tech replied to Elson Tan's discussion Code Editor for Custom Code
"+1. Good to see ya popping in Elson"
23 hours ago
Elson Tan replied to Elson Tan's discussion Code Editor for Custom Code
"hey guys, glad to see you too."
yesterday
Livita Jesus Silva left a comment for Livita Jesus Silva
"Thanks George
correto.
Very good
A good sunday
Livita"
yesterday
George H. Compton IV left a comment for Livita Jesus Silva
"Okay thanks for the link, this code will work :-)  see image below.
.subTab-item > a{   background:…"
yesterday
Jelena replied to Elson Tan's discussion Code Editor for Custom Code
"Glad to see you Elson and awesome Google chrome plugin. Thanks."
yesterday
More…