Hi all,
I've been experiencing this weird issue with Modx on a particular site i am working on where the output of HTML pushed to the client under certain situations contains 'extra' breaklines (not
) which push certain parts of the content down breaking the visual style of the front-end.
The site is using the YAMS multilingual plugin for Modx evo.
I have identified that this only happens in a very specific circumstance which is the following:
When a snippet calls another snippet (nested snippets) an extra 'invisible' breakline is added along with the output which causes the content below it to be pushed down as if there was an empty paragraph in place.
Weirdly enough this only happens when the site is pushing Portuguese content (the issue does not occur under English, Spanish or Greek).
When viewing the HTML source in the browser the extra line is not visible in any way, only by using the browser dev toolkit can you see that there is this extra phantom line. (attached is a screen shot).
I have already tried striping all occurrences of "\r","\n","\t" from the output via a plugin, which although leaves the site with a nice minified html source does not solve the issue.
Any ideas of why this might be happening and how i can get rid of it?
-
☆ A M B ☆
- 24,524 Posts
\r, \n, \t don't show up on the browser in any case. The only thing that can make spaces or lines in a browser are br tags or styling for elements adding padding or margins. Without seeing the HTML source of the page in question, it's impossible to guess what might be causing the extra spacing.