Locally a section is just a smooth function $s:U\to\mathbb{C}$. Given such a function, define $f(x, t) = \frac{s(x)}{t}$. Here $x$ stands for a point on $M$ and $t$ is a local coordinate in the fiber. Conversely, given such an $f$, define $s(x)$ to be the unique is the solution of the equation $f(x, s(x))=1$ (if doesn't exist, put $s(x)=0$).
Now observe that this construction behaves nicely under gluing.