1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How do I serve pages as something other than text/html?

Discussion in 'XenForo Development Discussions' started by Jaxel, Dec 13, 2010.

  1. Jaxel

    Jaxel Well-Known Member

    I'm using this right now:
    http://feedvalidator.org/check.cgi?url=http://www.8wayrun.com/media/rss

    Code:
    <?php
    
    class EWRmedio_ViewPublic_MediaMRSS extends XenForo_ViewPublic_Base
    {
    	public function renderXml()
    	{
    		echo $this->_params['xml']->saveXml(); exit;
    	}
    }
    The problem is that this servers the page as "text/html" instead of "application/rss+xml".

    Is there something I need to do to fix this?
     
  2. Jaxel

    Jaxel Well-Known Member

    Nevermind... figured it out... use renderRss instead of renderXml.
     

Share This Page