hack a logReplace function so logs don't flood the page

added quick and dirty logAppend and logReplace functions because appending a million lines to the log is messy. :)