Minecraft wiki entry for execute, associated text: execute <origin: target> <position: x y z> <command: command>
An alternate syntax allows the command to be executed only if a specific block is detected:
execute <origin: target> <position: x y z> detect <detectPos: x y z> <block: Block> <data: int> <command: command>