Whenever the office of judge of the circuit court of any county is vacant at the commencement of a term of such court, or the judge of said court shall fail to attend, the regular practicing attorneys in attendance on said court may meet at 10 o'clock a. m. on the second day of the term and elect a judge to preside at such court, or until the regular judge shall appear; and if the judge of said court shall become sick or die or unable to continue to hold such court after its term shall have commenced, or shall from any cause be disqualified from presiding at the trial of any cause then pending therein, then the regular practicing attorneys in attendance on said court may in like manner, on notice from the judge or clerk of said court, elect a judge to preside at such court or to try said causes, and the attorney so elected shall have the same power and authority in said court as the regular judge would have had if present and presiding; but this authority shall cease at the close of the term at which the election shall be made. The proceeding shall be entered at large upon the record. The special judge shall be learned in the law and a resident of the State.