Twenty people were killed when a gunman opened fire at a Walmart in El Paso in Texas Saturday evening, in what police said had a "nexus to a potential hate crime."

Twenty-six people were injured, some with life-threatening injuries. The shooting pitched the border city in West Texas with a population of 680,000 -- which President Donald Trump once described as an "extremely" violent city -- back into national focus.

But the suspected gunman in this mass murder, a 21-year old white male, was from Dallas, hundreds of kilometers away from the crime scene. He is believed to have posted a manifesto on an online message board before the crime. He wrote in the post to which the document was attached, "I'm probably going to die today."

CNN reported the gunman's name as Patrick Crusius, citing three sources. He is reportedly from the Dallas suburb of Allen, and Texas state lawmaker Jeff Leach tweetec that the suspect graduated from Plano Senior High School in 2017.

The document, posted days before the shooting, showed racist hatred toward immigrants and Latinos, and expressed fear that an influential Hispanic population would make Texas a Democratic stronghold. The writer said he or she had held these beliefs for years, even before Donald Trump was elected president, reports said.

Later in the day, Trump, in a tweet, called the shooting "an act of cowardice."

Gunmen posting online manifestos before committing mass murders is a new trend that started after the Christchurch mosque shootings in New Zealand that killed 49 people.

The suspect in El Paso was taken into custody without any incident, El Paso Police Sgt. Robert Gomez said.

FBI has opened a probe into the shooting. But an FBI officer said more investigation was needed before determining whether this was a hate crime.

Mexico President Andres Manuel Lopez Obrador said three Mexican nationals died in the shooting. The country's Foreign Relations Secretary Marcelo Ebrard said six Mexicans were wounded.

Reports said Saturday evening that a house in Allen was surrounded by law enforcement officials. The Associated Press reported a neighbor, Alice Baland, as saying that a retired couple lives at the home. She described them as sweet people who regularly attend church.

Shooting during busy back-to-school shopping season

There were hundreds of shoppers and 100 employees inside the Walmart when the shooting began.

The shooting started aroud 10.30 a.m. local time, and the first officer arrived at the scene in about six minutes. CNN reported that the injured were in the age range of 25 to 82.

The ages and genders of all these people injured and killed are numerous in the age groups," El Paso Police Chief Greg Allen said. "The situation, needless to say, is a horrific one."

Shoppers and employees hid inside stores after hearing of the shooter. Vanessa Saenz, told Fox News that she heard several "pops" and saw a man in a black shirt and cargo pants with a weapon shooting outside the building before entering the Walmart. Another witness told Fox News that his mother died at the scene.

El Paso police called urgently for blood donations following the shooting and the local community responded in strength, with lines wrapping around buildings, reports said.

crime scene
Representational image Getty Images/Jonathan Alcorn