Thursday, December 12, 2024

Goodies to Go ™
December 9, 2002– Newsletter #210


Goodies to Go ™
December 9, 2002–Newsletter #210

This newsletter is part of the internet.com network.
http://www.internet.com
 


Featured
this week
:

* Goodies Thoughts 
– I Never Met A Tag I Didn’t Like!
* Q & A Goodies
* News Goodies
* Feedback Goodies  

* And Remember This

 


 

Goodies Announcement

Just in case you missed
it before, the new Beyond HTML Goodies book is now available!

 

Go beyond the basics
and learn how the pros add and use dynamic HTML features and advanced
JavaScript techniques. Beyond HTML Goodies demonstrates dozens of new and
different features readers can add to their existing Web pages using HTML and
JavaScript. The book starts with simple text and image tips, such as adding a
clock to a Web page or causing text to appear when the mouse moves over an
image. It gradually builds to more complex tricks, including manipulating forms
or working with cookies behind the scenes. Throughout the book, readers enjoy
Joe’s snappy style and “to the point” discussion of each “goody” in the book.

 

http://books.internet.com/books/0789727803

 

 

Goodies
Thoughts

I Never Met A Tag I Didn’t Like!

New tags and old, they’re all such
an important part of the Web developer’s toolbox.
While many of them have become second nature to the
seasoned HTML coder, there are some, especially
among the newer ones, that remain a mystery.
Surprisingly, however, there is a group of tags that
harken back to the very origins of HTML and yet are
still numbered among the mysterious to many page
builders. These are the META tags. I see questions
all the time the answer to which would involve one
or another META tag, so I thought it might be useful
to talk a little about these "mysterious" tags.

Simply stated, META tags contain information about
the page on which they appear. They can also contain
certain directives — more about that later. There
are two types of META tag: HTTP-EQUIV and NAME. This
week I will be discussing the NAME variety,
HTTP-EQUIV will be next week.

A META tag with a NAME attribute provides
information about the document (web page) that
contains it. The NAME attribute specifies the type
of information, and the CONTENT attribute specifies
the information itself. For example, <META NAME="Ice
Cream Flavor" CONTENT="Vanilla"> defines information
about an Ice Cream Flavor and specifies Vanilla (my
personal favorite – please don’t ever call it "just
plain"!!)

Putting information about my favorite ice cream
flavor into your web pages is perfectly legal,
syntax wise. It might not be too useful, however.
The syntax allows for just about anything you could
dream up, there are certain values for the NAME
attribute that have well known, or generally
accepted meanings. These values include AUTHOR,
DESCRIPTION and KEYWORDS. The meanings of these META
tags are most important to the search engines.

Many of the search engine robots use the information
contained in your pages’ META tags for placement of
your page in the engines listings. If you are trying
to promote a website, this could be very important.
Suppose we have a web page for Ice Cream Inc., a
manufacturer of Chocolate, Strawberry and, of
course, Vanilla ice cream, and we wish to have our
page well placed for anybody looking for these
flavors of ice cream to find. we would add the
following META tags to the page for the search
engine robots to read:
<META NAME="AUTHOR" CONTENT="Ice Cream, Inc., IT
Dept.">
<META NAME="DESCRIPTION" CONTENT="The manufacturer
of the best Chocolate, Strawberry and, of course,
Vanilla Ice Cream in the known universe.">
<META NAME="KEYWORDS" CONTENT="Ice, Cream,
Chocolate, Strawberry, Vanilla, Manufacturer,
Gourmet, Dessert, Delicious"
This should provide an appropriate set of
information to the robots! Notice that you can add a
variety of different aspects to your KEYWORD list.
Be careful not to violate any copyright or patent
laws, however — you may not use someone else’s name
to advertise your products or services without their
permission.

You can also use META tags to direct (most) search
engine robots to skip your page if you wish to. This
is equivalent to placing a "robots.txt" file in your
web site directory. The META tag has a NAME="ROBOT"
attribute, and a CONTENT attribute with value
choices of: "ALL | NONE | INDEX | NOINDEX | FOLLOW |
NOFOLLOW". The default value "ALL" indicates that
this page should be indexed and all links on this
page may be followed to other pages. "INDEX,
NOFOLLOW" indicates that this page is to be indexed,
but links should not be followed to other pages.
"NONE" would indicate don’t index and don’t follow
links. You can see the possible combinations!

"robots.txt?" you ask? I heard! a file with the name
"robots.txt" (lower case, without the quotes)
provides a similar control mechanism. The format is
as follows:
User-agent: *
Disallow /

This example prevents everything from the web site’s
root on down from being indexed by any (robots.txt
aware) search engine agent (robot). "Disallow: /herenondx"
would prevent everything in the "herenondx"
directory from being indexed. Only one "User-agent:"
line may appear. It can use a wildcard as in this
example or specific user agents may be named. There
may not be any blank lines in the file, and if the
file contains errors it will most likely be ignored.

Next week, as I mentioned, I’ll take a look at the
"HTTP-EQUIV" META tags.
 



Thanks for Reading!
– Vince Barnes

Top

Q
& A Goodies


Questions are taken
from submissions to our Community Mentors. You can ask a Mentor a question by
going to https://www.htmlgoodies.com/mentors/.




 

Q. I busy working on a site and need some
help regarding CSS. I was in an IE talk a few
years back and I could swear I remember
something about anti aliasing text within the
html, any ideas how and if it can be done?

A. Anti-aliasing is done by the browser
and the OS. To my knowledge, there is no way to
specify this in CSS. Check to see which fonts
you are using, and how you are declaring their
styles.

Q. I am new to Javascript. I have been
researching a way to unselect a number of
checkboxes once a specific checkbox is clicked
and vise-a-versa.

A. Here is a example that I put together
for someone else (you could replace the radio
buttons with form buttons and it would work the
same.)
<html>
<head>
<title>Check All</title>
<SCRIPT LANGUAGE="JavaScript">
function checkall(formid,obj)
{
len=formid.ckb.length
for(i=0;i<len;i++)
{
if(obj.value=="Check All")
{formid.ckb[i].checked=true}
if(obj.value=="Uncheck All")
{formid.ckb[i].checked=false}
}
}
function onlyone(fldobj)
{
alert(fldobj.name)
}
</SCRIPT>
</head>
<body>
<CENTER>
<FORM NAME="myform">
<INPUT TYPE="checkbox" NAME="ckb" onClick="onlyone(this)">
Checkbox One
<BR>
<INPUT TYPE="checkbox" NAME="ckb" onClick="onlyone(this)">
Checkbox Two
<BR>
<INPUT TYPE="checkbox" NAME="ckb" onClick="onlyone(this)">
Checkbox Three
<BR>
Check All<INPUT TYPE="radio" NAME="chka"
VALUE="Check All"
onClick="checkall(this.form,this)">
Uncheck All<INPUT TYPE="radio" NAME="chka"
VALUE="Uncheck All"
onClick="checkall(this.form,this)">
</FORM>
</CENTER>
</body>
</html>

Q. Whenever I make a background for a
page, it looks right on my screen but not on
other computers that have a different screen
resolution. Is there any way of getting a
background image to fit itself to everyone’s
screen or any other way round it?

A. Screen resolutions are a bane of
designing. You can’t know what the user’s
resolution will be, and you can’t change it. You
might be able to use some JavaScript to detect
the resolution and offer different backgrounds
accordingly. You can detect screen.availHeight
and screen.availWidth and have the script write
the body tag accordingly. Just in case someone
has JavaScript turned off, you might want to
have a design that works in the common
resolutions. The most common is 800×600, then
1024×768, then 640×480.

Q. I have a web page that has 3 links
going to the same page. When I click on one
link, the other links change to a visited link
color. Is it possible to stop the color of the
unclicked links from changing to a visited link
color?

A1. You can use css style commands to
change link colors or have them all the same
color. Here is the example code to have all red
links. Just edit as needed and add the same
color to each and then add the code in between
the <head> and </head> html tags:
<style type="text/css">
a:link {color: red;}
a:visited {color: red;}
a:active {color: red;}
</style>
(This stops them all from changing color — all
links to a visited page are going to have the
color specified for them by an "a:visited"
style, whether the style is specified as shown
here or by a class — Ed.)

A2. Another idea if you still need the
visited links to change color would be to send
each link to a different anchor on the target
page. It would look something like <a href="page.html#one>text</a>
<a href="page.html#two>text</a> on the first
page, then on the second page add <a
name="one"></a> <a name="two"></a>. The browser
will treat these like separate URLs and change
only the one that was clicked.
(Assuming you have control of the target page’s
content — Ed.)

 

Q. I would like to know if it is possible
to make an image open in a particular table of a
cell from a link in another cell. Kind of like
with frames where you tell it to open in a
TARGET frame.

A. If you give a cell a <span> with a
name you can access it with cellname.innerHTML="New
Stuff".
For example
<table>
<tr>
<td><a onclick="magiczone.innerHTML=’Look here
now!’">Click to change something.</a></td>
<td><span name="magiczone">Pretty boring over
here.</span></td> </tr> </table>
When someone clicks the link the text changes.
You can use <span> like that anywhere in your
files.
 

 

 

 

Top

News Goodies


Dell Launches New Small Biz Services
[December 9, 2002] The systems vendor aims for
the small- and medium-sized (SMB) service market.

Click
here to read the article

Debra Solomon, ‘Lizzie McGuire’ Animator
[December 9, 2002] The animator of television’s (and
soon-to-be-movie) ‘Lizzie McGuire’ cartoon character
talks about the perils and joys of working with
computer technology.

Click
here to read the article

Yahoo! Revamps Site Hosting
[December 9, 2002] The portal updates its offering
for the SMB market; the latest business hosting
iteration comes in three different service levels.

Click
here to read the article

 

Disney Lays Down Anti-Palm PDA Policy
[
December 6, 2002] Palm OS users are out of
luck. As the holidays near, Disney makes its PDA
policy loud and clear to employees: only
Blackberries and iPaqs allowed on its network.

Click
here to read the article



IDC: PC Shipments Will Surge in 2003
[December 6, 2002] While government spending is
expected to slow, IDC predicts business and consumer
spending on PCs will see moderate growth in 2003 and
2004

Click
here to read the article

 




Sklyarov Admits to Targeting PDF Weaknesses
[December 6, 2002] (See Elcomsoft item in last
week’s Goodies To Go) Skylarov admitted writing a
software program that, in part, was designed to
bypass the copyright protections in Adobe Systems’
eBooks


Click here to read the article

 




Microsoft’s Revamped Finance Suite Touts Integration

[December 5, 2002] Microsoft on Thursday lifted
the veil off the newest version of its Small
Business Manager accounting software, touting
slicker integration to its bCentral Web services
platform and applications with Microsoft Office.


Click here to read the article

 

 



Intel, IBM Team With AT&T To Push Nationwide Wi-Fi
[December 5, 2002] Gambling on the future of
wireless connectivity, tech bellwethers AT&T, Intel
and IBM Thursday pooled their resources behind a new
company that will offer wholesale nationwide
wireless Internet access.


Click here to read the article

 

 

 

 

Top

Feedback
Goodies


Did you ever wish your newsletter was an easy two way communications medium?
Ploof! It now is!
If you would like to comment on the newsletter or expand/improve on something
you have seen in here, you can now send your input to:

mailto:nlfeedback@htmlgoodies.com

We already receive a lot of email every day. This address will help us sort out
those relating specifically to this newsletter from all the rest. When you send
email to this address it may wind up being included in this section of the
newsletter, to be shared with your fellow readers.

Chris (Black Knight) had a suggestion regarding
links that would enable a reader to jump around
inside a copy of the newsletter to facilitate
reading items of most interest first. It’s a great
idea, Chris. We send out the newsletter in text form
to enable it to be read by any email client, even
those incapable of reading HTML. After a while,
however, each newsletter finds its way into the
archives, where we have (recently added) hyperlinks
of the sort you suggest. You can find the archives
at
https://www.htmlgoodies.com/letters/
(there’s a
link on our home page also.)

Regarding last week’s discussion of firewalls: many
thanks to Guy Dorey from the UK who would like to
remind us of the firewall product "Zonealarm" (

http://www.zonelabs.com
)

We also got a few emails about "hacking". Mostly,
people wanted to distinguish between "crackers" and
"hackers". Generally, the writers indicate that
crackers are the bad guys, and hackers not so bad.
The reasoning says that hackers are only trying to
prove the vulnerability of systems, not trying to
obtain information or destroy anything. One writer
argued that "the role of a hacker is actually a
pretty noble one". I’d like to point out that that
job is one performed by security consultants and
security team members at the request of, and with
participation of, the system’s owners and operators.
In the US, the mere attempt to penetrate a system is
a crime, regardless of the sense of nobility of the
person behind the attempt or the name they call
themselves and regardless of whether or not they
succeed, gather information or damage anything. The
attempt itself is a crime. Similar laws exist in
most (if not all) countries.
 

 

 

 

Top
And
Remember This
. . .

On this day in…

1864: George Boole Dies
Mathematician George Boole died on this day in 1864.
By age 16, Boole began to teach others in order to
support himself and his family. He was an avid
student of Mathematics and submitted papers to
prominent journals describing his work on symbolic
representation of logic. His methods, which include
those we now know as Boolean logic, are an integral
and critical part of computer systems and
programming. Boole was appointed professor of
mathematics at Queen’s College in County Cork,
Ireland, and later became a fellow of the Royal
Society. Boole had no formal education. He was
self-taught.

and yesterday, December 8th…
1980:
John Lennon was shot and killed in New
York. He was 40. The murderer, mdc (I’d actually
prefer to refer to him only by his prison number,
but I don’t know it) was denied a parole hearing in
2000 because "your vicious and violent act was
apparently fueled by your need to be acknowledged."
He remains imprisoned in Attica, New York.

and the day before, December 7th…
1941:
at 7:55am the first of 360 Japanese
warplanes struck ships in Pearl Harbor, Hawaii.

 



Thanks for reading
Goodies to Go!


 




Archive
Home Page.


Get the Free Newsletter!

Subscribe to Developer Insider for top news, trends & analysis

Popular Articles

Featured