The gel from the DNA electrophoresis is heated or treated with chemicals to cause the double-stranded DNA to separate into single strands.
The gel is then put onto a sheet of nitrocellulose membrane and baked. This moves the DNA from the gel to the membrane, and fixates it there.
The membrane is now treated with a hybridization probe[?] - DNA with a specific sequence that pairs with the sequence you are looking for. The probe DNA is labelled so that it can be detected, usually by incorporating radioactivity or tagging the molecule with a fluorescent dye.
Result
The probe shows which of the fragments of the electrophoresis separation contains a certain DNA sequence.