index.php 3.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  1. <?php
  2. /**
  3. * Livecoding.tv Badges main page.
  4. *
  5. * Intructions and other info about LCTV Badges.
  6. *
  7. * @author andtrev
  8. * @license GPLv3
  9. * @package LCTVBadges
  10. * @version 0.0.4
  11. */
  12. /** Badge svg creator. */
  13. require_once( 'lctv_badges_svg.php' );
  14. ?>
  15. <!DOCTYPE html>
  16. <html>
  17. <head>
  18. <title>Livecoding.tv Badges</title>
  19. </head>
  20. <body style="font-family:Helvetica,Arial,sans-serif;font-size:15px;font-weight:400;color:#111;">
  21. <div style="padding:20px;width:600px;margin:0 auto;">
  22. <h1 style="font-size:24px;font-weight:400;">Livecoding.tv Badges</h1>
  23. <p>
  24. usage:
  25. <br>
  26. <ul>
  27. <li>Badges are SVG images meant to be used as src for img elements.</li>
  28. </ul>
  29. <pre>&lt;img src="streamingstatus.php?channel=channelname"&gt;</pre>
  30. </p>
  31. <br><br>
  32. <h2 style="font-size:20px;font-weight:400;">Streaming Status:</h2>
  33. <p><pre>streamingstatus.php?channel=channelname</pre></p>
  34. <p>
  35. options:
  36. <br>
  37. <ul>
  38. <li><em>channel</em> (required) LCTV channel name.</li>
  39. <li><em>online</em> (optional) Button message if status is streaming.</li>
  40. <li><em>offline</em> (optional) Button message if status is not streaming.</li>
  41. <li><em>title</em> (optional) true/false to show streaming title when live, this will override the online message.</li>
  42. <li><em>link</em> (optional) true/false to automatically link to channel.</li>
  43. </ul>
  44. </p>
  45. <p>
  46. <?php echo get_badge_svg( 'livecoding.tv', 'online', '#4c1' ); ?>
  47. <br>
  48. <?php echo get_badge_svg( 'livecoding.tv', 'offline', '#e05d44' ); ?>
  49. </p>
  50. <br><br>
  51. <h2 style="font-size:20px;font-weight:400;">Live Viewers:</h2>
  52. <p><pre>liveviewers.php?channel=channelname</pre></p>
  53. <p>
  54. options:
  55. <br>
  56. <ul>
  57. <li><em>channel</em> (required) LCTV channel name.</li>
  58. <li><em>link</em> (optional) true/false to automatically link to channel.</li>
  59. </ul>
  60. </p>
  61. <p>
  62. <?php echo get_badge_svg( 'lctv viewers', '30', '#4c1' ); ?>
  63. <br>
  64. <?php echo get_badge_svg( 'lctv viewers', '0', '#e05d44' ); ?>
  65. </p>
  66. <br><br>
  67. <h2 style="font-size:20px;font-weight:400;">Number of Followers:</h2>
  68. <p><pre>numberfollowers.php?channel=channelname</pre></p>
  69. <p>
  70. options:
  71. <br>
  72. <ul>
  73. <li><em>channel</em> (required) LCTV channel name.</li>
  74. <li><em>link</em> (optional) true/false to automatically link to channel.</li>
  75. </ul>
  76. Needs an <a href="authorize.php">authorized account</a> to function.
  77. </p>
  78. <p>
  79. <?php echo get_badge_svg( 'lctv followers', '50', '#4c1' ); ?>
  80. </p>
  81. <br><br>
  82. <h2 style="font-size:20px;font-weight:400;">Last Streamed:</h2>
  83. <p><pre>laststreamed.php?channel=channelname</pre></p>
  84. <p>
  85. options:
  86. <br>
  87. <ul>
  88. <li><em>channel</em> (required) LCTV channel name.</li>
  89. <li><em>link</em> (optional) true/false to automatically link to channel.</li>
  90. </ul>
  91. Needs an <a href="authorize.php">authorized account</a> to function.
  92. </p>
  93. <p>
  94. <?php echo get_badge_svg( 'lctv last streamed', 'Jan 1, 2016', '#4c1' ); ?>
  95. <br>
  96. <?php echo get_badge_svg( 'lctv last streamed', 'never', '#e05d44' ); ?>
  97. </p>
  98. <br><br>
  99. </div>
  100. </body>
  101. </html>
  102. <?php