[xiph-commits] r18957 - branches/dir.xiph.org/cronjobs

dm8tbr at svn.xiph.org dm8tbr at svn.xiph.org
Sun Jun 9 04:22:22 PDT 2013


Author: dm8tbr
Date: 2013-06-09 04:22:22 -0700 (Sun, 09 Jun 2013)
New Revision: 18957

Added:
   branches/dir.xiph.org/cronjobs/update_opus.php
Log:
Quick hack for dir.xiph.org that updates all mountpoints where URL ends in 'opus' to type opus.


Added: branches/dir.xiph.org/cronjobs/update_opus.php
===================================================================
--- branches/dir.xiph.org/cronjobs/update_opus.php	                        (rev 0)
+++ branches/dir.xiph.org/cronjobs/update_opus.php	2013-06-09 11:22:22 UTC (rev 18957)
@@ -0,0 +1,14 @@
+<?php
+
+// Inclusions
+include_once(dirname(__FILE__).'/../inc/prepend.php');
+
+// Database connection
+$db = DirXiphOrgDBC::getInstance();
+
+// Quick hack to update all mountpoints ending in opus to media_type_id for Opus instead of generic Ogg
+$query = "UPDATE mountpoint SET media_type_id = 107 WHERE id IN (SELECT mountpoint_id FROM server WHERE listen_url LIKE '%opus');";
+$db->noReturnQuery($query);
+
+
+?>



More information about the commits mailing list