Changeset 3701:16d6d099e144 for admin/popup_link.php
- Timestamp:
- 02/15/18 13:03:37 (8 years ago)
- Branch:
- default
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
admin/popup_link.php
r3639 r3701 11 11 # -- END LICENSE BLOCK ----------------------------------------- 12 12 13 require dirname(__FILE__) .'/../inc/admin/prepend.php';13 require dirname(__FILE__) . '/../inc/admin/prepend.php'; 14 14 15 15 dcPage::check('usage,contentadmin'); 16 16 17 $href = !empty($_GET['href']) ? $_GET['href'] : '';18 $hreflang = !empty($_GET['hreflang']) ? $_GET['hreflang'] : '';19 $title = !empty($_GET['title']) ? $_GET['title'] : '';17 $href = !empty($_GET['href']) ? $_GET['href'] : ''; 18 $hreflang = !empty($_GET['hreflang']) ? $_GET['hreflang'] : ''; 19 $title = !empty($_GET['title']) ? $_GET['title'] : ''; 20 20 $plugin_id = !empty($_GET['plugin_id']) ? html::sanitizeURL($_GET['plugin_id']) : ''; 21 21 22 dcPage::openPopup(__('Add a link'), $core->callBehavior('adminPopupLink', $plugin_id));22 dcPage::openPopup(__('Add a link'), dcPage::jsLoad('js/_popup_link.js') . $core->callBehavior('adminPopupLink', $plugin_id)); 23 23 24 echo '<h2 class="page-title">' .__('Add a link').'</h2>';24 echo '<h2 class="page-title">' . __('Add a link') . '</h2>'; 25 25 26 26 # Languages combo 27 $rs = $core->blog->getLangs(array('order'=>'asc'));28 $lang_combo = dcAdminCombos::getLangsCombo($rs, true);27 $rs = $core->blog->getLangs(array('order' => 'asc')); 28 $lang_combo = dcAdminCombos::getLangsCombo($rs, true); 29 29 30 30 echo 31 '<form id="link-insert-form" action="#" method="get">' .32 '<p><label class="required" for="href"><abbr title="' .__('Required field').'">*</abbr> '.__('Link URL:').'</label> '.33 form::field('href', 35,512,html::escapeHTML($href),'','',false,'required placeholder="'.__('URL').'"').'</p>'.34 '<p><label for="title">' .__('Link title:').'</label> '.35 form::field('title', 35,512,html::escapeHTML($title)).'</p>'.36 '<p><label for="hreflang">' .__('Link language:').'</label> '.37 form::combo('hreflang', $lang_combo,$hreflang).38 '</p>' .31 '<form id="link-insert-form" action="#" method="get">' . 32 '<p><label class="required" for="href"><abbr title="' . __('Required field') . '">*</abbr> ' . __('Link URL:') . '</label> ' . 33 form::field('href', 35, 512, html::escapeHTML($href), '', '', false, 'required placeholder="' . __('URL') . '"') . '</p>' . 34 '<p><label for="title">' . __('Link title:') . '</label> ' . 35 form::field('title', 35, 512, html::escapeHTML($title)) . '</p>' . 36 '<p><label for="hreflang">' . __('Link language:') . '</label> ' . 37 form::combo('hreflang', $lang_combo, $hreflang) . 38 '</p>' . 39 39 40 '</form>' .40 '</form>' . 41 41 42 '<p><button type="button" class="reset" id="link-insert-cancel">'.__('Cancel').'</button> - '. 43 '<button type="button" id="link-insert-ok"><strong>'.__('Insert').'</strong></button></p>'."\n". 44 45 '<script type="text/javascript">'."\n". 46 '$(\'input[name="href"]\').get(0).focus();'."\n". 47 '</script>'."\n"; 42 '<p><button type="button" class="reset" id="link-insert-cancel">' . __('Cancel') . '</button> - ' . 43 '<button type="button" id="link-insert-ok"><strong>' . __('Insert') . '</strong></button></p>' . "\n"; 48 44 49 45 dcPage::closePopup();
Note: See TracChangeset
for help on using the changeset viewer.