Sec. 1. Where a defendant, in the course of a criminal action, gives bail before any court or person authorized by law to take same, for his personal appearance before a court or magistrate, to answer a charge against him, the said bond shall be valid and binding upon the defendant and his sureties, if any, thereon, for the defendant's personal appearance before the court or magistrate designated therein, as well as before any other court to which same may be transferred, and for any and all subsequent proceedings had relative to the charge, and each such bond shall be so conditioned except as hereinafter provided.