Ticket #890: relative_enclosures.diff
| File relative_enclosures.diff, 652 bytes (added by markjaquith, 6 years ago) |
|---|
-
wp-includes/functions.php
1025 1025 $punc = '.:?\-'; 1026 1026 $any = $ltrs . $gunk . $punc; 1027 1027 1028 // allow for relative (to the site) enclosures 1029 $content = str_replace(' href="/', ' href="http://' . $_SERVER['HTTP_HOST'] . '/', $content); 1030 $content = str_replace(" href='/", " href='http://" . $_SERVER['HTTP_HOST'] . '/', $content); 1031 1028 1032 preg_match_all("{\b http : [$any] +? (?= [$punc] * [^$any] | $)}x", $content, $post_links_temp); 1029 1033 1030 1034 debug_fwrite($log, 'Post contents:');
