﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
2393	Links to database pages	MikeVrind		"Hello,

It should be easier to create a own list of links in the link dialog.
At this moment i'm using some PHP code to create a list of internal links:


{{{

			function fillURL(internPage)
			{
				document.getElementById('txtUrl').value = internPage;
				
				document.getElementById('optionHTTP').selected = false;
				document.getElementById('optionOTHER').selected = true;
			}

PHP:
			<select id=""cmbLinkType"" onChange=""SetLinkType(this.options[this.selectedIndex].value);"">
				<option value=""url"" fckLang=""DlgLnkTypeURL"" selected=""selected"">URL</option>
				<option value=""anchor"" fckLang=""DlgLnkTypeAnchor"">Anchor in this page</option>
				<option value=""email"" fckLang=""DlgLnkTypeEMail"">E-Mail</option>
					<?php
						
						$pageCats = mysql_query(""SELECT * FROM pagina_categorie ORDER by categorie_id ASC"") or die ( mysql_error() );
						
						while ( $getCat = mysql_fetch_assoc ( $pageCats ) )
						{
						
							echo '<optgroup label=""'.stripslashes($getCat['categorie_naam']).'"">';
							
							$pages = mysql_query(""SELECT pagina_id, pagina_titel FROM paginas WHERE pagina_categorie="".$getCat['categorie_id']."" ORDER BY pagina_titel ASC"") or die ( mysql_error() );
							
							while ( $Get = mysql_fetch_assoc ( $pages ) )
							{
								echo '<option value=""url"" onclick=""fillURL(\'cardan/index/'.$Get['pagina_id'].'/'.stripslashes($Get['pagina_titel']).'\');""> '.stripslashes($Get['pagina_titel']).' </option>';
							}
							
							echo '</optgroup>';
						
						}
						
					?>
			</select>

}}}

This only doesn't work in IE7, but when I change the function SetLinkType to check the value of a selected item, de link dialog doesn't work anymore.
FireBug reports the following error:

''A is undefined
FCK.Description=""FCKeditor for Gecko Bro...tem(i);E.href=A;B.push(E);}};return B;};'' 

So there should be a option in FCK that makes it easer to create own links in de option dialog."	New Feature	closed	Normal		UI : Dialogs	FCKeditor 2.6.2	duplicate		
