Skip to:
Content
Pages
Categories
Search
Top
Bottom

CKEditor – problem integrating it in BP activity post form


  • pcwriter
    Participant

    @pcwriter

    Hi all!

    I’ve been playing around with various visual editors these last few weeks, trying to get one to function properly in all the textareas of a new site I’m putting together. I finally settled on CKEditor for it’s customization options and THOROUGH documentation: http://cksource.com/ckeditor http://docs.cksource.com/

    It works flawlessly in comment/reply forms, forum topic post/reply/edit forms and a members-only front-end blog-post form using GravityForms (I suspect it would work just as well with TDO-Mini-Forms too).

    Here’s the only hiccup I can’t figure out: I can get the editor to display and all features working in the what’s-new post form as well as activity reply textareas but, any time I click “Submit”, I get the “Please enter some content to post” message.

    Has anyone gotten this to work well in the activity stream? If so, would you be kind to a now-almost-hairless gentleman by sharing your wisdom?

    Just to be clear, I’m working with the full CKEditor, not the BP plugin: http://buddypress.org/community/groups/bpckeditor/

Viewing 7 replies - 1 through 7 (of 7 total)

  • pcwriter
    Participant

    @pcwriter

    Odd… clicking the “Edit Topic” link leads to a “Page not found” error. So here’s my edit:

    EDIT – The site I’m working on is http://kwitterz.com if you want to take a look. :-)


    Boone Gorges
    Keymaster

    @boonebgorges

    I know what the problem is, but not necessarily how to solve it.

    These JS rich text editors work by hiding the HTML textarea, and hijacking the form submit process; when you submit the form, the CKeditor takes the content of its custom editor and puts it into the hidden textarea before the form is submitted for processing. The problem with the activity update form is that it’s submitted with ajax rather than with a regular HTML form submission (which requires a page load).

    TinyMCE has a method called .triggerSave() that you can call manually on an event (such as (‘#whats-new-submit’).click()) that will do this content shuffling without a regular form submit. It’s possible that CKeditor has something similar.


    pcwriter
    Participant

    @pcwriter

    @boonebgorges

    Thanks for the tip, I’ll look into their documentation to see if anything similar exists. JS is still a whole new world for me ;-)


    pcwriter
    Participant

    @pcwriter

    This exercise has proven to be beyond my knowledge and abilities at the moment.

    Consequently, I rethought the intended use of the stream on my site and realized that updates & replies in it should remain a fast-and-easy, shoot-from-the-hip, Twitter-type text-only affair, while more involved comments & replies to blog posts & forum topics should be made in their respective posts & topics.

    So I disabled activity stream commenting for blogs & forums, limited the character count in stream updates, and customized & styled the visual editors in post-form/forums/comments/replies.

    I’m happy with the result :-)


    Boone Gorges
    Keymaster

    @boonebgorges

    That’s one way to work around it :)


    technicull
    Member

    @technicull

    Has anyone already made Ckeditor work with BP-Docs? All I see mentioned is forums. I’ve asked Boone on Twitter, but even he hadn’t tried it yet. Is there anything I will need to do to make it work with BP-docs? I’d just try it, but I’m a bit gunshy, having hosed my installation twice with experiments in the past several days. Just thought I’d ask in advance for the wisdom of the crowd :)


    pcwriter
    Participant

    @pcwriter

    @technicull

    I’ve been redesigning my latest project kwitterz.com and haven’t gotten around to adding CKEditor to docs yet, but that’s on my to-do list for this week. I’ll let you know how it goes :-)

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘CKEditor – problem integrating it in BP activity post form’ is closed to new replies.
Skip to toolbar