The URI scheme soundpad:// can be used to add sounds from a website to Soundpad.
soundpad://sound/url/https://www.leppsoft.com/download/sound.mp3
soundpad://sound/url/https://www.leppsoft.com/download/sound/internal-sound-id/
Sample PHP web code:$filename = "你好声音.mp3"; $file = "/some/directory/on/the/server/".$filename; if (file_exists($file)) { header("Content-type: application/octet-stream"); header("Content-Length: ".filesize($file)); header("Content-Disposition: attachment; filename*=UTF-8''".rawurlencode($filename)); echo file_get_contents($file); }
Requires the header Content-Disposition to be set.
It can be simple e.g. Content-Disposition: attachment; filename=sound.mp3
or better
UTF-8: Content-Disposition: attachment; filename*=UTF-8''%E4%BD%A0%E5%A5%BD%E5%A3%B0%E9%9F%B3.mp3
Downloaded sounds are saved in the directory, that the user specified at File ▶ Preferences ▶ Recorder ▶ Save recordings in.
Possible errors are: