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.

General Questions

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

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

text only version ?


6 Posts   1248 Views


19 November 2009 at 12:19pm Community Member, 4 Posts

Hi there

I need to build a site that can offer a text-only / low-bandwidth version... can it be done with SilverStripe ?


Web designer Hobart


19 November 2009 at 3:28pm Community Member, 283 Posts

If you design it that way, you sure can! If you need it to be able to switch on the fly you can try the detection that has been done with Mobile:


19 November 2009 at 5:03pm Community Member, 4 Posts

I don't need the automatic detection, just the option to view the site without images, etc.

So would it be just a matter of changing templates... sorry I've never used SilverStripe


19 November 2009 at 5:05pm Community Member, 283 Posts

Yep, that would do it. You could also just use some apache .htacces kung-fu to not serve images if you wanted to take a brass tacks approach.


19 November 2009 at 8:47pm Community Member, 901 Posts

As previous posters said: It can easily be done with custom templates.
The SilverStripe WYSIWYG Editor allows insertion of images too, so you might want to replace the Editor with a TextAreaField, or just disable the Image Button using HtmlEditorConfig:

You could also output raw text in the template by using $Content.RAW (


19 November 2009 at 10:05pm Community Member, 101 Posts


Here is the code that pulls content only from the live published pages. We use it for generating printable pages. Modify it to suit your situation.

Create a new page type (maybe contentPage.php)

paste this function in the controller


public function PrintContent() {
      $content = Versioned::get_one_by_stage('SiteTree', 'Live', "SiteTree_Live.URLSegment = '".$_GET['urlSegment']."'");
      return $content->Content;


<script language="javascript">
function printContent() {"/contentprint?urlSegment=$URLSegment","mywindow","menubar=1,resizable=1,width=700,height=700,scrollbars=1");

in all templates create an href

<a href="javascript:printContent();">text version</a>

in you use


and this template can have its own CSS

hope this will help you