Prepared echo code for regex implementation