I am using Theme Check to test my theme and I keep getting following error:
WARNING: Both DOS and UNIX style line endings were found in the file style.css. This causes a problem with SVN repositories and must be corrected before the theme can be accepted. Please change the file to use only one style of line endings.
Below is what I have tried to get this fixed:
I am using Notepad++ it has an option under Edit->EOL Conversion->UNIX/OSX Format, I have converted the file with that, it clearly says in the Status bar that it is UNIX.
I tried Editepad Lite 7 and tried to convert it to Unix.
I fixed only CSS prettifies to fix all the extra spacing (maybe there were any)
I even delete ALL lines of code with simple blank style.css file
but I am still getting this warning from Theme Check Plugin, I have no idea what I have to do with the file to fix this error.
Open the style.css file in Notepad++. I haven't used it in a while but there should be an option in File => EOL Conversions to choose the format you want.
Hope this helps!
Related
My template starts with <!DOCTYPE html> on the first line, but for some reason when I view source on the page that's rendered, it starts on line 2.
This isn't a big deal in HTML, but I'm trying to render some XML and I'm running into the same issue, except XML isn't forgiving like HTML and must start on the first line.
EDIT
Thank you for the comments! I am a fairly new developer and was not aware of the BOM. That being said, I use PhpStorm, and you can just right click on a folder, then click 'Remove BOM', which I have done.
After doing that I ran this terminal command I found someone post grep -rl $'\xEF\xBB\xBF' that outputs files in the directory that have the BOM character. There were a few files listed, and I've fixed them all except /vendor/doctrine/orm/lib/Doctrine/ORM/Query/TreeWalkerAdapter.php. I've tried removing the BOM with PhpStorm, and haven't had any luck, so I opened the file with VIM and ran set nobomb like I found here: How do I remove  from the beginning of a file?, but it still comes out in the listing of the grep command above.
I faced the same issue, but because I closed my PHP file with "?>" and added some blank lines after. After removing the "?>", problem has been solved.
In this case nothing related to BOM directly (I was in UTF-8).
If this can help other people who find this post with the same issue than me.
See post : php: empty line from nowhere
When I open my website link ,I found errors.The error is:
"Cannot modify header information - headers already sent by (output started at ...../wp-includes/pomo/entry.php:2) in /...../wp-includes/pomo/pomo.php(1) : eval()'d code on line 1".
And I cannot log in my website admin that shows plugabble.php errors.
How can I do that?
You need to troubleshoot whats going on...
Check plugin compatibility issues, deactivate plugind and see if it works
Another problem might be that you have gotten some text or whitespace [spaces or newline] before the opening PHP tag or after the closing PHP tag in your theme's functions.php file. There can't be a single character before or after those tags, check that...
Remove white spaces from other files, on wp-congig.php maybe...
Do your research on wordpress forums, the below link might help
https://wordpress.org/support/topic/cannot-modify-header-information-headers-already-sent-4
Its white space error or space in < ? ? > <? php etc.
so check again. also as per your notice check includes/pomo/entry.php:2 this file and see line no 2.
if there is extra space etc then remove it.
ALso if it will not solve then open function.php file of theme and remove space in bottom of the page.
or last step is remove space from wp-config file.
I have installed Brackets with Tern Intelligence.
Inside my file Main.js, I type the following thing
Math.
And press ctrl-enter. I imagine I should see pow,max,etc, show up. What am I missing?
Code hints should appear automatically - no need to press anything. (If you do want to trigger them manually though, it's Ctrl-Space, not Ctrl-Enter).
What's in the rest of your Main.js file? If you make a new, blank JS file does it work? When I type Math. in an empty .js file, I see a list of code hints both while I'm typing Math and the appropriate list of options after typing the .
Also, try using Debug > Reload Without Extensions to make sure you don't have an extension installed that could be causing a problem.
As the title, i can't find the way to make alignment plugin available with .less file. It's just work on CSS File
I haven't tested this yet, but I have a pretty strong hunch that it might help your case.
Open sublime text, and go to Preferences>Browse Packages
Look for the Alignment plugin folder and enter in it.
Look at the files in there, you will see:
Base File.sublime-settings
CSS.sublime-settings
Javascript.sublime-settings
JSON.sublime-settings
Try your hand at creating a LESS.sublime-settings file in there, copying the contents of another of the settings files, for example, the JSON.sublime-settings contains this:
{ "alignment_chars": ["=", ":"] }
It seems to me, that to enable alignment to work as expected with other filetypes not designed as default with the plugin, one would have to add this settings file to the plugin in order for it to work out.
I am not sure if the file name has to be case sensitive towards the syntax you want align to work with. If you installed the less package, you should see "LESS" shows up in the list as all caps, this is why my guess is to name the file LESS.sublime-settings. You can try different naming if it doesn't go at first...
Open any LESS file in Sublime Text.
Navigate to:
- Preferences
-- Package Settings
--- Alignment
---- Settings-Syntax Specific-User
Alternatively, if you're on a Mac hit Command+Shift+P and start typing 'Alignment' and the option will appear. Once clicked, an empty JSON file will be generated for you: LESS.sublime-settings
As EffectiX mentioned, just type in { "alignment_chars": [":"] } or whatever you want to align on. Save the file. This will work with pretty much any file format if configured correctly.
A simple usability question. So I got a Dreamweaver 8 (I'm kinda used to it by now) and I've just downloaded Notepad++. (Before that I used simple Notepad) What I like about these editors is that the PHP code appears in different colors. So if the colors are not right then you immediately know that you're doing something wrong.
But this works for only the files that end with .php
But Drupal's files end with .module and .inc etc... and it's often a nightmare to look for some comma or a single-quote that's messing up your code. So how can I make Dreamweaver or Notepad++ to show me the code in .module and .inc files in colors?
in notepad++:
Settings > Style Configurator...
Find PHP in the Language listing select it then add your desired extensions in the "User Ext :" field
leave the dot off and separate them with a space. you'll need to reopen the document after you save the change.
I created a Drupal 'user language' for Notepad++ so you can get autocomplete and sytax highlighting:
Here is how to install in the last post here:
https://drupal.org/node/326803
Enable clickable links : Settings**->Preferences->Misc->**Enable clickable link
Enable PHP Syntax Highlighting for .module files, .inc files and .install files by clicking Settings**->Style Configurator-> Click on the php extension in the left sidebar and copy and paste "module inc install" into the user ext box without the quotes of course and Save and close. Voila!