Tuesday, March 19, 2024

Goodies to Go! Newsletter #320


Goodies to Go ™
January 17, 2005 — Newsletter # 320

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


Featured this week:

* Goodies Thoughts – Port Redirection
* Q & A Goodies
* News Goodies

* Feedback Goodies  
* Windows Tech Goodies  
* And Remember This

 


 

Goodies Announcement

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 – Port Redirection


The question has come up a few times recently, regarding the
problem of hosting a web site at home when your Internet Service Provider keeps
changing your IP number, and worse, blocks TCP/IP port 80, which is the HTTP
default port – i.e. the port you need open in order the serve up a web site.
Most broadband service providers block this port on connections provided to
residences.

The solution is quite simple, and has been covered before in this newsletter and
on the HTML Goodies website. What you need in Dynamic DNS and Port Redirection.
For those who may have missed this info, or for those who might like a
convenient quick reference, here are some links to the details of the required
solution:

You’ll need to register a name and point it to your computer. See this article
for some thoughts here:

http://www.htmlgoodies.com/nontechintro/ntipart2.html
 

If your provider blocks port 80, the web port, to prevent you from hosting
websites at home, or changes your IP address with some regularity so that you
can’t set the Domain Name System (DNS) to consistently point to your computer
without having to reset the DNS, see Goodies To Go number 247 at

http://www.htmlgoodies.com/letters/247.html
for solutions to these minor
irritations.

Also note that hosting a website is possible on either Windows or Linux (and
other OS’s, of course; but these are the most common.) but there are
consideration concerning each of these choices; and there is an article covering
those considerations here:

http://www.htmlgoodies.com/articles/winvsinuxhost1.html

 

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

http://www.htmlgoodies.com/mentors
.

Q. I am trying to set up a framed site, with a dropdown list on the left,
and the main page to the right. I currently have the frame with the dropdown
list setup so that when the selection is changed, it opens up the selection in
that same frame. Is there anyway to change the frame it opens in? I need the
menu on the left to bring up the pictures in the main frame rather than the left
one.

A. You need to change this link in your linkup function:
location.href = document.DropDown.images.options[number].value;
To this:
parent.frame2.location.href = document.DropDown.images.options[number].value;
I would also recommend that you change the name of your dropdown as "images"
might cause a problem with JavaScript.

Q. In JavaScript Primer 28, the script does not work with my browser,
Internet Explorer 6.0. I believe that it has to do with nesting loops within
loops, but I am not sure. There is a note that some Internet Explorer browsers
will not display the code. What part of the JavaScript code is not working?

A. Not sure why it does not work for you in IE, but here is a modified
version that works using the setTimeout method to control the fliping of images.
<html><head>
<script type="text/javascript">

var num=1 img1 = new Image (150,150)
img1.src = "0.gif" img2 = new Image (150,150)
img2.src = "1.gif" img3 = new Image (150,150)
img3.src = "2.gif"
function startshow()

{
num=num+1
if(num<4)
{
document.mypic.src=eval(‘img’+num+’.src’)
anim=setTimeout(‘startshow()’,3000)
}
else

{
num=0
clearTimeout(anim)
document.mypic.src=img1.src
}
}
</script>
</head>
<body>

<center>
<img src="0.gif" name="mypic" border=0 alt="My Image">
<br>
<a href="JavaScript:startshow()">Display animation</a> </center> </body> </html>

Also here is a brief explanation of setTimeout:
setTimeout, a method of the window object, basically delays the execution of a
function or statement until the specified time has passed. The basic syntax of
this function is:
setTimeout("expression", delaytime)
"expression" is the function/statement you want delayed, and delaytime is the
delay time, in milliseconds.
I also use clearTimeout to stop the animation once it reaches the end of the
images array.

Q. I would like to use CSS alone (no JavaScript) to put an image in the
background of a table element (td), and still be able to have text = appear over
the background image. I have been trying to find all references to
background-image, but most refer to body, and the others only replace text in a
td cell.=20 Can it be done?

A. The style for background images applies to most tags: body, p, div,
td, li, etc.
<table>
<tr>
<td style="background-image: url(image.gif);">

TEXT GOES HERE
</td>
</tr>
</table>
Alternately you can define the styles in an external style sheet: td {
background-image: url(image.gif); }
Two good resources for CSS are:

http://www.blooberry.com/indexdot/css/

http://www.mako4css.com/

Q. I would like to eliminate the use of the Enter key that a user may
enter while in a TextArea. How can I do that?

A. Here is a script example that will ignore the enter key in a textarea:
<html>

<head>
<title>Test</title>
<script language="JavaScript">
IE5=document.all? 1:0
function stopkey(e)
{
whKey = !IE5? e.which:event.keyCode; // check for NS4 and NS6

window.status=whKey // Display ascii code in status bar
if(whKey==’13’) // check for ascii enter key (ascii)
{
return false;
}
}
</script>
</head>
<body>

<center>
<form name="myform">
<textarea name="txta" cols="30" rows="4" WRAP="hard"

onkeypress="return stopkey(event)" >Enter your response here</textarea>
</form>
</center>
</body>
</html>

 

 

 

 

Top

News Goodies


CA Modifies Desktop DNA

[January 17, 2005] The first real upgrade since its purchase of
the technology last year holds file management and PC settings
capture improvements.

Click
here to read the article

 

Sun Offers Nailed-Down RFID For Retail

[January 17, 2005] New industry-specific reference architecture unveiled at
national retailing show.

Click
here to read the article

 

 

 


Rolling With 3G

[January 14, 2005] FEATURE: Talking about a third generation?
After many false starts, 3G is rolling out in the United States.
Which carriers, equipment vendors and handset makers have the
early lead?

Click here to read the article

 

 

 

Oracle Announces 5,000 Job Cuts
[January 14, 2005] UPDATED: PeopleSoft employees wait
anxiously for 5,000 FedEx packages containing pink slips.

Click here to read the article
 

 

 

FBI’s Virtual Case File Flops
[January 14, 2005] FBI goes back to the drawing board for a state-of-the-art
case management system — as technology advances ahead of it.

Click here to read the article

 

 

 

Z-Wave Wants to Be Your Standard
[January 14, 2005] The battle for wireless home control is on, as Zensys
prepares to open up access to its wireless technology in the wake of ZigBee
1.0’s arrival..

Click here to read the article

 

 



Search Ads Reap Big Rewards

[January 14, 2005] Doubleclick reports that search advertising revenues grew
by more than 300 percent in the third quarter.

Click here to read the article

 

 

 

HP to Merge Printing, Personal Systems Groups
[January 14, 2005] UPDATED: HP will bundle its printer and personal
computing group to streamline operations.

Click here to read the article


 

 

Big Spam Bust, Texas Style
[January 14, 2005] State files multi-million dollar lawsuit against two of
nation’s largest e-mail operators.

Click here to read the article

 

 

 


Apple’s iPod Shuffle Stifles Podcasting

[January 14, 2005] Audio bloggers say even the new 1GB
Flash-based player is not enough for a full show.

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.
Please don’t send your questions to this address.
They should be sent to our mentors: see
http://www.htmlgoodies.com/mentors/

Thanks again for all your feedback!
 

 

Top


 


Windows Tech Goodie of the Week:
 

Populating ASP.NET Form Validators from XML

In large web applications, maintaining form validation
criteria can become quite a chore. This article, by Robert
Walling, will take a detailed look at a validation class
that enables you to store these details in an accompanying
XML file in order to make managing them much simpler.


http://www.15seconds.com/issue/050112.htm

*** AND ***

A Code Template for a Pageable, Bi-Directional Sortable
DataGrid

Any ASP.NET developer that has had to display database data
on an ASP.NET page is likely familiar with the DataGrid Web
control. This article examines a template for building an
ASP.NET page with a pageable, bi-directional sortable
DataGrid.


http://aspnet.4guysfromrolla.com/articles/011205-1.aspx


 

 

 

Top


 

And Remember This . . .

On this day in…
 

On this day in…

1861 patent for a flush toilet with a water tank and pull
chain granted to Mr. Thomas Crapper; 1871 patent granted for
a cable car (first went into service in 1873); 1926 George
Burns married Gracie Allen; 1928 patent granted for a fully
automatic film developing machine; 1929 Popeye made his first
appearance; in the cartoon "Thimble Theatre"; 1946 the first
meeting of the United Nations Security Council was held; 1969
the Beatles released Yellow Submarine in the UK; 1969 Led
Zeppelin’s debut album was released in the US; 1987 President
Reagan signed a secret order permitting covert sale of arms to Iran;
1989 a gunman opened fire in a schoolyard in California,
killing five children and wounding thirty; 1994 a 6,6
earthquake hit Los Angeles, killing 60 and causing $30B in damage;
1995 a 7.2 earthquake hit Kobe, Japan, killing 5,372; 1998
Paula Jones filed sexual harassment charges against President
Clinton;

Born today were: in 1706 statesman Benjamin Franklin; 1820
English novelist Ann Bronte; 1880 movie creator Mack Sennett
(Keystone Kops); 1899 novelist Nevil Shute; 1899
gangster Al Capone; 1922 actress Betty White; 1925
actor Rock Hudson; 1927 singer Eartha Kitt; 1928

English hairstylist Vidal Sassoon; 1931 actor James Earl
Jones; 1934 ventriloquist Shari Lewis; 1939 TV
personality Maury Povich; 1942 boxer Muhammad Ali (Cassius
Clay); 1949 comedian Andy Kaufman; 1956 actor David
Caruso; 1962 Canadian actor/comedian Jim Carrey;





Thanks for reading Goodies to Go!

Get the Free Newsletter!

Subscribe to Developer Insider for top news, trends & analysis

Popular Articles

Featured