Republican presidential contender Rudy Giuliani pushed the idea of a "virtual" rather than a real fence along much of the U.S.-Mexico border on Monday, an issue that's controversial in the Rio Grande Valley where many people oppose construction of a physical fence to stop illegal immigration.

The former New York mayor said that while a physical fence is needed in some places, most of the border should be policed with high-tech monitoring. He toured the border Monday along the southernmost tip of Texas with state and local officials.

"And frankly, the virtual fence is more valuable because it alerts you to people approaching the border, it alerts you to people coming over the border," Giuliani said, the Rio Grande in the background.

Giuliani said his approach could end illegal immigration within three years.

Giuliani did not specifically address the idea of a fence in the Rio Grande Valley, the most heavily populated portion of the Texas-Mexico border. Opponents, including most local elected officials, say a physical fence would restrict access to the river and hurt their livelihoods, in some cases creating a no man's land between the river and the fence.

Gov. Rick Perry, who has endorsed Giuliani, opposes construction of a 1,200-mile wall along the U.S-Mexico border. Instead, he supports fencing at strategic points, such as in bigger cities, along with more border patrol agents and high-tech monitoring of the kind Giuliani seeks, spokesman Robert Black said Monday.

Perry has a plan to broadcast live video footage, beginning next year, from mobile cameras along the Texas-Mexico border.

Giuliani also addressed New York's "sanctuary" policy, which barred city workers during his administration from reporting suspected illegal immigrants who enrolled their children in school or sought hospital treatment. GOP rivals Mitt Romney, the former Massachusetts governor, and Fred Thompson, the former Tennessee senator, have criticized Giuliani for supporting the policy. Giuliani says Romney tolerated such policies in Massachusetts.

Giuliani said he cracked down on all crimes, including illegal immigration.

"The policies that I utilized with regard to illegal immigration were in the context of overall policies that probably were the most successful in the history of the country in creating an orderly, legal, lawful society," he said.

Romney campaign spokesman Kevin Madden said: "Mayor Giuliani created an amnesty haven in New York City, and as a result he hampered enforcement efforts and hurt our nation's ability to secure our borders. He has exactly the wrong approach to a very serious problem."

In New Hampshire on Monday, Giuliani began airing a new ad that promotes his government leadership positions, from Justice Department official to mayor of New York. "I believe I've had the most leadership experience of anyone that's running. It's not just holding executive positions, like mayor of New York, or United States Attorney, or third-ranking official in the Reagan Justice Department. It's having held those positions in time of crisis," he says in the ad.

Despite his reference to crisis, the ad does not mention the Sept. 11, 2001, terrorist attacks, the moment of crisis most identified with Giuliani. As in a previous ad, Giuliani declares that his experiences make him a "tested" leader. "They're not going to find perfection, but they're going to find somebody who has dealt with crisis almost on a regular basis and has had results," he says.