Consider $$I(y)=\int_a^b g(x)\sqrt{1+(y'(x))^2}dx$$ where $g$ is a know differentiable funtion of $x$, $y'$is also a function of $x$.
In this case, it only has one independent variable $x$, so I wonder is it the same as the case where you have several independent variables, if not, how to derive the EL equation.
If I am to trust you actually mean your statement, then the only function to vary in the extremization is y(x). In that case, with the boundary variations vanishing, the variational equation results out of the $\delta y'$ variation to be just $$ 0=\partial_x \frac{g y'}{\sqrt{1+(y')^2}}= \frac{g' y'+ g y''}{\sqrt{1+(y')^2}} - \frac{g y'' (y')^2 }{(1+(y')^2)\sqrt{1+(y')^2}} \\ = \frac{g' y' }{\sqrt{1+(y')^2}} + \frac{g y''}{(1+(y')^2)\sqrt{1+(y')^2}} ~~. $$
Now you do realize the solution for y' in terms of g reverses these two very steps! $$ \frac{ y'}{\sqrt{1+(y')^2}}= c/g(x) ~ . $$