#  deleteTags:Tcl
#   Parses tags from an HTML file 
#   Requires: fileLib.tcl

proc deleteTags { inFile outFile} {

  set data [readEntireFile $inFile]
  regsub -all "\n" $data {} data
  regsub -all {\[} $data {} data
  regsub -all {\]} $data {} data
  writefile $outFile $data
  set tagCount [parse $outFile < 250 > tagFile]

  set fileID [open tagFile "r"]
  for {set xx 0} {$xx < $tagCount} {incr xx} {
    gets $fileID parsedTag
    puts $parsedTag
    puts [regsub $parsedTag $data \n data]
  }
  close $fileID
  writefile $outFile $data
}