Jump to:

5539 Posts in 1738 Topics by 1224 members

Customising the CMS

SilverStripe Forums » Customising the CMS » ContentNegotiator::disable() not working?

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

Page: 1
Go to End
Author Topic: 1047 Views
  • Anatol
    Avatar
    126 Posts

    ContentNegotiator::disable() not working? Link to this post

    Hi,

    does anyone know if the ContentNegotiator doesn't work any more?

    I added the following to my _config.php :

    ContentNegotiator::disable();

    But the type remains 'application / xhtml+xml' - shouldn't this change to 'text/html'?

    I used the same code on pretty much the same page in Silverstripe 2.2.2 and the type was 'text/html'.

    Cheers!
    Anatol

  • Anatol
    Avatar
    126 Posts

    Re: ContentNegotiator::disable() not working? Link to this post

    I removed

    <?xml version="1.0" encoding="UTF-8"?>

    from the template and it worked as text/html. It's still strange that there is a difference between Silverstripe 2.2.2 and 2.3.1. My 2.2.2 version had the <?xml ... bit.

    (If you are wondering why I want to change the type: I need to use 'text/html' to be able to use the Google Maps API. It doesn't seem to work with 'application / xhtml+xml')

    Cheers!
    Anatol

    1047 Views
Page: 1
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.