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.

Customising the CMS /

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

Can I change the width of the page in tinymce?


Go to End


2 Posts   1829 Views

Avatar
Leslie

Community Member, 6 Posts

27 March 2010 at 11:31am

Hi,

Silverstripe 2.3.6

Would it be possible to customise TinyMce in such a way that it looks more like my website? The main container on my website is 800 px wide so it would be helpfull if the page in TinyMce would be 800 pc wide as well?

Leslie

Avatar
Carbon Crayon

Community Member, 598 Posts

28 March 2010 at 10:19am

Edited: 28/03/2010 10:21am

Hi Leslie,

Adding the code below to your getCMSFields() function in Page.php should do the trick. You might need to play around with some more CSS to make it look good, but this should get you started:

		Requirements::customCSS("
			table#Form_EditForm_Content_tbl{width:800px !important;}
		"); 

note that this will only change the Content field, if you have other custom HTML editor fields then you will need to add CSS for them too.

Aram

www.ssbits.com - SilverStripe tutorials, tips and other bits