if ($boxcar_activated) { echo "Boxcar notifications set for {$boxcar_uid}<br/>"; } else { echo "Push notifications not activated!"; } } echo "</td>"; echo "<td><input type='text' name='issuetrackerurl' size='25' maxlength='4000' value='" . $issuetrackerurl . "' placeholder='%subject% %description%'/><br>"; echo "<input type='text' name='hockeyappidentifier' size='25' value='" . $hockeyappidentifier . "' maxlength='4000' placeholder='HockeyApp Public Identifier'/></td>"; echo "<td><select name='symbolicate' onchange='javascript:document.update" . $id . ".submit();'>"; add_option("Don't symbolicate", 0, $symbolicate); add_option('Symbolicate', 1, $symbolicate); echo "</select><br/>"; // get the total number of crashes $query2 = "SELECT count(*) FROM " . $dbcrashtable . " WHERE bundleidentifier = '" . $bundleidentifier . "'"; $result2 = mysql_query($query2) or die(end_with_result('Error in SQL ' . $query2)); $totalcrashes = 0; $numrows2 = mysql_num_rows($result2); if ($numrows2 > 0) { $row2 = mysql_fetch_row($result2); $totalcrashes = $row2[0]; mysql_free_result($result2); } echo $totalcrashes . "</td>"; echo "<td><button class='button' type='submit'>Update</button>"; echo " <a href='app_name.php?id=" . $id . "' class='button redButton' onclick='return confirm(\"Do you really want to delete this item?\");'>Delete</a></td>"; echo "</tr></table></form>"; } mysql_free_result($result); } mysql_close($link);
} echo '</td><td><input type="text" id="fixversion' . $groupid . '" name="fixversion" size="20" maxlength="20" value="' . $fix . '"/></td><td><textarea id="description' . $groupid . '" cols="50" rows="2" name="description" class="description">' . $description . '</textarea></td><td>'; echo "<a href=\"javascript:updateGroupMeta(" . $groupid . ",'" . $bundleidentifier . "')\" class='button'>Update</a> "; echo "<a href='actionapi.php?action=downloadcrashid&groupid=" . $groupid . "' class='button'>Download</a> "; $issuelink = currentPageURL(); $issuelink = substr($issuelink, 0, strrpos($issuelink, "/") + 1); echo create_issue($bundleidentifier, $issuelink . 'crashes.php?groupid=' . $groupid . '&bundleidentifier=' . $bundleidentifier . '&version=' . $version); echo " <a href='javascript:deleteGroupID(" . $groupid . ")' class='button redButton' onclick='return confirm(\"Do you really want to delete this item?\");'>Delete</a></td></tr>"; echo '</table>'; echo '</form>'; } mysql_free_result($result); } // get all bugs not assigned to groups $query = "SELECT count(*) FROM " . $dbcrashtable . " WHERE groupid = 0 and bundleidentifier = '" . $bundleidentifier . "' AND version = '" . $version . "'"; $result = mysql_query($query) or die(end_with_result('Error in SQL ' . $dbcrashtable)); $numrows = mysql_num_rows($result); if ($numrows > 0) { $row = mysql_fetch_row($result); $amount = $row[0]; if ($amount > 0) { echo '<table>' . $cols; echo '<tr><td><a href="crashes.php?bundleidentifier=' . $bundleidentifier . '&version=' . $version . '">Ungrouped</a></td>'; echo '<td>' . $amount . '</td><td></td><td></td><td></td>'; echo "<td><a href='regroup.php?bundleidentifier=" . $bundleidentifier . "&version=" . $version . "' class='button'>Re-Group</a>"; echo "<a href='groups.php?bundleidentifier=" . $bundleidentifier . "&version=" . $version . "&groupid=0' class='button redButton' onclick='return confirm(\"Do you really want to delete this item?\");'>Delete</a></td></tr>"; echo '</table>'; } mysql_free_result($result); } mysql_close($link);
// require_once '../config.php'; function end_with_result($result) { return '<html><body>' . $result . '</body></html>'; } $allowed_args = ',id,'; $link = mysql_connect($server, $loginsql, $passsql) or die(end_with_result('No database connection')); mysql_select_db($base) or die(end_with_result('No database connection')); foreach (array_keys($_GET) as $k) { $temp = ",{$k},"; if (strpos($allowed_args, $temp) !== false) { ${$k} = $_GET[$k]; } } if (!isset($id)) { $id = ""; } if ($id == "") { die(end_with_result('Wrong parameters')); } $query = "SELECT log FROM " . $dbcrashtable . " WHERE id = " . $id; $result = mysql_query($query) or die(end_with_result('Error in SQL ' . $dbversiontable)); $numrows = mysql_num_rows($result); if ($numrows > 0) { while ($row = mysql_fetch_row($result)) { echo $row[0]; } mysql_free_result($result); } mysql_close($link);
// external process // require_once '../config.php'; function end_with_result($result) { return '<html><body>' . $result . '</body></html>'; } $allowed_args = ','; $link = mysql_connect($server, $loginsql, $passsql) or die(end_with_result('No database connection')); mysql_select_db($base) or die(end_with_result('No database connection')); foreach (array_keys($_GET) as $k) { $temp = ",{$k},"; if (strpos($allowed_args, $temp) !== false) { ${$k} = $_GET[$k]; } } $crashids = ""; $query = "SELECT crashid FROM " . $dbsymbolicatetable . " WHERE done = 0"; $result = mysql_query($query) or die(end_with_result('Error in SQL ' . $dbsymbolicatetable)); $numrows = mysql_num_rows($result); if ($numrows > 0) { while ($row = mysql_fetch_row($result)) { if ($crashids != '') { $crashids .= ','; } $crashids .= $row[0]; } mysql_free_result($result); } mysql_close($link); echo $crashids;
$query = "SELECT log FROM " . $dbcrashtable . " WHERE id = '" . $crashid . "' ORDER BY systemversion desc, timestamp desc LIMIT 1"; $result = mysql_query($query) or die(end_with_result('Error in SQL ' . $query)); $numrows = mysql_num_rows($result); if ($numrows > 0) { // get the status $row = mysql_fetch_row($result); $logdata = $row[0]; mysql_free_result($result); } $crash["bundleidentifier"] = $bundleidentifier; $crash["version"] = $version; $crash["logdata"] = $logdata; $crash["id"] = $crashid; $error = groupCrashReport($crash, $link, NOTIFY_OFF); if ($error != "") { die(end_with_result($error)); } } mysql_free_result($result1); } mysql_close($link); ?> <html> <head> <META http-equiv="refresh" content="0;URL=groups.php?&bundleidentifier=<?php echo $bundleidentifier; ?> &version=<?php echo $version; ?> ">