Cannot read property 'replaceChild' of undefined at replaceMessage
<script type="text/javascript">
function replaceMessage(){
var oldnode = document.getElementsByTagName("b");
var oldnodetext = oldnode.innerHTML;
var newnode = document.createElement('i');
oldnode.perentNode.replaceChild(newnode,oldnode)
newnode.innerHTML = oldnodetext;
}
</script>
哪里写错了呢?为什么报这个错