If $0\notin B$, then you don't need $B$ to be open:
For every $b\in B$, the map $x\mapsto xb$ is a homeomorphism in $\mathbb{R}$, so $Ab$ is open. Then
$$AB = \bigcup_{b\in B}Ab,$$
so $AB$ is open.
If $0\in B$, it's a bit tricky. We need $B$ to be open. In that case, $B':= (-\varepsilon,\varepsilon)\subseteq B$ for some $\varepsilon > 0$. Then we can decompose $B = B' \cup B''$ where $B'' = B\setminus B'$. Now $AB = AB' \cup AB''$ and we know that $AB''$ is open. All we need to do is prove that $AB'$ is open.
Now $B'$ is open, so if $0\notin A$, we can use the same argument as before to prove that $AB'$ is open. Otherwise, we make a similar decomposition $A = A' \cup A''$ where $A' = (-\delta,\delta)\subseteq A$ and $A'' = A\setminus A'$. Now
$$AB = A'B' \cup A''B' \cup AB''.$$
We need to prove that $A'B' = (-\varepsilon,\varepsilon)(-\delta,\delta)$ is open. To do that, just note that $A'B' = (-\varepsilon\delta,\varepsilon\delta)$, which is open.