Is Paying Upon Delivery for Online Shopping Prohibited in Islam?
Question

I want to ask about buying items on the Internet, if payment is made when the item is received, or before it is received, via bank transfer, if the item is described in words or pictures, or it is not described, in the following transactions: 1. An item that is not made of gold or silver, and is not plated with gold. 2. Gold or silver, or something that is plated with gold, whether it is silver plated with gold or any other metal that is plated with gold. 3. Rings, bracelets, watches and jewellery in general, if it is made of gold or silver, or is plated with gold. 4. Jewellery and vessels that are gold in colour, but are not gold-plated. 5. Perfumes or other items that cannot be sufficiently described in words or pictures. We hope that you will provide a detailed answer about the items mentioned above, and what a person should do if he bought any of these things in a way that means that it is not permissible for him to keep them or give them as gifts, because he was unaware of the ruling or he forgot.
Praise be to Allah.Types items bought with cash
That which is bought with cash is of two types:

A type of transaction in which it is stipulated that both the cash and the item to be exchanged must be physically present, and the exchange should occur during the same sitting in which the deal is finalised. This applies whether it is done in real life or in a sense in which it may be deemed to be real. This applies to gold, silver and currency; the exchange must be done in a real sense, by paying cash and taking the gold or currency in the same sitting.

The exchange that could be deemed to be real [i.e., take the same ruling as exchanging while being physically present] and occurring in the same sitting is: providing a certified cheque, or making an immediate deposit in the [seller’s] account, when the gold is handed over in the same sitting.
The basic principle for stipulating that this exchange should take place is based on the report narrated by Muslim (1587) from ‘Ubadah ibn As-Samit (may Allah be pleased with him), who said: The Messenger of Allah (blessings and peace of Allah be upon him) said: “Gold for gold, silver for silver, wheat for wheat, barley for barley, dates for dates, salt for salt, like for like [in quality], same for same [in quantity or weight], hand to hand. But if these commodities differ, then sell as you like, as long as it is hand to hand.”
Cash (currency) comes under the same rulings as gold and silver.
Based on that, it is not permissible to buy gold or silver by paying for it before receiving it, or after receiving it. Rather the exchange must take place in the same sitting.
With regard to that which is plated or coated with gold, it comes under the same ruling as gold if the layer of that plating is such that you could accumulate some gold if you scratched it or placed it on the fire.
However, if it is only colour from which nothing could be accumulated, or it is false gold, then it does not come under the same ruling as gold and silver; rather it is of the second type, which is discussed below.
An-Nawawi (may Allah have mercy on him) said: “If the ring is made of silver coated with gold, or the sword or other weapon, or other item, is coated with gold, if the coating is such that something could be accumulated from it if it is exposed to fire, then it is prohibited according to scholarly consensus." (Al-Majmu` 4/441).

A type of transaction which does not stipulate that the two items be physically present when selling; rather it is sufficient for one of them to be present. This ruling applies to all other goods, such as perfume, clothing, cars and land.

It is permissible for the price to be paid later when the item is physically present. This is called selling on credit.
Also, it is permissible for the price to be paid in advance, and the item to be delivered later. This is called payment in advance (Salam transaction), for which specific conditions are stipulated [for the validity of the transaction], one of which is that the item should be something that can be described in clear details.
Another type of transactions is when the price is paid in full in the sitting in which the deal is drawn up, i.e., when an agreement is made to purchase the item, and it is not permissible to delay payment until the time of delivery.
From what we have mentioned above, we learn that it is not permissible to delay both payment of the cash and delivery of the item.
It is not permissible to sell any of the items mentioned above if it is not delivered in the sitting in which the deal is drawn up and the seller does not receive the price for it.
Ibn Qudamah (may Allah have mercy on him) said: “It is not permissible [for the parties in a transaction] to part before the item has been received or before the price has been paid – which is the view of Ash-Shafi`i – because it is a transaction in which something is owed by either of the two parties. Therefore it is not permissible for them to part before receipt of one of the two things to be exchanged, as in the case of payment in advance (Salam transaction)." (Al-Mughni 3/497)
How to correct online shopping transactions 
The way to do this transaction correctly is:
[The two parties] should come to an agreement to sell an item that meets particular specifications, and to regard that as a mere promise which is not binding on either party. When the product comes to the buyer, then the transaction may be concluded, if the purchaser wishes, and he likes the item.
We have previously answered many questions about buying over the Internet , and related matters such as payment in advance , conditions which stipulate that the seller should have possession of the item [before selling it], and other similar matters . 
And Allah knows best.