function submitShout(formData)
{
    var message = encode_entities(formData['title'].value);
    var params = {
        "title"   :  message,
        "message" :  message,
        "channel" :  774
    };

    new Ajax.Request('/action/shout', {
        method: 'post',
        parameters: params,
        onSuccess: function (result) {
            if ($('noresults')) { $('one-week-list').removeChild($('noresults')); }
            $('one-week-list').insert({'top': '<li>'+formData['title'].value+'</li>'});
            if ($('one-week-list').childElements().size() > 6) $('one-week-list').childElements().last().remove();
            $('boxTitle').value = '';
        },
        onFailure: function (exception) {
            alert('There was an error posting your comment.');
            console.log(exception);
        }
    });
}

function goToPage(page)
{
    var params = {
        'page': page
    };
    new Ajax.Request('/statements', {
        method: 'get',
        parameters: params,
        onSuccess: function (result) {
            $('lightwindow_contents').insert(result.responseText);
            $$('#lightwindow_contents .if-i-had-box')[0].remove();
        },
        onFailure: function (exception) {
            alert('There was an error requesting the specified page.')
            console.log(exception);
        }
    });
}