I think it is much easier to edit .html files directly on the SD card. You can simply plug it into your laptop and edit the files in the www directory. It saves a lot of time of uploading and debugging.
How have you tried editing the files from the terminal?
How have you tried editing the files from the terminal?
sudoshould give you root privileges.