Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 5846727
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 22, 20262026-05-22T12:37:04+00:00 2026-05-22T12:37:04+00:00

This code is from Facebook Chat Emoticons Bar Grease Monkey UserScript ImagesURL = HttpsOn?’https://s-static.ak.fbcdn.net/images/’:’http://static.ak.fbcdn.net/images/’;

  • 0

This code is from Facebook Chat Emoticons Bar Grease Monkey UserScript

ImagesURL = HttpsOn?'https://s-static.ak.fbcdn.net/images/':'http://static.ak.fbcdn.net/images/';


emotsInfo = [':)', ':(', ':p', ':D', ':o', ';)', '8)', '8|', '>:(', ':/', ':\'(', '3:)', 'O:)', ':*', '<3', '^_^', '-_-', 'o.O', '>:O', ':v', ':3'];



for(i=0;i<emotsInfo.length;i+=1) {
        var fEmotsDom = document.createElement('img');
        fEmotsDom.setAttribute('alt',emotsInfo[i]);
        fEmotsDom.setAttribute('style','cursor: pointer; background-position: -'+ 16*i +'px 0px;');
        fEmotsDom.setAttribute('src',ImagesURL + 'blank.gif');
        fEmotsDom.setAttribute('class','emote_img');
        fEmotsListDom.appendChild(fEmotsDom);
    }

This code brings Facebook emotions from Facebook server
I’m coding a WPF , I understand all code procedures except getting the emotion from blank.gif

C# Code

        const string EmotionsResources = "http://static.ak.fbcdn.net/images/";


        private Image Emoticons ( string E )
        {
            return ( new Image ( ) { Source = new BitmapImage ( new Uri ( EmotionsResources + E ) ) } );
        }

if you try to get source of any of Facebook chat emotions .. you will get [ http://static.ak.fbcdn.net/images/blank.gif ]
this code retrieve emotions from this link HOW ?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-22T12:37:05+00:00Added an answer on May 22, 2026 at 12:37 pm

    I’m guessing here, but I think that the class triggers a style that checks the alt text. (that’s the only valid answer once you cross-off all the impossible answers.. the only thing that changes in each iteration is the alt text so that must be what’s triggering it. and a css class selector can work on attribute values)

    and in other words – you’re stuck.


    Edit

    So i was intrigued so i started to dig a bit deeper:

    css style on the image has the following css rules in it:

    element.style {
    background-position: 0px 0px;
    }
    .emote_img {
    background: url(http://static.ak.fbcdn.net/rsrc.php/v1/zC/r/eKCEtE1PXyK.png) no-repeat;
    overflow: hidden;
    }
    

    the first one is set by the script, and the second comes from the CSS file.

    so. the actual images are found in that png file, which is:

    http://static.ak.fbcdn.net/rsrc.php/v1/zC/r/eKCEtE1PXyK.png:
    facebook emoticon sprite

    (cool to know u can use so many emoticons in fb! 🙂

    and you’ll see ALL of the images in one image (it’s done to preserve bandwidth)
    since the image size is 16*16, it only shows ONE image at a time.
    the background-position thingie is in charge of shifting the image, so that each time a different icon is shown from the big image.


    So to get the image in C# you’ll do the following:

    you can either crop it, or use the exact same trick (which is better IMO), like this:

    <Canvas ClipToBounds="true" Width="16" Height="16">
        <Image Source="http://static.ak.fbcdn.net/rsrc.php/v1/zC/r/eKCEtE1PXyK.png" 
           Canvas.Left="0" /> <!-- or -16, -32, -48 etc.. -->
    </Canvas>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i have copied this code from the FB.init documentation : <script src=http://static.ak.connect.facebook.com/js/api_lib/v0.4/FeatureLoader.js.php/en_US type=text/javascript></script> ...
I'm using this code from Microsoft to play audio notifications for my application. It's
hI, I'm trying to get this code from Larry Nyhoff's book to compile in
This code is from Prototype.js . I've looked at probably 20 different tutorials, and
I have been playing with the demo code from this msdn article by Jeffrey
This is an excerpt of code from a class I am working with in
So I have this code that takes care of command acknowledgment from remote computers,
If I wrote this code: typeof(myType).TypeHandle Would it use reflection? How much different from:
What does STRAIGHT_JOIN do in this code ? SELECT STRAIGHT_JOIN ClosingBalance FROM Accounts WHERE
In .NET, after this code, what mechanism stops the Thread object from being garbage

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.