This is a class exercise, but I have confusion when it comes to attacking, I made the trivial case $X=x$
$g(X)E[h(Y)|X=x]=g(X) \int_{\mathbb{R}}h(Y)f_{Y|X}(Y|X)dy=\int_{\mathbb{R}}g(X)h(Y)f_{Y|X}(Y|X)dy=$
$E[g(X)h(Y)|X=x]$
But I do not feel that even this case is fine, I'm confused, I need
$E[g(X)h(Y)|X]=g(X)E[h(Y)|X]$, any help or Hint will be grateful.
Hints: by definition of conditional expectation it is enough to prove that $EI_{X^{-1}(A)} g(X)h(Y)=EI_{X^{-1}(A)}g(X)E[h(Y)|X]$ for any Borel set $A$. [ Because the sigma algebra generated by $X$ is nothing but $\{X^{-1}(A): A \text {is Borel set in } \mathbb R\}$]. Now if $g$ is is a simple function then this equation follows immediately from definition of $E[h(Y)|X]$. The general case follows by writing $g^{+}$ and $g^{-}$ as limits of simple functions. Of course you need some assumptions on $g$ and $h$ to make sure that all the expectations are finite.