mirror of
https://github.com/WordPress/WordPress.git
synced 2025-01-22 08:11:52 +01:00
Fix for bug #0000076: http:// added to links in link-manager when needed. Also more special chars. encoding.
git-svn-id: http://svn.automattic.com/wordpress/trunk@1440 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
aa16c88414
commit
c23e83e331
@ -14,7 +14,7 @@ function category_dropdown($fieldname, $selected = 0) {
|
||||
echo " <option value=\"".$row->cat_id."\"";
|
||||
if ($row->cat_id == $selected)
|
||||
echo " selected";
|
||||
echo ">".$row->cat_id.": ".$row->cat_name;
|
||||
echo ">".$row->cat_id.": ".htmlspecialchars($row->cat_name);
|
||||
if ($row->auto_toggle == 'Y')
|
||||
echo ' (auto toggle)';
|
||||
echo "</option>\n";
|
||||
|
@ -185,6 +185,7 @@ switch ($action) {
|
||||
check_admin_referer();
|
||||
|
||||
$link_url = $_POST['linkurl'];
|
||||
$link_url = preg_match('/^(https?|ftps?|mailto|news|gopher):/is', $link_url) ? $link_url : 'http://' . $link_url;
|
||||
$link_name = $_POST['name'];
|
||||
$link_image = $_POST['image'];
|
||||
$link_target = $_POST['target'];
|
||||
@ -235,6 +236,7 @@ switch ($action) {
|
||||
|
||||
$link_id = $_POST['link_id'];
|
||||
$link_url = $_POST['linkurl'];
|
||||
$link_url = preg_match('/^(https?|ftps?|mailto|news|gopher):/is', $link_url) ? $link_url : 'http://' . $link_url;
|
||||
$link_name = $_POST['name'];
|
||||
$link_image = $_POST['image'];
|
||||
$link_target = $_POST['target'];
|
||||
|
Loading…
Reference in New Issue
Block a user