How is the path integral for light explained, or how does it arise? In a Phys.SE question titled How are classical optics phenomena explained in QED (Snell's law)? Marek talked about the probability amplitude for photons of a given path. He said that it was $\exp(iKL)$, and that "...this is very simplified picture but I don't want to get too technical so..." 
I want to know how it arises, even if it is technical. I find it very strange. If we compare it to the case of a particle obeying the Schrodinger equation, we have $\exp(iS/h)$ where $S$ is the action of a given path. $S$ is what we want to minimize(in the classical limit). In this case the path is a space-time path. 
But in the other case, of the photon, where $L$ is that we have to minimize(in the classical limit or if you want in the geometrical optics limit) the paths are only in space, and I can't find any temporal dependence. 
when I check any book about QED, I can read about the photon propagator (about space-time paths) but I never have found out about the expression $\exp(iKL)$.
In general terms I find hard to relate what Feynman teaches in his book with what I have read in the "formal QED books" like Sokolov, Landau, Feynman or Greiner.
 A: Ordinary massive particles have the action equal to
$$ S = -m_0\int d\tau_{\rm proper} $$
which is negative and equal to the proper time along the world line multiplied by the rest mass. However, photons classically move along time-like geodesics and all of them have a vanishing proper duration. So one couldn't say which of these "zigzag" timelike trajectories is the right one.
Snell's law needs another step to be derived. We need to assume a constant frequency of the photon. Because the frequency is specified, the velocity of the wave packet is determined by the local wave number. This reduces the selection to trajectories in space - Snell's law only addresses light's journey through static environments - because the direction of the trajectory in time is determined at each point by the known frequency. Also, the phase contributed to the path integral is simply the phase of the light
$$\exp(iKL), \quad K = 2\pi / \lambda$$
where $\lambda$ is the wavelength of the light in a given environment. If there are many environments along the path, $KL$ should be replaced by $\sum_i K_i L_i$. However, the thing we're minimizing isn't really the action, at least I don't see how to derive Snell's law directly from the principle of least action and the concepts of particles. However, if you study the action for the electromagnetic field,
$$ S = -\frac{1}{4} \int d^4x F^{\mu\nu}F_{\mu\nu} $$
then I believe that if you make the Ansatz that $F$ describes a constant-frequency electromagnetic wave of a unit intensity, the action $F^2$ could be perhaps reduced to $\sum_i K_i L_i$ simply because the same Snell's law follows from the principle of least action in electromagnetism. However, this derivation wouldn't be "straightforward". For example, the description via Snell's law knows nothing about the two transverse polarizations included in Maxwell's theory.
A: This is not meant as a comprehensive answer, but perhaps is a helpful addition to the above answers.
There is a less well-known Hamiltonian formulation of the path integral in which all classical paths through phase space are considered, not just over real space.
We have 
$ S = \int L(q,\dot{q}) dt = \int (P dq - H(P,q) dt) $.  We integrate $e^{iS/\hbar}$ over all paths $(q(t),P(t))$.  If we restrict ourselves to paths satisfying $H(P,q) = const $, then the $H dt$ term is a constant and the $P dq$ term obviously produces the $e(iKL)$ factor.  
A: Like other areas in physics the resolution of EM/light phenomena can be described at many different levels and when you try to combine the terminology or equations from different levels, you usually end up confused :)
Like Lubos implies, the simple phase-equation that relates a pathlength to a phase depends on an assumption of a wave propagating with a fixed speed and a fixed wavelength. Except for polarization, this is enough to describe the propagation of light in a classical way.
However in more general descriptions, a Lagrangian formulation is used where the concept of a wave itself doesn't really arise until the equations are extremalized. That is, if you write out the "path integral" as a sum of the $exp(iS/\hbar)$ contributions where each $$S=-\int L dx^4$$ as you've probably seen in the textbooks (Lubos example above with the EM field tensor F is the kinetic part of the EM Lagrangian), you see that you do the integral over spacetime (the L here is the Lagrangian, not the pathlength). The Lagrangian formulation is designed so that the extremal value of this corresponds to the usual wave-propagations, but you actually formally sum over any configuration of the spacetime field in question. 
Also, in a flash of confusing circularity, the photon propagator you've read about which is used to perturbatively find solutions to the above, is actually just a Green's function of the already extremalized solution of the free photon field per the above general formulation.. I wish I could dig deeper into this here but I'm just learning how these different formulations fit together myself. Suffice to say, if you want to build a completely particle-based approach from scratch, you need to postulate the shape of the propagator.
As Feynman notes in his simple QED book he makes a couple of shortcuts. Apart from leaving out polarization, after talking about the simple path-length-dependent phase in 10 chapters he then casually drops the note that this is simply an approximation and tries to explain the framework of the above in 2 pages, much to the confusion of the reader :)
A: To use a popular buzzword, I used a renormalization group to move from a scale of microscopic physics to a scale of macroscopic classical physics :)
To describe what I've actually done: I've summed over the microscopic degrees of freedom. In a full theory of a single photon particle (i.e. not QED) the particle travels through all trajectories and receives a phase proportional to their length. But as you know, under certain assumptions most of these trajectories are unimportant because they destructively interfere. So we may as well sum them up. What we will be left with is just a classical trajectory. Therefore the major contribution to the probability amplitude is the phase along classical trajectory which is precisely just $\exp(iKL)$.
This approximation certainly breaks down when $L \to 0$ because lots of quantum mechanical effects will start to mess up the picture. Not only that, we will need to take full QED and even standard model into account, as there is always a possibility that the photon will create an electron-positron pair, etc and all of these modify the phase. Nevertheless, you can again sum over all these higher-order effects to obtain an effective propagator, this is all part of renormalization. These were the technicalities I wanted to avoid.
