We illustrate a differential oligopoly game where firms compete à la Cournot in homogeneous goods in the market phase, and invest in advertising activities aimed at increasing consumers' reservation price. Such investments produce external effects, characterizing the advertising activity as a public good. We derive the open-loop and the closed-loop Nash equilibria, and show that the properties of the equilibria depend on the curvature of the market demand function. The comparative assessment of these equilibria shows that firms' advertising efforts are larger in the open-loop than in the closed-loop equilibrium. We also show that a cartel involving all firms, setting both quantities and advertising efforts so as to maximize joint profits, may produce a steady state where social welfare is higher than the social welfare levels associated with both the non-cooperative settings.