They just need for the liquid to have a very high surface tension or even be slightly gelatinous (like napalm, which was developed for the same needs you have).
Then they can employ a relatively simple two-chamber mechanism, with a larger reservoir chamber where the liquid accumulates, and a smaller chamber with muscle walls and a sphincter to shoot the liquid.
Having the liquid catch fire at a small distance from the mouth protects the dragon from the fire (they simply need to shoot the liquid faster than its flame speed, and stop the jet at once without slowing it down; hence the two-chamber mechanism). The dragons might do that through electric discharges from the teeth, for example, or by quickly sparking together their fangs (they'd need to be made of, or covered with, some suitable substance, like flintstone).
To attack, the dragon opens the sphincter between the fuel reservoir and the shooting chamber, enlarging the latter. The depression pumps the fuel out of the reservoir. Then the sphincter serrates and the muscles begin to tighten, greatly increasing the pressure in the shooting chamber. The release sphincter at the opposite end opens, and a short cartilagineous duct drives the liquid outside, past the larynx and the mouth. The teeth smash together giving off sparks that ignite the jet, exactly like a flamethrower.