When you are in labor and getting ready to give birth, your cervix does shorten. This is what they call effacement. When you are 100% effaced your cervix has disappeared, making it possible for the baby to be born.
When you are pregnant your cervix will be closed until the baby is born. When your baby is ready to come it will start to open. It will go back to regular size after birth.