|
|
|
|
@ -200,9 +200,21 @@ if (api_is_allowed_to_edit(null, true) && isset($_GET['action'])) { |
|
|
|
|
echo '<form method="post" action="'.api_get_self().'?action='.Security::remove_XSS($_GET['action']).'&urlview='.Security::remove_XSS($urlview).'">'; |
|
|
|
|
echo '<input type="hidden" name="sec_token" value="'.$token.'" />'; |
|
|
|
|
if ($_GET['action'] == 'editlink') { |
|
|
|
|
echo '<input type="hidden" name="id" value="'.intval($_GET['id']).'" />'; |
|
|
|
|
$clean_link_id = intval($_GET['id']); |
|
|
|
|
$link_info = get_link_info($_GET['id']); |
|
|
|
|
if ($link_info) { |
|
|
|
|
$urllink = $link_info['url']; |
|
|
|
|
$title = $link_info['title']; |
|
|
|
|
$description = $link_info['description']; |
|
|
|
|
$category = $link_info['category_id']; |
|
|
|
|
$onhomepage = ''; |
|
|
|
|
if ($link_info['on_homepage'] != 0) { |
|
|
|
|
$onhomepage = 'checked'; |
|
|
|
|
} |
|
|
|
|
$target_link = $link_info['target']; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
$clean_link_id = trim(Security::remove_XSS($_GET['id'])); |
|
|
|
|
echo '<input type="hidden" name="id" value="'.$clean_link_id.'" />'; |
|
|
|
|
} |
|
|
|
|
echo ' <div class="row"> |
|
|
|
|
<div class="label"> |
|
|
|
|
|