I have been trying to generate and output a plist file to the user on demand. When the user clicks a button, I run the code below:
<?php
header('Content-Description: File Transfer');
header('Content-Type: application/xml');
header('Content-Disposition: filename="Settings.plist"');
echo '<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>key</key>
<string>value</string>
</dict>
</plist>';
?>
Here is the output:
What do I need to do to get the file download to initiate?