With two weeks to go before the Democratic National Convention comes to town — along with thousands of protesters hoping to snag the media spotlight — some in Philadelphia’s legal community want activists to know that protesting isn’t just about marching with clever signs and catchy chants.

It’s knowing what to do if a cop starts patting you down: “A police officer cannot put their hands in your pockets while they’re patting you down. They can only pat you down externally … but just because they’re not supposed to do something doesn’t mean they won’t,” legal worker Amanda Spitfire said.

It’s knowing whether it’s legal for a cop to snatch your smartphone: “It’s unlawful, but it’s also common practice,” Spitfire said.

And it’s knowing how to respond if you’re a person of color: “You absolutely need to verbalize every action that you’re going to do in front of a police officer. ‘Officer, I’m going to reach for my license now with my right hand, very f---ing slowly!’” said another legal worker, who declined to be identified.

These lessons and more, imparted by a group of lawyers, legal workers, and others who support free speech rights, were part of a three-hour “Know Your Rights” training held Saturday at the Arch Street United Methodist Church, the first of several such trainings the Up Against the Law Legal Collective will give before the DNC.

Some of the 50 activists who attended left the session more uneasy than when they arrived.

“I just feel very concerned right now, like anybody is fair game, no matter what we do,” said Janet Horwitz, 51, of the city’s Spring Garden neighborhood. “I’m feeling like it’s highly likely, after this presentation, that I could be arrested.”

But organizers said the training was meant to address “worst case scenarios.”

“I’m really hoping at the end of the day the police realize the smartest thing they can do is let people protest and go home,” said Jody Dodd, a legal collective member.

The training came on the heels of a heartbreaking week that saw fury surge nationally after police gunned down Alton Sterling in Louisiana and Philando Castile in Minnesota, and an armed and angry military veteran shot 11 police officers in Dallas during a Black Lives Matter rally, leaving five dead.

Castile’s and Sterling’s deaths sparked protests nationally — including a “Weekend of Rage” here in Philadelphia in which hundreds have taken to the streets to protest police brutality.

But Dodd and other trainers said they don’t expect violence to erupt at these or any other protests, including during the DNC — unless the violence comes at the hands of those wearing uniforms and badges.

“The only violence I have ever seen was violence by police officers on the bodies of the protesters,” said Aine Fox, a legal collective trainer.

Dodd agreed: “I think what we all want is to be effective, right? And I think that the strategy of nonviolence can be a very effective strategy, especially if when you’re lifting up the dichotomy between those who are being harmed and those who are doing the harming … Violence happens when police start cracking down in riot gear, going after people, and it’s very upsetting. That’s usually what escalates the situation. If we don’t want violence, my advice to police is: Don’t be violent.”

One activist training, scheduled at the church on July 23, will be a “freedom school” that will specifically focus on the nonviolent protest tactics espoused by the Rev. Martin Luther King Jr.

Still, violence was very much on the minds of some activists, including one who wondered about the city’s recent law decriminalizing summary offenses like blocking the highway, loitering and disorderly conduct, infractions with which police could charge protesters. Under the new law, those offenses warrant just a civil citation. But what if, one activist asked, protesters want to be arrested to prove a point? Would the civil citations drive arrest-minded protesters to become violent in order to earn handcuffs?

“Oh let me assure you, you don’t need to be violent to get arrested in the city of Philadelphia,” Dodd told him, prompting knowing chuckles from the crowd, many whose protest activities have earned them trips to jail.

But it was one of few laughs during an afternoon of role-playing and warnings of all the various ways police could violate activists’ civil rights — or worse.

“Every single police officer in this country is armed with things that can kill you,” Fox told her listeners.

The legal collective has posted their training online and will run a hotline (484-758-0388) during the DNC that any protesters who get arrested can call for help. About 35 attorneys already have signed on to represent arrested protesters for free, Dodd said.