sed changes go to standard out....?

Hi gang: Need some help with "sed". The script below is working except for the sed command. It does replace the words I'm searching for but the change goes to standard out (screen) so the file is not updated. How do I get sed to modify the file?? I'm sure it something simple...
Thanks All !!! This is running Solaris 8

#! /bin/sh

# Begin shell script to modify the netmap

echo "Welcome to the netmap edit tool"
echo "What would you like to do?"

echo 1. Add a node to the netmap
echo 2. Modify a node in the netmap
echo 3. Delete a node in the netmap.

read choice
# Begin choice determination logic

if [ $choice = 1 ]
then
# logic to add a new node to current netmap

cat newnode >> netmap.cfg

# New Node info collection
echo " Enter the new node name"
read newnodename

sed "s/bogus/$newnodename/" netmap.cfg

echo "Enter IP address of new node"
read IP

sed "s/ipaddress/$IP/" netmap.cfg

else
echo "Still under construction"
fi

use sed -ie

sed -ie "s/bogus/$newnodename/" netmap.cfg

Hmmm... Here is the outcome.. Doesn't seem to like the "i".

Enter the new node name
JJJJJJJ
Enter IP address of new node
100.10.0
sed: illegal option -- i

New code:
# New Node info collection
echo " Enter the new node name"
read newnode

echo "Enter IP address of new node"
read IP

sed -ie "s/bogus/$newnode/" netmap.cfg

If your sed doesn't have the -i option, you will need to redirect to a temporary file, then move the temporary file over the original file.

You can do both substitutions in a single sed script after you collected all the user input.

sed -e "s/bogus/$newnodename/" -e "s/ipaddress/$IP/"

Your first beta tester will want to input an IP address with a slash in it, and then you're screwed (^:

Man... this was subtle... Here's the answer... has to redirect to a tmpfile and then cat to the file I'm using.... Thanks for the help era you got me pointed in the right direction..

# Begin choice determination logic

if [ $choice = 1 ]
then
# logic to add a new node to current netmap

# New Node info collection
echo " Enter the new node name"
read newnode

echo "Enter IP address of new node"
read IP

sed -e "s/bogus/$newnode/" -e "s/ipaddress/$IP/" newnode >tmpnode
cat tmpnode >> netmap.cfg

rm tmpnode

else
echo "Still under construction"
fi

Actually if you are always appending to netmap.cfg then you don't need the temporary file at all.

sed -e "s/bogus/$newnode/" -e "s/ipaddress/$IP/" newnode >>netmap.cfg

Sorry, I missed this detail.