Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Character Code for Webding Character 2

Status
Not open for further replies.

AllenRitch

Technical User
May 20, 2003
52
0
0
US
Does anyone know the character code for the combination lock in Webdings? In Microsoft Word, it shows up as 00CF. But that won't work. HTML seems to only accept one digit codes.

Thanks
 
Well, it's not really a character entitiy. It's a graphic. If you want that specific lock, you're going to have to make a graphic out of it.

HTML can use character entities, which are usually 6-character sequences of the form:
ampersand-hashmark-digit-digit-digit-semicolon.

Some can be abbreviated, such as ampersand-"nbsp"-semicolon which forms a non-breaking space.

You can easily search the web for a table of character entities. The truth is out there -- fear not.

Cheers,


[monkey] Edward [monkey]

"Cut a hole in the door. Hang a flap. Criminy, why didn't I think of this earlier?!" -- inventor of the cat door
 
Is there a lock symbol or charachter entity of a lock that's not a graphic?

I'm offering several reports on our intranet site where some of them are secured. And I'm presently using a gif image of a lock next to each secured report which seems to load a little slow (and sometimes not at all).

Thanks
 
As far as I know there's no unicode character entity for a padlock glyph. You've got two real choices; Stick with the .gif file - or change the icon to something there is a character for. (Perhaps an 'X').

[sub]Never be afraid to share your dreams with the world.
There's nothing the world loves more than the taste of really sweet dreams.
[/sub]

AU.gif
Check out Tek-Tips Australia New Zealand forum1155
NZ.gif
 
I just want to add to this..
When I was doing something similar with lots of small .GIF images on a Website.. I too noticed sometimes they didn't like to load.

But if you use Javascript and PreLoad(?) the images, it'll work much faster.. and the images will always show up.

Here's an example for preloading with rollovers.
But I'm sure you can modify that to your needs ;)

function preload() {
if (!document.images) return;
var ar = new Array();
var arguments = preload.arguments;
for (var i = 0; i < arguments.length; i++) {
ar = new Image();
ar.src = arguments;
}
}

<BODY onLoad=&quot;preload('first.gif', 'second.gif', 'third.gif')&quot;>

 
AllenRitch: Is there a lock symbol or charachter entity of a lock that's not a graphic?

Basically, no.

I'm offering several reports on our intranet site where some of them are secured. And I'm presently using a gif image of a lock next to each secured report which seems to load a little slow (and sometimes not at all).

Geez, what's the file size/dimensions of the GIF? I mean, it shouldn't be more than 1K, which pretty much loads in an eyeblink (unless you're on a 300-baud modem, in which case it can take somewhere between an eyeblink and a second). Furthermore, if it's an intranet site, there's absolutely no reason why that file shouldn't be right there right now

How do you call it? One suggestion is:
Code:
<img src=&quot;locked.gif&quot; height=&quot;10&quot; width=&quot;10&quot; alt=&quot;locked&quot; />

If you use this exact line everywhere you want the lock, it'll take, maybe, a fraction of a second to load the first time and then even smaller a slice after that because their browser has it in cache.

Can I e-mail you an example?

Cheers,


[monkey] Edward [monkey]

&quot;Cut a hole in the door. Hang a flap. Criminy, why didn't I think of this earlier?!&quot; -- inventor of the cat door
 
I'm using the image tag that you suggested along with the JavaScript xWastedMindx offered. Everything seems to load pretty quickly now. I'm not sure what the problem was before.

Kudos to all for the help.
 
Code:
Locked: &#207; or the character Ï
Unlocked: &#208; or the character Ð

I see Ed's point on the cached images, but, WebDings (as far as I've read) has been included with IE since IE 4.
Why not use it? Then, worry about caching the StyleSheet you're using to set the font style and size, not the image.

For instance, by including in your StyleSheet include file:
Code:
SPAN.LOCKS{font-family:webdings; font-size:12pt}

You can use
Code:
<span class='LOCKS'>Ï</span> - LOCKED
and
<span class='LOCKS'>Ð</span> - UNLOCKED

instead of
Code:
<img src="locked.gif" height="10" width="10" alt="locked" /> - LOCKED
and
<img src="unlocked.gif" height="10" width="10" alt="unlocked" /> - UNLOCKED

And unless you're using Vector graphics for your image, you can't resize it to any size you want, without increaseing the size of the download (or reducing the image's quality.)
However, since Webdings are a TrueType font, you can resize to your heart's content, and still be satisfied with the quality.

Want a LARGE lock, just change your stylesheet to be:
Code:
SPAN.LOCKS{font-family:webdings; font-size:70pt}

You'll have a huge lock, but no change in the file's size.

I'd rather keep everything in my HTML, if I can avoid resorting to images.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top