If I buy 'ex-dividend' do I still get the next dividend?
No, you must own the stock on the ex-dividend date in order to qualify for the next dividend payment date.
If you buy a stock 'ex-dividend' you will not be entitled to the most recently declared dividend and will need to wait until the next payment date.