Example 3 If $a \neq 1, b \neq 1, a>0, b>0$, and satisfy the relation $\log _{a} 2=\log _{\frac{a}{2}} 4=\log _{b} 3$, find the values of $a$ and $b$.
Solution 1 (Converting logarithms to exponents) Let $\log _{a} 2=\log _{\frac{a}{2}} 4=\log , 3=m$, then $a^{m}=2,\left(\frac{a}{2}\right)^{m}=4$.
Thus, $2 a^{m}=\left(\frac{a}{2}\right)^{m}$, since $a^{m}>0$, we have $\frac{1}{2^{m}}=2$, which means $m=-1$, so $\log _{a} 2=$ $\log _{b} 3=-1$, solving for $a=\frac{1}{2}, b=\frac{1}{3}$.

Solution 2 (Using the change of base formula) $\log _{a} 2=\log _{\frac{a}{2}} 4, \frac{1}{\log _{2} a}=\frac{\log _{2} 4}{\log _{2} \frac{a}{2}}, \log _{2} a=-1$, further solving for the values of $a$ and $b$.