  Vortex line and magnetic line representations are introduced for description
of flows in ideal hydrodynamics and MHD, respectively. For incompressible
fluids it is shown that the equations of motion for vorticity ${\bf \Omega}$
and magnetic field with the help of this transformation follow from the
variational principle. By means of this representation it is possible to
integrate the system of hydrodynamic type with the Hamiltonian ${\cal{H}}=\int
|{\bf \Omega}| d{\bf r}$. It is also demonstrated that these representations
allow to remove from the noncanonical Poisson brackets, defined on the space of
divergence-free vector fields, degeneracy connected with the vorticity
frozenness for the Euler equation and with magnetic field frozenness for ideal
MHD. For MHD a new Weber type transformation is found. It is shown how this
transformation can be obtained from the two-fluid model when electrons and ions
can be considered as two independent fluids. The Weber type transformation for
ideal MHD gives the whole Lagrangian vector invariant. When this invariant is
absent this transformation coincides with the Clebsch representation analog
introduced by Zakharov and Kuznetov.
