Tell me how to organize the unloading of selected value values to a file, with the sequence 111 or 001. I explain:
0 this is a1
1 is b2
After I select the result of my actions in the span tag, I have practically no experience with working with files, tell me how to save the received data to a txt file for example.
function recalculate(){ $('#res').text(''); var sum = 0; $('div').each(function(){ var selectVal = $('select',this).val(); $('#res').append(selectVal); if($(this).index() < $('div').length - 1){ $('#res').append(' '); -- получаю value значения выбранных селектов, проблема в сохранении. Подскажите как реализовать } sum +=selectVal * 1; }); $('#res').append('<p>Согласовано: ' + sum + ' </p>'); return; } $('select').change(function(){ recalculate(); }); I am writing only on js or jQuery. Php in this work do not consider.
var data = 'Hello from App', and call thedownload(data, 'customFileName', 'text')methoddownload(data, 'customFileName', 'text'), you will download the file with the textHello from Appand the file name will becustomFileName- Vasily Barbashev