PageRenderTime 25ms CodeModel.GetById 22ms RepoModel.GetById 0ms app.codeStats 0ms

/upnp/MediaServerServiceDesc.php

https://gitlab.com/x33n/ampache
PHP | 91 lines | 88 code | 3 blank | 0 comment | 1 complexity | f65abbde3f34741ca9d98e7f62a0a036 MD5 | raw file
  1. <?php
  2. define('NO_SESSION','1');
  3. require_once '../lib/init.php';
  4. if (!AmpConfig::get('upnp_backend')) {
  5. echo "Disabled.";
  6. exit;
  7. }
  8. header ("Content-Type:text/xml");
  9. $web_path = AmpConfig::get('local_web_path');
  10. echo '<?xml version="1.0" encoding="UTF-8"?>';
  11. ?>
  12. <root xmlns="urn:schemas-upnp-org:device-1-0">
  13. <specVersion>
  14. <major>1</major>
  15. <minor>0</minor>
  16. </specVersion>
  17. <device>
  18. <deviceType>urn:schemas-upnp-org:device:MediaServer:1</deviceType>
  19. <friendlyName>Ampache</friendlyName>
  20. <manufacturer>ampache.org</manufacturer>
  21. <manufacturerURL>http://ampache.org</manufacturerURL>
  22. <modelDescription>Ampache - For the love of music</modelDescription>
  23. <modelName>Ampache</modelName>
  24. <modelNumber><?php echo AmpConfig::get('version'); ?></modelNumber>
  25. <modelURL>http://ampache.org</modelURL>
  26. <UDN>uuid:<?php echo Upnp_Api::UUIDSTR; ?></UDN>
  27. <iconList>
  28. <icon>
  29. <mimetype>image/png</mimetype>
  30. <width>32</width>
  31. <height>32</height>
  32. <depth>24</depth>
  33. <url><?php echo $web_path; ?>/upnp/images/icon32.png</url>
  34. </icon>
  35. <icon>
  36. <mimetype>image/png</mimetype>
  37. <width>48</width>
  38. <height>48</height>
  39. <depth>24</depth>
  40. <url><?php echo $web_path; ?>/upnp/images/icon48.png</url>
  41. </icon>
  42. <icon>
  43. <mimetype>image/png</mimetype>
  44. <width>120</width>
  45. <height>120</height>
  46. <depth>24</depth>
  47. <url><?php echo $web_path; ?>/upnp/images/icon120.png</url>
  48. </icon>
  49. <icon>
  50. <mimetype>image/jpeg</mimetype>
  51. <width>32</width>
  52. <height>32</height>
  53. <depth>24</depth>
  54. <url><?php echo $web_path; ?>/upnp/images/icon32.jpg</url>
  55. </icon>
  56. <icon>
  57. <mimetype>image/jpeg</mimetype>
  58. <width>48</width>
  59. <height>48</height>
  60. <depth>24</depth>
  61. <url><?php echo $web_path; ?>/upnp/images/icon48.jpg</url>
  62. </icon>
  63. <icon>
  64. <mimetype>image/jpeg</mimetype>
  65. <width>120</width>
  66. <height>120</height>
  67. <depth>24</depth>
  68. <url><?php echo $web_path; ?>/upnp/images/icon120.jpg</url>
  69. </icon>
  70. </iconList>
  71. <serviceList>
  72. <service>
  73. <serviceType>urn:schemas-upnp-org:service:ContentDirectory:1</serviceType>
  74. <serviceId>urn:upnp-org:serviceId:ContentDirectory</serviceId>
  75. <controlURL><?php echo $web_path; ?>/upnp/control-reply.php</controlURL>
  76. <eventSubURL><?php echo $web_path; ?>/upnp/event-reply.php</eventSubURL>
  77. <SCPDURL><?php echo $web_path; ?>/upnp/MediaServerContentDirectory.xml</SCPDURL>
  78. </service>
  79. <service>
  80. <serviceType>urn:schemas-upnp-org:service:ConnectionManager:1</serviceType>
  81. <serviceId>urn:upnp-org:serviceId:ConnectionManager</serviceId>
  82. <controlURL><?php echo $web_path; ?>/upnp/cm-control-reply.php</controlURL>
  83. <eventSubURL><?php echo $web_path; ?>/upnp/cm-event-reply.php</eventSubURL>
  84. <SCPDURL><?php echo $web_path; ?>/upnp/MediaServerConnectionManager.xml</SCPDURL>
  85. </service>
  86. </serviceList>
  87. </device>
  88. </root>