The invention provides a two-layer tablet comprising a) a rapid-disintegration layer containing a salt able to buffer gastric acidity and a mucoadhesive substance that adheres to the gastric mucosa and b) a floating layer containing a salt able to release carbon dioxide in the presence of acidity, a mucoadhesive substance, and a polymer able to form a hydrogel matrix that retains carbon dioxide after hydration with aqueous fluids. The tablet is useful in the treatment of symptoms of gastric disorders caused by excessive acid secretion and/or reduced functionality of the gastric mucopolysaccharide barrier.