Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

FCKEditor Ajax Quote

I've put together an extension for adding quotes using AJAX fetching and the FCK Editor interface. It'll be uploaded shortly.

Based the work on AjaxQuote, obviously :D

FCKAjaxQuote

Comments

  • Cool stuff, but there seems to be a conflict with the Permalink extension. For some reason, having both activated causes the quote link to point to the discussion's page. The "quote" and "permalink" links were also stuck one against the other without space between them.
  • I'll have to get the other extension and try it.
  • I dont have the Permalink extension but it also points to the discussion's page. regards.
  • Did this get sorted?
  • xurxur
    edited January 2007
    I also am having a problem with quoting across multiple pages.. Specific error is: FCKeditorAPI is not defined fckajaxquote.js (line 11) fck_ajax_qoute fckajaxquote.js (line 11) Line 11: var oEditor = FCKeditorAPI.GetInstance('Body') ; Anyone have any ideas?
  • same problem like bugme :/
  • I have the same problem too, would really like it resolved since this is very useful
  • edited October 2008
    I don't have the same problem as bugme, but I found a fix for the quote and permalink links being stuck together. In the default.php, line 15, add a space to either side of

    $Context->Dictionary['Quote'] = 'quote';

    I forget if it's a space or nbsp;, but I have an nbsp; (non breaking space) just in case:

    $Context->Dictionary['Quote'] = 'quote ';

    Edit #1: I've also been a bit experimentative with the html and css of the quote and ended up with this:

    image

    You have to edit line 41 (oEditor.InsertHtml...), with the html you want (I changed the contents of the <cite> tag, added an <hr> and the little inverted commas (gifs)). To get it to look like that, though, you have to add a line in the main css for blockquote (background-color and border). You have to add css to the html the script outputs so as to look right in the editor box, but it gets stripped, so another entry in the main css is required.

    oEditor.InsertHtml('<blockquote style="background-color: #eeeeee; border: 1px solid #9c9c9c; padding: 10px;"><cite>Quote: <b>'+g_com_author+'</b></cite><hr><img src="http://www.domain.com/quote1.gif">'+ request.responseText+'<img src="http://www.domain.com/quote2.gif" class="closing-quote"></blockquote>');

    and

    blockquote { background-color: #eeeeee; border: 1px solid #9c9c9c; padding: 10px;}

    EDIT #2: Yellow fade breaks this add-on.
  • judgejjudgej
    edited December 2008
    This button should be context-aware: if the user does not have the FCK visual editor enabled in their preferences, then the 'quote' link should not appear. At the moment it appears, but just bumps the user to the of the page ('#') when clicked.

    An alternative would be to fall back to the standard quoting feature (e.g. like the Quotations 1.6 plugin) but I think simply not displaying would be better, since this link only knows whether *it* needs to display or not - it has no idea whether there is a different visual editor enabled, which has its own quoting method.

    -- Jason

    Edit:

    I fixed this on line 11 of default.php like this:

    if( in_array($Context->SelfUrl, array("comments.php")) && $Context->Session->User->Preference('VisualEditing') ) {
    ...

    I suspect an additional check may be needed to check exactly which visual editor is in operation, but this is a start at least.
  • gilgil
    edited December 2008
    this extension is just not working for me.. i don't know, if i'm not crazy it was working yesterday. i can't understand. edit note: yellow fade is the reason of my crazyness. don't use yellow fade extension if you'd like to use quote extension.
  • @judgej: Thanks for the post, I was having some users complain about this quote feature as well and your patch resolved the issue.
  • How would I port the css from AjaxQuote to this?
Sign In or Register to comment.