CMS MADE SIMPLE FORGE

CMS Made Simple Core

 

[#5350] Removing empty lines from HTML code (index.php) file

avatar
Created By: Hristo Zlatarski (cms_man)
Date Submitted: Fri Aug 27 01:43:05 -0400 2010

Assigned To:
Version: 1.8.2
CMSMS Version: None
Severity: Minor
Resolution: Won't Fix
State: Closed
Summary:
Removing empty lines from HTML code (index.php) file
Detailed Description:
When the actual html is printed there are some empty lines printed as well.  The
empty lines affect the rendering and the SEO as well.

Please add the following line to index.php file  at line 268

$html = preg_replace("/(^[\r\n]*|[\r\n]+)[\s\t]*[\r\n]+/", "\n", $html);
echo $html;


History

Comments
avatar
Date: 2010-12-17 23:05
Posted By: Robert Campbell (calguy1000)

This is not present in CMSMS itself.  It's probably related to the handling of
some module that's handling one of the events that can alter the template.

I would check your modules, and or UDT's and the event manager to see what is
handling certain events, and disable them one by one to isolate the problem.
      
avatar
Date: 2011-01-07 15:00
Posted By: Ronny Krijt (ronnyk)

Can be fixed wiht a UDT with ContentPostRender. 
      
avatar
Date: 2011-01-07 15:01
Posted By: Ted Kulp (wishy)

See
http://forum.cmsmadesimple.org/viewtopic.php?f=7&t=37604&p=178307&hilit=contentpostrender+blank+lines#p178307
for some solutions.
      
Updates

Updated: 2011-01-07 15:00
resolution_id: 11 => 8
state: Open => Closed

Updated: 2010-12-17 23:05
resolution_id: => 11