Image copyright EPA Image caption Some religious groups view Valentine's Day as promoting indecency

A court in Pakistan has banned public celebrations of Valentine's Day in the capital, Islamabad, on the grounds that it is not part of Muslim culture.

The Islamabad High Court's order prohibits all Valentine's Day festivities in government offices and public spaces with immediate effect.

It also directs the media not to promote or cover Valentine's events.

The orders were a response to a private petition which argued that Valentine's Day was contrary to Islamic teaching.

According to the Dawn newspaper, the petition argued that the festival promoted immorality, nudity and indecency under the cover of spreading love.

Valentine's Day has grown in popularity in many cities in Pakistan over the past decade, but some religious groups have denounced it as decadent.

The ban does not affect shops and restaurants, but it is the first time such a ruling has been imposed in the capital.

Countries out of love with Valentine's Day

It comes a year after Pakistan's President Mamnoon Hussain said Valentine's Day should be avoided, calling it a Western tradition that was not part of Pakistan's culture.

There have been other localised measures. Last year local officials in Kohat, in north-west Pakistan, banned the sale of Valentine cards and goods, and Peshawar local council banned celebrations.

However, officials in both places later said the bans had been discarded or ignored for being unpopular.

Image copyright AFP Image caption Valentine's Day is popular in big cities in Pakistan

Love or obscenity? - Analysis by Haroon Rashid, BBC Urdu

This is not the first time that Valentine's Day has made the news in Pakistan for the wrong reasons. Last year it was vigilantes burning Valentine cards, but now for the first time a court has barred it. Many believe this shows the reluctance of religiously conservative parts of Pakistani society to assimilate international events or ideas.

Many religious hardliners believe Valentine's Day is a foreign idea with no roots in Pakistan. They argue that it is is essentially a Christian festival. Last year one conservative newspaper ran an advertisement which described it as "a festival of obscenity". They fear in the future they will also be celebrating Diwali, Christmas and who knows what else.

Also creating concern among ordinary Pakistanis is the fact that it is the commercial entities that are out promoting these days to make them spend their hard-earned money. Online stores and restaurants offer special deals, while prices of flowers, especially red roses, soar on the day.

But the real problem is probably the narrow definition of the Valentine's Day message. It is not seen as promoting love, but perceived in a more sexual way.

How the ban is implemented depends on how the government and, especially, the police interpret it. If they think it means going after shops selling Valentine's Day items, it could mean a ban on them too. But so far we have seen no such action.