• Running the latest version of WordPress, and this has occurred with different themes from different places. I use Fetch as my FTP file manager.

    Often, when opening a stylesheet or other sheet, I see multiple spaces in between the lines. My entire stylesheet looks like this:

    /*
    
    Theme Name: Origin
    
    Theme URI: https://www.elegantthemes.com/gallery/
    
    Version: 2.4.4
    
    Description: 2 Column theme from Elegant Themes
    
    Author: Elegant Themes
    
    Author URI: https://www.elegantthemes.com
    
    */

    (Hoping that shows the spaces in the code example added). One client’s site yesterday contained about 100-150 spaces between each line of code. I’m going to assume that’s one reason why their site loads slow.

    What is doing this? And how can I help prevent this from happening again? The client site recently mentioned is only about 300 lines of CSS.

    **Editing to announce more tools, could the problem be that I’m using: HostGator? Sublime Text Edit 2? Fetch FTP?? **This occurs also, when either viewing from WordPress side, or from FTP.

Viewing 2 replies - 1 through 2 (of 2 total)
  • When you edit & save any of these files in your text editor, are you making sure that you save them in UNIX format? I know, from previous experience, that saving such files in PC format can create the spacing issues you describe.

    Thread Starter rubydrag0n

    (@rubydrag0n)

    Thanks for your reply, Esmi. I’ll be honest, I’m not sure how to go about saving the files in UNIX format; I’m lost when it comes to the terms, I’ve just been editing the WordPress files as they’ve been packaged as themes. When I check the Line Endings in Sublime, the files do say: [Sublime >> View >> Line Endings >>] UNIX. Is that what I want to be checking for? Thanks!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Lines Between Code, Every Time I Open CSS or PHP Files’ is closed to new replies.