username . ' attempted to change the state of a song','1'); exit; } $song = new Song($_REQUEST['song_id']); $new_enabled = $song->enabled ? '0' : '1'; $song->update_enabled($new_enabled,$song->id); $song->enabled = $new_enabled; $song->format(); ob_start(); require Config::get('prefix') . '/templates/show_song_row.inc.php'; $results['song_' . $song->id] = ob_get_clean(); break; default: $results['rfc3514'] = '0x1'; break; } // switch on action; // We always do this echo xml_from_array($results); ?>