In many forms of media, when a person is bitten by a vampire have a look of calmness and pleasure on their face. Do vampires inject some sort of venom that causes feelings of pleasure or another explanation of this phenomenon. example
Blood loss can cause a lack of oxygen being delivered by red blood cells to the brain. If the vampire is biting the carotid artery, then blood flow to the brain would be severely impaired, resulting in the brain starting to shut down like when being suffocated or drowning, hallucinations and ecstasy may be produced from this affect.
Also, arousal to the point of climax has for centuries been called "the little death", and this may be a way of authors/writers sneaking being bitten and coming close to death as an erotic experience.
Humans are nothing but vampire feed. When a human is bitten by a vampire they finally achieve the only reason they exist. This is similar to sexual pressure as reproduction is the only other reason human cattle exists.
So our body releases endorphins to thank us for fulfilling the reason for our race and letting a vampire feed
Typically the feeling of euphoria is explained as being caused by either psychic abilities of the vampire, or through a chemical transmitted through the bite.
For example in The Dresden Files, the saliva of Red Court vampires contains a powerful narcotic that induces euphoria in the victim.
The whole concept of euphoria in the victim most likely comes from the post-Dracula view of vampires. As opposed to the monstrous Nosferatu, these new vampires are suave seductors/seductresses with a certain grace to them.
I believe that the expression of euphoria in most media that does NOT specifically explain the reasoning behind it comes from this concept of vampires, and is supposed to make you feel as though the bite is somewhat sexual (which the imagery invokes strongly)
EDIT: These Buffy fans also entertain the idea of a narcotic as an explanation. http://buffy-boards.com/threads/vampires-bite.59308/
SECOND EDIT: It could possibly come from the effects of an actual vampire bat's saliva which is known to contain anesthetic as well as other chemical compounds.