back to Deljunk
back to Computer stuff
home

Copy and paste the following (but don't include the "last updated" line!) into C:\bat\DelCooki.bat

@echo off

REM "if exist *.*", or its converse, detects hidden files.

echo Note: Remember to watch the echoed directory when reminded "All files in
echo directory will be deleted!", especially if running this utility after making
echo changes to this script or to the directory structure of the computer.
REM (Suggest 80 column editing guide here - use dots and vertical lines and copy and paste)
REM As the programmer, always check for the directory before going to it
REM (eg "if not exist winzip.log goto CW32"),
REM and always put a "cd" by itself before any delete command, for the benefit of the user (you!).
REM As the user, train yourself to watch the echoed directory before approving any deletes.

echo Directories will be echoed where junk found
c:\windows\command\choice /C:ync /N "OK to start looking for and deleting any Cookies? (y/n/c)>"
if errorlevel 3 goto END
if errorlevel 2 goto END

c:

echo Searching for cookies to delete... (directories echoed where junk found)
echo.

:CPJNETZ
if not exist c:\Progra~1\Netscape\Users\CAP_J\nul goto V7NSCK
cd\Progra~1\Netscape\Users\CAP_J
if not exist cookies.txt goto V7NSCK
cd
echo cookies.txt were found in this directory
if not exist c:\bat\delnscck.bat echo c:\bat\delnscck.bat is required to delete Netscape cookies but was not found.
if exist c:\bat\delnscck.bat call c:\bat\delnscck.bat

:V7NSCK
if not exist c:\Windows\APPLIC~1\Mozilla\Profiles\cap_j\foo.slt\nul goto WINCOOK
cd\Windows\APPLIC~1\Mozilla\Profiles\cap_j\foo.slt
if not exist cookies.txt goto WINCOOK
cd
echo cookies.txt were found in this directory
if not exist c:\bat\delnscck.bat echo c:\bat\delnscck.bat is required to delete Netscape cookies but was not found.
if exist c:\bat\delnscck.bat call c:\bat\delnscck.bat

:WINCOOK
if not exist c:\bat\delwinck.bat echo c:\bat\delwinck.bat is required to delete Windows cookies but was not found.
if exist c:\bat\delwinck.bat call c:\bat\delwinck.bat


:FUP
echo.

echo Done.

:END
echo.
echo Click on the X in the top right-hand corner of the Finished MS-DOS Window; that will clear it.
 

Last updated May 26: I added code to delete cookies from ver 7.02 of Netscape
March 29, 2003