Waarschuwing pop-up wanneer er een afbeelding wordt gedetecteerd in een bericht

Would it be easier to put a hook in so that when someone clicks the upload button, or drags+drops a pic that then provides the pop up?