Hi,
i making an webapp for my uni project that send an POST request using AJAX to the server and server returns an wav file in return... i want to know how do i get the name of the returned file (using javascript) and also when the file is returned IE automatically start downloading the file which i dont want....

any suggestions?

Hi,
i making an webapp for my uni project that send an POST request using AJAX to the server and server returns an wav file in return... i want to know how do i get the name of the returned file (using javascript) and also when the file is returned IE automatically start downloading the file which i dont want....

any suggestions?

Usually, if it is a regular download, then the filename is in the Content-Disposition header.

However, it really depends on how you structure your HTTP Response. You can easily send the filename as a header, or in the content etc.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.