add original javascript to convert