Books, cds, magazines, newspapers, and movie titles are underlined or italicized.
Titles of poems, chapter titles, songs, article names, or essays are in quotes.
The pattern tends to be that “bigger” works of literature, writing and art (a novel, a book of poems, a full-length movie) gets underlined, and “smaller” ones (an individual poem or song, a short story) get quotes.
A cheap mnemonic to remember this rule: Heavy plants go on a table, and the underline looks like a tabletop. Lighter plants can hang on hooks, like the quotation marks floating above the title.