I barely understand embryology as it is, but here goes…
During and not long after gastrulation, (Day 16-19), epiblasts that migrate via the primitive node to form a chordal process called the notochord. This runs centrally and longitudinally, in the middle of the mesoderm, towards the cranial end of the embryo. It is crucial for the induction of neural development of the ectoderm above it. This region is called the prechordal plate (the notochord actually goes on to become the nucleus pulposus of the intervertebral discs- i.e. it defines the location of the vertebra and CNS).
Between days 18-20, the prechordal plate differentiates (through induction by the notochord) into the neural plate, which enlarges (this will become the cells of the CNS). At day 20, rapid cell proliferation at the margin of the neural plate causes development of the neural groove, running down the centre of the plate. As this continues, the neural folds develop and the neural groove deepends and eventually seals itself off to form the neural tube.
By day 24/25 the neural tube has closed cranially, and by 26-28 caudally. The cavity formed by this will eventually go on to form the ventricular system. Cells at the margins of the neural folds will becomes neural crest cells (which will become the PNS).
See also Mesodermal and Somite development