Video

Senator Lindsey Graham will probably have to change his cellphone number.

That’s because Donald J. Trump, the provocative Republican presidential contender, brandished a card showing the South Carolina senator’s phone number from the stage at a speech on Tuesday afternoon, reading the digits aloud and encouraging people to dial.

The reaction on Twitter was explosive. Several journalists wrote that the number was, indeed, Mr. Graham’s. Some people watching the speech on a livestream said they dialed it; one reported hearing a voice mail message identifying the phone number as belonging to Mr. Graham, and another said a man who sounded like Mr. Graham answered and hung up.

"i do not know what that is what is 'updog'?" pic.twitter.com/GNqFVZChg3 — darth!™ (@darth) July 21, 2015

I just called Lindsey Graham's cell too. Went straight to voice mail. — Ben Jacobs (@Bencjacobs) July 21, 2015

The prank, more typical of shock radio hosts than presidential candidates, intensified the back-and-forth between Mr. Trump and Mr. Graham – one that began when Mr. Graham assailed Mr. Trump for describing Mexican immigrants as drug dealers and rapists and urged other Republicans to speak out against him as well.

After Mr. Trump disparaged the war record of Mr. Graham’s close friend, Senator John McCain of Arizona, because Mr. McCain was a prisoner of war in Vietnam, Mr. Graham called Mr. Trump “a jackass.”

Speaking in Mr. Graham’s home state on Tuesday, in Bluffton, S.C., Mr. Trump responded in kind, calling the senator an “idiot,” before taking a white index card from his pocket with the phone number scrawled in black ink. He said that Mr. Graham had eagerly given him the number a few years ago.

Christian Ferry, Mr. Graham’s campaign manager, said that Mr. Trump “continues to show hourly that he is ill-prepared to be commander in chief.”

Throughout his speech, Mr. Trump denounced Mr. Graham and former Gov. Rick Perry of Texas, another Republican contender who has been critical of Mr. Trump.

And he continued to criticize Mr. McCain for dismissing people who attended a Trump rally in Arizona as “crazies.”

“I know crazies. I know crazies,” Mr. Trump said, the implication being that his followers did not meet the definition of the term.