Jump to:

791 Posts in 369 Topics by 303 members

Widgets

SilverStripe Forums » Widgets » HTMLTextField in Widget

Discuss SilverStripe Widgets.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1 2
Go to End
Author Topic: 4255 Views
  • swaiba
    Avatar
    Forum Moderator
    1769 Posts

    Re: HTMLTextField in Widget Link to this post

    I just read that (btw the link isn't correctly linking in your article) but it wasn't clear to me whether you have used that code and "hacked the core" - did you hack the core?

    Also how are the other functions that are added to TinyMCE handled - for instance inserting a link to another ss page?

    btw I am intrested in this, but without hacking the core and providing all TinyMCE functions, until then I'll stick to bbcode only and a text edit

  • CHD
    Avatar
    Community Member
    217 Posts

    Re: HTMLTextField in Widget Link to this post

    Sorry hadn't quite finished with the article!
    check it now...hopefully it's clearer

    http://www.clickheredigital.co.uk/blog/bad-widget-class-name-given-our-experience-with-widgets-on-any-silverstripe-page/

  • swaiba
    Avatar
    Forum Moderator
    1769 Posts

    Re: HTMLTextField in Widget Link to this post

    sorry to be a pain but the link in the article "http://groups.google.com/group/silverstripe-dev/msg/1a3b1292c4f46117" still links to "http:"
    and the article is advising a replacing a core class yes?

  • CHD
    Avatar
    Community Member
    217 Posts

    Re: HTMLTextField in Widget Link to this post

    oh that link! fixed. thanks for pointing it out.

    no we ONLY used the "widgets_content" folder from his link of attachments at the bottom of the page. We didn't make ANY core changes. Or changes to WidgetEditorArea.js.

  • swaiba
    Avatar
    Forum Moderator
    1769 Posts

    Re: HTMLTextField in Widget Link to this post

    hmmm, no core change great! and it handles things link inserting a link the same way tinyMCE in the "normal" use does?

  • CHD
    Avatar
    Community Member
    217 Posts

    Re: HTMLTextField in Widget Link to this post

    yep!

    The ONLY draw back is that you still need to save the page when you add a content widget before the TinyMCE applet will load.
    But links, images, internal links etc all work fine.

  • Digital-Punk.co.uk
    Avatar
    Community Member
    51 Posts

    Re: HTMLTextField in Widget Link to this post

    To CHD:

    I try to implement your plugin, but it seems that .js file is missing in archive. In the ContentWidget.php you have requirement:

    Requirements::javascript('widgets_content/ContentWidget.js');

    And there is no such file in this folder. Could you check this please? Thanks!

  • CHD
    Avatar
    Community Member
    217 Posts

    Re: HTMLTextField in Widget Link to this post

    You're right!
    That's odd. Doesn't look like it matters, I just commented it out and all still works fine.
    I'll update my .zip files now.

    (in case you haven't noticed, this isn't my strong point, so the code may not be great! But it works, so I wanted to share anyway, I'm sure the pros here can clean up these widget packs for general public use!)

    4255 Views
Page: 1 2
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.