Secondo me e` sbagliato, ma qualche browser potrebbe interpretare quello che intendevi. Prova il tuo script con altri browser.

Dovresti scrivere:
if (dove=="parent") window.history.go(-1);
else window.open('nuovapagina.htm','','width=600,height =600');

Ciao
Michele