php:
$imce_url = function_exists('imce_access') && imce_access() ? url('imce') : '';

return "js:
var B = eDefBrowseButton('$imce_url', 'attr_href', 'Browse', 'link');
var form = [
 {name: 'href', title: 'Link URL', suffix: B},
 {name: 'html', title: 'Link text'},
 {name: 'title', title: 'Link title'}
];
eDefTagDialog('a', form, 'Insert/edit link', 'OK');
";