Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

<0xEF,0xBB,0xBF> character showing up in files. How to remove them?

I am doing compressing of JavaScript files and the compressor is complaining that my files have  character in them.

How can I search for these characters and remove them?

like image 664
Quintin Par Avatar asked Sep 04 '11 07:09

Quintin Par


People also ask

What is u feff?

Name: Zero Width No-Break Space (BOM, ZWNBSP)


1 Answers

You can easily remove them using vim, here are the steps:

1) In your terminal, open the file using vim:

vim file_name 

2) Remove all BOM characters:

:set nobomb 

3) Save the file:

:wq 
like image 82
Mohammad Anini Avatar answered Sep 22 '22 23:09

Mohammad Anini