Title: Servers handle code differently
Last modified: August 18, 2016

---

# Servers handle code differently

 *  [earther](https://wordpress.org/support/users/earther/)
 * (@earther)
 * [20 years, 10 months ago](https://wordpress.org/support/topic/servers-handle-code-differently/)
 * I was getting a lot of non SGML errors when trying to validate a WP installation
   on a Mac server. So I did an identical installation (minus the added data) on
   a PC running RHEL and it validated perfectly.
 * You can see how the offending [] characters look in Notepad here [http://www.waterstonewildlife.org/images/SGML.jpg](http://www.waterstonewildlife.org/images/SGML.jpg)
   This is how all the WP files look when they are unzipped. When I open the files
   in my usual text editor NoteTab, the [] are not visible and the correct line 
   breaks appear.
 * [] is an approximation of the squarish binary thingies.
 * Is there a configuration change that can be adjusted on the Mac? Does it have
   to do with the charset=UTF-8 encoding? And why are those characters in the files
   in the first place?
 * The site in question [http://www.waterstonewildlife.org/journal/](http://www.waterstonewildlife.org/journal/)
   works fine now because all the offending characters were stripped but that isn’t
   an ideal solution IMO because if I ever have to replace files, the bug will return
   unless I manually strip out the [].
 * Any suggestions?

Viewing 6 replies - 1 through 6 (of 6 total)

 *  [Kafkaesqui](https://wordpress.org/support/users/kafkaesqui/)
 * (@kafkaesqui)
 * [20 years, 10 months ago](https://wordpress.org/support/topic/servers-handle-code-differently/#post-214698)
 * Those [] are UNIX line breaks (i.e. carriage returns) in the files. I’m surprised
   they cause problems on a Mac server.
 * Normally if you ftp text (including php) files in ASCII mode, it should properly
   convert line breaks to the format of the receiving system. Barring that, line
   break conversion utilities exist for the various OS’.
 *  Thread Starter [earther](https://wordpress.org/support/users/earther/)
 * (@earther)
 * [20 years, 10 months ago](https://wordpress.org/support/topic/servers-handle-code-differently/#post-214711)
 * Thanks for helping to clear things up.
 * Yes, I ftp in ASCII but the [] were not converted. Could the conversion utilities
   be used on my destop files or would it have to be run on the receiving end? Sorry
   if that’s a no-brainer question.
 * The converted files seem to work just fine with xampp – I downloaded the ones
   for the theme that I created and no prob. It’s a PITA to have to keep track of
   Mac compliant and non-compliant files though.
 * BTW, I was told that the .tar.gz files were compatible when they were unzipped
   on the Mac. Go figure . . .
 *  [Kafkaesqui](https://wordpress.org/support/users/kafkaesqui/)
 * (@kafkaesqui)
 * [20 years, 10 months ago](https://wordpress.org/support/topic/servers-handle-code-differently/#post-214718)
 * “It’s a PITA to have to keep track of Mac compliant and non-compliant files though.”
 * I was once paid to do that for hundreds of documents! Oof.
 * If I recall correctly, NoteTab has an option for document properties that allows
   saving to the different OS’ file formats. I’d look at that in your case.
 *  Thread Starter [earther](https://wordpress.org/support/users/earther/)
 * (@earther)
 * [20 years, 10 months ago](https://wordpress.org/support/topic/servers-handle-code-differently/#post-214796)
 * Thanks, Kafkaesqui. You’ve been very helpful. I just downloaded the Mac compatible
   files to replace the ones with the [] since they seem to work locally. Is there
   any reason why that’s a bad idea?
 *  [Kafkaesqui](https://wordpress.org/support/users/kafkaesqui/)
 * (@kafkaesqui)
 * [20 years, 10 months ago](https://wordpress.org/support/topic/servers-handle-code-differently/#post-215000)
 * Internet Rule #16: If it works, it’s not a bad idea.
 *  Thread Starter [earther](https://wordpress.org/support/users/earther/)
 * (@earther)
 * [20 years, 10 months ago](https://wordpress.org/support/topic/servers-handle-code-differently/#post-215153)
 * The final word on this glitch.
 * Turned out the mystery was not quite solved as of my last post so here’s a follow-
   up FYI . . .
 * After the characters were removed the files were in DOS not UNIX format. Not 
   the best solution.
 * So the Mac server admin did a little research and tweaking and upgraded his ftp
   server in the process. But the files were still doing weird – but different –
   things. He posted on a Mac list, as was told that if I upload the UNIX files 
   in binary, the line breaks should remain intact. That so goes against instinct
   but it seems to work. The UNIX line breaks remain undisturbed ftping either way
   and the validator isn’t choking anymore. Go figure . . .
 * This simplifies my life and it is much better to have UNIX instead of DOS files.

Viewing 6 replies - 1 through 6 (of 6 total)

The topic ‘Servers handle code differently’ is closed to new replies.

## Tags

 * [encoding](https://wordpress.org/support/topic-tag/encoding/)
 * [mac](https://wordpress.org/support/topic-tag/mac/)
 * [validation](https://wordpress.org/support/topic-tag/validation/)

 * In: [Fixing WordPress](https://wordpress.org/support/forum/how-to-and-troubleshooting/)
 * 6 replies
 * 2 participants
 * Last reply from: [earther](https://wordpress.org/support/users/earther/)
 * Last activity: [20 years, 10 months ago](https://wordpress.org/support/topic/servers-handle-code-differently/#post-215153)
 * Status: not resolved

## Topics

### Topics with no replies

### Non-support topics

### Resolved topics

### Unresolved topics

### All topics
