I tried to do it the following way:
Let $U\times V$ be an open set in $X\times X$. It is now to be shown that $h^{-1}(U\times V):=\{(x,y): (x,f(x,y))\in U\times V\}$. By continuity of $f$, there exists open set $U_1\times V_1\ni (x,y), f^{-1}(V)=U_1\times V_1. $ So $x\in U_1\cap U$. I conjecture that $h^{-1}(U\times V)= (U\cap U_1)\times V_1.$
Proof of the conjecture: Take any $(a,b)\in (U\cap U_1)\times V_1=f^{-1}(V)$. $f(a,b)=ab\in V\implies h(a,b)=(a,ab)\in U\times V\implies (a,b)\in h^{-1}(U\times V).$