How to create a function in javascript that generates an .ini file?
For example, I will fill 2 fields and it will generate a file like this
[teste]
nome: "campo 1 que vou preencher"
teste: teste
teste: teste
email: "campo 2 que vou preencher"
teste: teste
teste:
That's it, then the person clicks Save or Download and downloads the file I'm trying to use FileSaver, but I'm having trouble even running the demo of it.
I tried it in a similar way, more or less like this
$('#salvar').click(function() {
var nome = $('#nome').val();
var email = $('#email').val();
this.href = "data:text/plain;charset=UTF-8," + encodeURIComponent(texto);
});