Be nicer to people without http

git-svn-id: http://svn.automattic.com/wordpress/trunk@3040 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
matt 2005-11-11 01:13:30 +00:00
parent 89bbb5bb21
commit 7c20f40c39
1 changed files with 1 additions and 1 deletions

View File

@ -396,7 +396,7 @@ function edit_link($link_id = '') {
die(__("Cheatin' uh ?"));
$_POST['link_url'] = wp_specialchars($_POST['link_url']);
//$link_url = preg_match('/^(https?|ftps?|mailto|news|gopher):/is', $link_url) ? $link_url : 'http://'.$link_url;
$_POST['link_url'] = preg_match('/^(https?|ftps?|mailto|news|gopher):/is', $_POST['link_url']) ? $_POST['link_url'] : 'http://' . $_POST['link_url'];
$_POST['link_name'] = wp_specialchars($_POST['link_name']);
$_POST['link_image'] = wp_specialchars($_POST['link_image']);
$_POST['link_rss'] = wp_specialchars($_POST['link_rss']);