Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

We've moved the forum!

Please use forum.silverstripe.org for any new questions (announcement).
The forum archive will stick around, but will be read only.

You can also use our Slack channel or StackOverflow to ask for help.
Check out our community overview for more options to contribute.

General Questions /

General questions about getting started with SilverStripe that don't fit in any of the categories above.

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

The missing table cell


Go to End


7 Posts   1629 Views

Avatar
Landon

Community Member, 7 Posts

1 January 2010 at 9:54am

I'm not sure if this is a bug or if there is a way around this. Anyway, here is the issue that I am having...

I have a table filled with data, but if I take the data out of the cell just temporarily and then that table cell completely disappears. This is okay for someone knowing html, because they can just go into the html view and readd the <td></td> there, but someone that is not familiar with it would be lost and would have to create a completely new table from the menu.

Has anyone else experienced this problem? Any help would be greatly appreciated.

Landon

Avatar
tobych

Community Member, 97 Posts

1 January 2010 at 3:46pm

If there's nothing in the table cell, put &nbsp; in there. That's what used to be the way, anyway. Maybe there's a more modern way.

Avatar
Landon

Community Member, 7 Posts

1 January 2010 at 3:54pm

Thanks for the reply Toby, that would work for me, but no for my clients that don't know HTML. If there is nothing in the table shouldn't the CMS automatically put a &nbsp; for the less HTML-savvy?

Avatar
tobych

Community Member, 97 Posts

1 January 2010 at 6:02pm

What in SilverStripe is producing your table?

Avatar
Landon

Community Member, 7 Posts

1 January 2010 at 6:09pm

If my team creates a regular table from the Tiny MCE menu, enters data, then removes data from one cell of that table it automatically removes the <td></td> tags...

Avatar
tobych

Community Member, 97 Posts

2 January 2010 at 2:15pm

Others have the same problem:

http://tinymce.moxiecode.com/punbb/viewtopic.php?id=13634

There is a TinyMCE config change you could make that would probably solve this:

http://wiki.moxiecode.com/index.php/TinyMCE:Configuration/valid_elements

The SS Wiki shows how to change the TinyMCE config using mysite/_config.php

http://doc.silverstripe.org/doku.php?do=show&id=htmleditorconfig

This SSBits article covers it, too:

http://www.ssbits.com/customising-the-wysywig-editor-in-v2-3-2-tinymce/

I imagine you'll need to copy the valid_elements setting from cms/_config.php into your own _config.php, edit the settings (perhaps putting #td rather than -td -- I'm no expert on TinyMCE and have NOT tried any of this) and set that option yourself

There's a bug http://open.silverstripe.org/ticket/4390 in SS that means the cms/ module's config overrides your own: you can work around this as described here:

http://www.silverstripe.org/general-questions/show/268901?start=0

Hope this helps.

Toby

Avatar
Landon

Community Member, 7 Posts

5 January 2010 at 4:01am

Thanks Toby, I will start looking more into the TinyMCE part.