Not capable of writing valid javascript