Spanish photographer Manu Brabo and three other journalists detained by forces loyal to Moammar Gadhafi were released Wednesday in Tripoli, a Libyan government spokesman said on state television.

The four newly-freed journalists are Brabo, U.S. reporters James Foley and Clare Morgana Gillis and Briton Nigel Chandler, according to the Libyan spokesman.

However, South African photographer Anton Hammerl - who disappeared along with Brabo and the two Americans - has not been released.

The four journalists were put on trial on Tuesday in an administrative court in Tripoli, which declared them guilty and sentenced each of them to a year's probation and a fine of 200 dinars ($154) for illegally entering the country, according to the spokesman.

After their release, the reporters arrived at the Rixos Hotel in Tripoli, witnesses told Efe, adding that their physical appearance was good despite the fact that they clearly appeared very tired.

Manuel Varela de Seijas Brabo, known professionally as Manu Brabo, was detained on April 4 on the highway between Brega and Ajdabiya, in eastern Libya, along with Foley, Gillis and Hammerl.

The Libyan government confirmed weeks later that the journalists were being held on a charge of illegally entering the country.

On April 23, Brabo was allowed to speak by telephone with his parents, and he told them he was doing well and being held in a military prison in Tripoli, where he was visited by an envoy of the Spanish government.