Cities from Amsterdam to Sydney are banning fossil fuel advertisements, drawing from tactics once used to curb smoking.