Although he didn't mention his detractors by name, Bush's comments about Iraq were a slap at Democratic presidential nominee and a boost to Sen. , the Republican candidate.
"The commander in chief must always listen to the commanders, and not the latest opinion polls," Bush said during a speech to the annual convention of the Veterans of Foreign Wars.
"America's future leaders must remember that the war on terror will be won on the offense. And that's where our military must stay," Bush said. Obama and McCain are sharply divided about the war in Iraq. Obama opposed it and says he will bring American forces home; McCain was a strong supporter of the war and the surge, and he opposes a quick pullout.
Bush also prodded Russia to honor its commitment to leave pro-Western Georgia, a small, former Soviet republic that has come "under siege" from its larger neighbor.
Bush said it can no longer be "business as usual" with Russia due to its aggression. He said the breakaway regions of South Ossetia and Abkhazia are part of Georgia and that Washington will work with allies to insure Georgia's independence and territorial integrity.
Obama, addressing the VFW on Tuesday, reaffirmed his early opposition to the U.S. invasion of Iraq. He said the surge of troops has not led to the political reconciliation needed to ensure the country will remain secure once all U.S. troops are gone.
McCain, in an appearance before the same group on Monday, repeated his support for the president's January 2007 decision to add 30,000 U.S. troops in Iraq. The increase is credited with reducing violence in Iraq, and the additional troops have already returned home.
McCain criticized Obama for not only opposing the surge but trying to block the funding that would have allowed the increase.
Bush flew to Orlando from his ranch in Crawford, Texas. Later in the day the president was visiting New Orleans and Gulfport, Miss., to talk about ongoing recovery efforts from Hurricane Katrina in 2005.
Bush told the VFW this would be his final appearance before a veterans group as commander in chief. His remarks were preceded by a video slide show highlighting the role of the military and its veterans.
"You live by a code and you fight for a cause and I'm honored to be your commander in chief," Bush said in the slide show.
VFW National President George Lisicki introduced Bush to an enthusiastic crowd in the Orlando Convention Center. Veterans organizations have pushed aggressively for expanded benefits for veterans and have not always seen eye-to-eye with the Bush administration.
But Lisicki said there's one thing they all agree on: "Our nation does not go to war to lose."
Bush ticked off a long list of accomplishments for veterans during his two terms in office. The annual budget for the Veterans Affairs Department is $94 billion, an amount he said is nearly double for veterans when he took office.
The wars in Iraq and Afghanistan have produced a larger number of veterans in need of specialized care from traumatic injuries caused by roadside bombs and other terror weapons.
Bush's speech highlighted themes that McCain has been using to argue that he is better qualified to be commander in chief than Obama.
In his remarks, Bush said the war on terror "cannot be won, however if we treat terrorism primarily as a matter of law enforcement. Law enforcement is an essential part of our strategy but our strategy cannot be limited to law enforcement alone."
Bush said the U.S. prosecuted people responsible the first bombing of the World Trade Center in 1993 "but eight years later al Qaeda terrorists came back to finish the job."
Obama in June said the government can crack down on terrorists "within the constraints of our Constitution." He mentioned the indefinite detention of Guantanamo Bay detainees, contrasting their treatment with the prosecution of the 1993 World Trade Center bombings.