in the 1866 costa rican general election josé maría castro madriz was elected president of costa rica in april 1st, 1866 for the 1866-1869 period, which would not finish since in 1868 he was overthrown by his predecessor jesús jiménez zamora. madriz had previously been president and had been overthrown in his first presidency.