The nonlinear Schrödinger equation is studied for a periodic sequence of delta-potentials (a delta-comb) or narrow Gaussian potentials. For the delta-comb the time-independent nonlinear Schrödinger equation can be solved analytically in terms of Jacobi elliptic functions and thus provides useful insight into the features of nonlinear stationary states of periodic potentials. Phenomena well-known from classical chaos are found, such as a bifurcation of periodic stationary states and a transition to spatial chaos. The relation to new features of nonlinear Bloch bands, such as looped and period doubled bands, are analyzed in detail. An analytic expression for the critical nonlinearity for the emergence of looped bands is derived. The results for the delta-comb are generalized to a more realistic potential consisting of a periodic sequence of narrow Gaussian peaks and the dynamical stability of periodic solutions in a Gaussian comb is discussed.