The party's dramatic reversal on civil rights issues culminated when Democratic President Lyndon B. Johnson signed into law the Civil Rights Act of 1964. On doing so he commented, "We [the Democrats] have lost the South for a generation." Meanwhile, the Republicans, led again by Richard Nixon, were beginning to implement their Southern strategy, which aimed to resist federal encroachment on the states, while appealing to conservative and moderate white Southerners in the rapidly growing cities and suburbs of the South. Southern Democrats took notice of the fact that 1964 Republican Presidential candidate Barry Goldwater had voted against the Civil Rights Act, and in the presidential election of 1964, Goldwater's only electoral victories outside his home state of Arizona were in the states of the Deep South.
The year 1968 was a trying one for the party as well as the United States. In January, even though it was a military defeat for the Viet Cong, the Tet Offensive began to turn American public opinion against the Vietnam War. Senator Eugene McCarthy rallied anti-war forces on college campuses and came within a few percentage points of defeating Johnson in the New Hampshire primary. Four days later Senator Robert Kennedy, brother of the former president, entered the race. Johnson stunned the nation on March 31 when he withdrew from the race; four weeks later his vice-president, Hubert H. Humphrey, entered. Kennedy and McCarthy traded primary victories while Humphrey stayed out the primaries and gathered the support of labor unions and the big-city bosses. Kennedy won the California primary on June 4 and may have been able to wrest the nomination from Humphrey, but he was assassinated in Los Angeles. (Even as Kennedy won California, Humphrey had already amassed 1000 of the 1312 delegate votes needed for the nomination, while Kennedy had about 700.[10]) During the 1968 Democratic National Convention, while police and the National Guard violently confronted anti-war protesters on the streets and parks of Chicago, the Democrats nominated Humphrey. Meanwhile Alabama's Democratic governor George C. Wallace launched a third-party campaign and at one point was running second to the Republican candidate Richard M. Nixon. Nixon barely won, with the Democrats retaining control of Congress.
The degree to which the Southern Democrats had abandoned the party became evident in the 1968 presidential election when the electoral votes of every former Confederate state except Texas went to either Republican Richard Nixon or independent George Wallace, the latter a former Southern Democrat. Defeated Democrat Hubert Humphrey's electoral votes came mainly from the Northern states, marking a dramatic shift from the 1948 election 20 years earlier, when the losing Republican candidate's electoral votes were mainly concentrated in the Northern states.