There is a difference of opinion as to whether gambling is permitted or forbidden in Halacha.
The Shulchan Aruch rules that it is a form of stealing and is forbidden. Sefardim, who follow the rulings of the Shulchan Aruch, may therefore not gamble even occasionally, and this includes even buying a lottery ticket. Buying a raffle ticket however, would seem to be permitted even according to this opinion. When one buys a lottery ticket, one is placing money simply to earn the chance of receiving more. Buying a raffle ticket is different, though; you are actually donating money to a worthy cause, with a side benefit being the possibility of winning a prize as well, and this may well be permitted.
The Remoh, however, disagrees with the Shulchan Aruch, and permits gambling, even on a regular basis. One who has no regular source of income other than from his gambling, however, is considered to be not a member of a civil society, and is Possul Le'eydus – invalid to serve as a witness in Halachah.
It is worth noting, however, that the Remoh himself in at least one place (O. C. 322) does not object to the ruling of the Shulchan Aruch who forbids gambling (see Mishnah Berurah, Shaar Tiyon 322:20).
Further, one should note the words of the Rambam, who writes that in this context that it is not fitting for a person to spend his days in practices other than the gaining of wisdom, necessary business affairs and other such matters of societal importance.
Note too, the words of the Rivash who refers to gambling as a "disgusting, repulsive and sordid practice that has caused many casualties," and the Talmud Yerushalmi rules that we should make no effort to annul the vow of one who vowed never to gamble again!