in the us, periods and commas
always go inside the quotation marks... no exceptions... but question marks and exclamation marks can go inside or outside, as warranted... such as in:
"Did he say, 'It's okay with me,'?" Danny asked.
and the weird-looking, but correct:
"Did he say, 'Are you kidding?'?" asked Danny, with a wink.
or:
The professor asked the class, "If, as Santayana wrote, 'Those who forget history are condemned to repeat it,' then dare we ignore the lessons of the past?"
note that single quotes must be used for a quote within a quote... in the uk, it's reversed... singles are used for the quotes, and doubles for quotes within...
also, in the uk, periods and commas go outside the " "... what would you expect from a place where they drive on the wrong side of the road?
are you all sufficiently confused yet?
hugs, m