The procedure for electing the President and Vice President are laid out in the Twelfth Amendment.
Article II, Section 1, Clause 2 of the Constitution requires each state legislature to determine how electors for the state are to be chosen, but it disqualifies any person holding a federal office, either elected or appointed, from being an elector. Under Section 3 of the Fourteenth Amendment, any person who has sworn an oath to support the United States Constitution in order to hold either a state or federal office, and later rebelled against the United States, is disqualified from being an elector. However, the Congress may remove this disqualification by a two-thirds vote in each House.
Candidates for elector are nominated by their state political parties in the months prior to Election Day. In some states, the electors are nominated in primaries, the same way that other candidates are nominated. In some states, such as Oklahoma, Virginia and North Carolina, electors are nominated in party conventions. In Pennsylvania, the campaign committee of each candidate names their candidates for elector (an attempt to discourage faithless electors).
Since the Civil War, all states have chosen presidential electors by popular vote. This process has been normalized to the point that the names of the electors appear on the ballot only in a handful of states.
The Tuesday following the first Monday in November has been fixed as the day for holding federal elections, called the Election Day. Forty eight states and Washington, D.C., employ the "winner-takes-all method", each awarding its electors as a single bloc. Maine and Nebraska use the "congressional district method", selecting one elector within each congressional district by popular vote and selecting the remaining two electors by a statewide popular vote. This method has been used in Maine since 1972 and in Nebraska since 1996.
The current system of choosing electors is called the "short ballot". In most states, voters choose a slate of electors, and only a few states list on the ballot the names of proposed electors. In some states, if a voter wants to write in a candidate for president, the voter is also required to write in the names of proposed electors.
After the election each state prepares seven Certificates of Ascertainment, each listing the candidates for president and vice president, their pledged electors, and the total votes each candidacy received. One certificate is sent, as soon after Election Day as practicable, to the National Archivist in Washington D.C. The Certificates of Ascertainment are mandated to carry the State Seal, and the signature of the Governor (in the case of the District of Columbia, the Certificate is signed by the Mayor of the District of Columbia).
This is why the Republicans were so very hard behind Cruz, they had someone who they could use as a pretty face to Rat Fuck Trump with by having someone the delegates could throw their votes at regardless of the popular vote.
I have been asked who I am voting for in this Presidential Election.
I'm not going to bother with it.
The system is rigged to begin with and neither of the two most popular candidates represent my beliefs anyway.
Trump is a Carpetbagger with no specific platform and Hillary is a proven criminal enterprise.
The country we grew up in is dead and we are all just Free Range prisoners wasting time on the charade of electing the warden.
I have better things to do.
The only reason I pay attention to this farce is from a sense of morbid curiosity and the entertainment value I get from observing much ado about nothing.
It's very much like watching a Soap Opera.
A very expensive and elaborate one.