The JBL PlaCollect is a simple planaria (flatworm) trap that doesn’t use chemicals. The simple device is basically a plastic tube with a cap and stopper that has a smaller tube to draw the flatworms in with some bait. Sure, you could probably DIY something like this, but for a few bucks, you get all that you need.
The kit comes with the trap along with bait (JBL NovoTab), suction cup to secure it to the inside of the glass and a mono filament line to make pulling it out a bit easier. Just put in the stopper, pop in the NovoTab, screw on the lid, and attach the line. Then you dip the whole thing under water, unscrewing the cap to fill with water and let sink, stick the suction cup to the glass when its in the position you want, hang the string outside the tank and then just wait.
The JBL PlaCollect retails for around $12 USD. Here is a simple video from an online store (Aquaplantsonline) show how to put it together and use.