Is there a tool (command-line is fine) that can convert accented characters to HTML entities in Ubuntu? Preferably recursively and without also converting html/php tags.
e.g.
from: é
to: é
or: é
|
Is there a tool (command-line is fine) that can convert accented characters to HTML entities in Ubuntu? Preferably recursively and without also converting html/php tags.
|
||||
|
|
|
Recode can convert to HTML entities:
There are a few slightly different HTML transformations available in recode; see If you want to recode a file or some files, you can use
For recursive action, use the
The above find command will only show the files. Please make sure that you have found only the right files, not any binaries and not any files in unwanted directories. It is also a good idea to make a backup or use a copy of your files, not the real files. If you have found the correct find command, append
But wait a moment, there's one big caveat: |
|||||
|
|
probably sed. Tutorial here http://www.grymoire.com/Unix/Sed.html#uh-6 for yours example, maybe command
( repair me if im wrong, havent seen sed for a while ) GUIprobably default installed gedit, ctrl+H |
|||||
|
|
Check out the source of http://www.text-symbols.com/tools/escape-chars/ Take that javascript, execute it in a js environment that can do some IO (node.js) and just use |
|||
|
|