1

典型的なケース:

       $.ajax({
            url: schedule.link,
            context: document.body
        }).done(function(data) {
            // tutt ok, quindi scrivo il file
            console.log (data);
        }).error(function (jqXHR, textStatus, errorDescription ) {
            // segnalo il problema
            logga("Error " + error.description);
        });

dataajax経由で受信したxPathを使用するにはどうすればよいですか?

単純に//ul.resultxpathとして取得する必要があります

4

1 に答える 1

1

次のように実行する必要があります(jQueryを使用している場合)。

$.ajax({
        url: schedule.link,
        context: document.body
    }).success(function(data) {
        // gives you the html inside the matching expression
        alert($('xpathexpr', data).html());
    }).error(function (jqXHR, textStatus, errorDescription ) {
        // segnalo il problema
        logga("Error " + error.description);
    });
于 2013-03-24T18:07:43.677 に答える