#2393: Links to database pages
--------------------------+-------------------------------------------------
Reporter: MikeVrind | Owner:
Type: New Feature | Status: new
Priority: Normal | Milestone: FCKeditor 2.6.3
Component: UI : Dialogs | Version: FCKeditor 2.6.2
Keywords: links |
--------------------------+-------------------------------------------------
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.
--
Ticket URL: <http://dev.fckeditor.net/ticket/2393>
FCKeditor <http://www.fckeditor.net/>
The text editor for Internet
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
FCKeditor-Trac mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fckeditor-trac