//////////////////////////////////////////////
//jQuery No Conflict
var j$ = jQuery.noConflict();

//速報
//var message = new Array();
//var entryLength = 3;
//var no = 0;
//
function initTicker(xmlDataSet) {
//    j$.ajax({
//        type: 'GET',
//        url: 'RSS.rdf',
//        async: true,
//        cache: true,
//        dataType: "xml",
//        success: function(result)
//        {
//            processNodes(result);
//        },
//      error: function (xmlhttp, textStatus, errorThrown) {
//        alert("xmlhttp.status: " + xmlhttp.status + ", \n" +
//              "textStatus: " + textStatus + ", \n" +
//              "errorThrown: " + errorThrown);
//      }
//    });
}
//
//function processNodes(xml)
//{
//    entryLength=j$("item",xml).length;
//    for(var i=0; i<entryLength; i++){
//        strToAppend = '<a href="' + j$("item > link",xml)[i].childNodes[0].nodeValue + '">' + j$("item > title",xml)[i].childNodes[0].nodeValue + '<\/a>';
//        message[message.length++] = strToAppend;
//    }
//    ticker();
//}
//
//function ticker(){
//    if(no == entryLength){
//        no = 0;
//    }
//    j$("#message").empty();
//    j$("#message").append(message[no]);
//    no++;
//    j$("#message").val(message[no]);
//    j$("#message").animate({opacity: 'show' }, 1500, "easeInQuad", function(){ j$(this).animate({opacity: 1.0 }, 4000, "easeInQuad", function(){j$(this).animate({opacity: 'hide' }, 1500, "easeInQuad", function(){ticker()})})});
//}


//////////////////////////////////////////////
//HTMLロード後共通処理
j$(document).ready(function () {
    jQuery(function (j$) {
        j$('#box_login .login a,#tf_comment_login .login a').click(function (e) {
            e.preventDefault();
            var rcms_page = j$("#page_sysnm").val();
            var rcms_id = j$("#id").val();
            var newDivHTML = "";
            newDivHTML += '<form action="http://www.football-plaza.jp/mypage/login_check.php" method="post" id="login" name="">';
            newDivHTML += '<input name="mode" type="hidden" value="login" />';
            newDivHTML += '<input name="from_rcms" type="hidden" value="1" />';
            newDivHTML += '<input name="rcms_page" type="hidden" value="' + rcms_page + '" />';
            newDivHTML += '<input name="rcms_id" type="hidden" value="' + rcms_id + '" />';
            newDivHTML += '<div class="label">ID</div>';
            newDivHTML += '<input name="mypage_login_email" type="text" class="query" value="" />';
            newDivHTML += '<div class="label margin">password</div>';
            newDivHTML += '<input name="mypage_login_pass" type="text" class="query" value="" />';
            newDivHTML += '<div class="link"><a href="http://www.football-plaza.jp/forgot/">パスワードを忘れた方はこちら</a></div>';
            newDivHTML += '<input type="submit" class="bt_login" value="ログイン" />';
            newDivHTML += '</form>';
            j$.modal(newDivHTML);
        });
    });
});
