fork(3) download
  1. <?php
  2. $string = '[rrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmorethan80](http://n...content-available-to-author-only...s.in)';
  3. $pattern = '/\[(.{1,80}).*?\]\((.+?)\)/';
  4. $replacement = '<a href="$2">$1</a>';
  5. echo preg_replace($pattern, $replacement, $string);
  6. ?>
Success #stdin #stdout 0.01s 20520KB
stdin
Standard input is empty
stdout
<a href="http://n...content-available-to-author-only...s.in">rrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrm</a>