PORTSMOUTH, England – On the final leg of his three-day state visit to Britain, President Donald Trump joined Queen Elizabeth II and leaders from around the world in paying respects to Allied service members who 75 years ago took part in the D-Day landings that helped liberate Europe from Nazi Germany's military occupation.

The Normandy landings on June 6, 1944, were the largest land, air and sea invasion in history and Portsmouth Naval Base, near where the commemorations took place Wednesday, served as a key launch pad for those forces.

In an address, the queen said that "75 years ago, hundreds of thousands of young soldiers, sailors and airmen left these shores in the cause of freedom. In a broadcast to the nation at that time, my father, King George VI, said: 'What is demanded from us all is something more than courage and endurance; we need a revival of spirit, a new unconquerable resolve.' That is exactly what those brave men brought to the battle, as the fate of the world depended on their success."

Earlier, in a special message to mark the occasion, the queen said: "At this time of reflection for veterans of the conflict and their families, I am sure that these commemorations will provide an opportunity to honor those who made extraordinary sacrifices to secure freedom in Europe. They must never be forgotten."

The event featured a number of British and American veterans of the invasion. Their chests bore ribbons and medals and a few of them clutched canes. The story of the build-up to the battle was told through live music, performances and readings.

"We must never forget," said D-Day veteran John Jenkins, 99, addressing a crowd of more than a thousand seated in folding chairs before an amphitheater-type stage. About 300 World War II veterans attended the ceremony on England's south coast.

Trump read a prayer that President Franklin Roosevelt delivered in a radio address on June 6, 1944, as U.S. and allied forces were crossing the English Channel to land on the beaches of Normandy, France. "Almighty God, our sons, pride of our nation, this day, have set upon a mighty endeavor, a struggle to preserve our republic, our religion and our civilization and to set free a suffering humanity," Trump read.

World War II D-Day:5 to know on the 75th anniversary of Normandy landings

Several hours before the event, Trump launched into a Wednesday morning tweet storm, criticizing the "Corrupt Media," praising his "warm" treatment by Britain's royal family and offering condolences to Israel President Reuven Rivlin on the death of his wife Nechama Rivlin. He also unleashed attacks on Senate Minority Leader Chuck Schumer, former Vice President Joe Biden and even actress and singer Bette Midler.

In a news conference on Tuesday with May, Trump said he was grateful for the warm welcome he has received from the royal family and the prime minister during his visit to Britain. "The bonds of friendship forged here and sealed in blood on those hallowed beaches will endure forever," Trump said at the news conference.

He said the D-Day landings "may have been the greatest battle ever in history."

Colin King, 73, who served in the British Navy and was manning a pop-up booth in Portsmouth for the Royal Navy Association, a support group for ex-service members, said Trump "had done quite well" on his trip to Britain and as far as he was concerned the "special relationship" between the U.S. and Britain had "never been better."

"I haven't seen too many people complaining about his tweets," he said.

Before and after:Photos reveal dramatic changes since D-Day

Ahead of the commemorations, the countries taking part issued a joint statement pledging to make sure the "unimaginable horror" of World War II did not happen again.

Later Wednesday, Trump will make his first visit as president to Ireland, where he will hold meetings with Irish Prime Minister Leo Varadkar at Shannon Airport, before spending the night at the Trump golf club in Doonbeg. He will then travel to France for further D-Day commemorations focused on honoring Americans killed in the fighting.

75th D-Day anniversary:The Pieper twins are finally together in Normandy

Prior to the ceremonies Trump also took part in a broadcast interview with "Good Morning Britain," telling host Piers Morgan that he meant no harm when he used the term "nasty" in discussing the American-born Duchess of Sussex, Meghan Markle. The phrase generated a lot of media coverage and Trump sought to clarify that he was speaking specifically on her comments about him, not about her.

"She was nasty to me. And that’s okay for her to be nasty, it’s not good for me to be nasty to her and I wasn’t," Trump said in the interview, which he also used to play down an earlier comment that any trade deal between the U.S. and Britain after the latter leaves the European Union could involve Britain's National Health Service, a prospect that has alarmed many Britons and politicians.

In the interview, Trump was also asked about avoiding serving in the Vietnam War.

"Well I was never a fan of that war I’ll be honest with you," he said. "I thought it was a terrible war, I thought it was very far away, nobody ever… you know you’re talking about Vietnam and at that time, nobody had ever heard of the country."

Back in Portsmouth, Laurence Wood, 76, who fought for the British army in Borneo in a conflict against Indonesia in the 1960s, was sitting down on a patch of grass taking it all in. Wood said his mother was a "British GI bride" – in other words, his father was an American soldier stationed in Britain during World War II, part of what historians sometimes refer to as the "friendly invasion" of Britain during the Nazi era.

After the war, Wood lived with his parents in New York City, but they separated, he moved back to Britain with his mother, and last saw his dad when he was four-years-old. He has lost all touch with his American side of the family, he said.

He also said Trump's visit had caused him to change his mind about the president.

"Until he came here, I never liked him," he said. "But he's behaved himself in front of our queen and the royal family and I have appreciated that."