MIAMI (AP) -- John McCain charged that Barack Obama lacks "what it takes to protect America from terrorists" Wednesday as he sought to shift attention away from the economy in the final week of the race for the White House. Obama cast his rival as a threat to the middle class, and readied a 30-minute prime-time commercial at a cost of millions.
Obama, who has led in the polls for weeks, toughened his rhetoric as Republicans and even some Democrats said the race to pick the next president was tightening somewhat nationally and in some battleground states.
Yet Associated Press-GfK polls taken within the past several days showed Obama ahead in six states that supported President Bush in 2004 and essentially even with McCain in two others. A separate survey suggested even McCain's home state of Arizona was not safely in his column.
"If Senator McCain is elected, 100 million Americans will not get a tax cut ... your health care benefits will get taxed for the first time in history ... we'll have another president who wants to privatize part of your Social Security," Obama said in Raleigh, N.C.
North Carolina is one of the states he hopes will deliver him a sizable victory next Tuesday.
His appearance was prelude to a costly campaign-closing commercial. Obama bought time on CBS, NBC and Fox for $1 million per network for the 30-minute commercial. He also bought time for it on Univision, BET, MSNBC and TV One.
Campaign officials said a portion of the commercial would include a live appearance of Obama addressing a rally in Kissimmee, Fla., and the rest would consist of videotaped segments showing him chatting with voters about a variety of issues.
McCain lacked the money for the type of nationwide commercial that Obama could afford, and was relying instead on traditional 30-second advertisements. They, too, run less frequently than Obama's, a reflection of the financial disparity in the race.
The Republican, a former Naval aviator and prisoner of war, was in Florida during the day, where he assembled a group of former military officers and other national security advisers.
"The question is whether this is a man who has what it takes to protect America from Osama bin Laden, al-Qaida and the other great threats in the world," he said of Obama. "He has given no reason to answer in the affirmative."
Earlier in the campaign, former Democratic rival Hillary Rodham Clinton as well as McCain sought to raise doubts about Obama's relatively thin resume on foreign policy and national security matters.
In response, Obama traveled last summer to Iraq, Afghanistan and Europe, where he met with world leaders. Later, he tapped Sen. Joseph Biden, who has long experience in foreign policy, as his vice presidential running mate.
More recently, he won an endorsement from former Secretary of State Colin Powell.
Conversely, McCain has slumped in the polls as the economic crisis has unfolded in the past several weeks.
Speaking to reporters Wednesday, he said the economic meltdown, while serious, was temporary, and the nation would emerge stronger.
Besides Obama, he criticized the Democratic leaders of Congress, who hope to command larger majorities in the new House and Senate than they do now.
"We're getting only a glimpse of what one-party rule will look like," he said, predicting deep cuts in defense spending and efforts to shrink America's role in the world if Democrats take over the government.
"Let there be no confusion about the threats we face," said McCain. "I've had to make some defining choices along the way," he added in what seemed to be a reference to his time in the Navy, more than five years of which were spent as a prisoner of war in Vietnam.
Obama blended his sharp rhetoric with a more humorous approach as he sought to fend off McCain's charge that his tax policies amount to socialism.
McCain, he said, will soon "be accusing me of being a secret communist because I shared my toys in kindergarten."
By any available survey, the economy trumps the war in Iraq and national security issues in the campaign's final days, and McCain fares better on foreign policy matchups than on pocketbook issues.
The AP-Gfk surveys underscore the point, in surveys in the battleground states of Colorado, Florida, Nevada, New Hampshire, North Carolina, Ohio, Pennsylvania and Virginia.
Obama won at least 50 percent support in each of the states when voters were asked which candidate they trusted to improve the economy.
When it came to national security, voters in Florida, North Carolina and Ohio preferred McCain, and the two rivals were in statistical ties in the other five states.
The Arizona survey was by Cronkite/Eight, and it showed McCain with 46 percent support, to 44 for Obama, a statistical tie. McCain has not betrayed any concern about losing the state, and Obama has not campaigned there or run statewide television ads.
The same could not be said of numerous other Republican states, and the candidate itineraries in the final days of the race suggested Obama was running to pile up a large Electoral College margin while McCain was hoping to eke out a victory.
While some Republicans said their polling showed a significant tightening in New Hampshire, both men have visited only one state in recent days that voted for Democratic Sen. John Kerry in 2004 - Pennsylvania.
Republican running mate Sarah Palin was in Ohio on Wednesday, where she stressed the ticket's commitment to achieving energy independence.
She pledged a "clean break not just from the politics of the current administration, but from thirty years' worth of failed policies in Washington."
Palin, the governor of Alaska, described herself as "a gal who knows the North Slope of Alaska," an energy-rich region, and someone who took on the powerful oil industry. She made no mention of having sought and won higher taxes on oil companies, a position unlikely to win favor among conservatives.
Democratic vice presidential candidate Joe Biden was in Florida, where he helped train volunteers as part of a massive early voting program. "We need some help spreading the faith in the next six days," he said.
David Espo reported from Washington. AP writers Ben Feller and Kelli Kennedy contributed from Florida, Beth Fouhy from Ohio and Jim Kuhnhenn from Washington.