タグ

関連タグで絞り込む (1)

タグの絞り込みを解除

html5とxhrに関するgrapswizのブックマーク (2)

  • Bytes and Blobs

    File interface File : Blob { readonly attribute DOMString name; readonly attribute Date lastModifiedDate; }; All Files are Blobs Not all Blobs are Files How to Get a File With an <input> element: <input type="file" onchange="process(this.files[0])"> With Drag-and-Drop: droptarget.ondrop = function(e) { var files = e.dataTransfer.files; upload(files); } User grants permission to read the file(s) by

  • Google App Engineでクロスドメイン通信

    前回「秋はまだですか」と書きましたが、その日のうちに気温下がったw これでちょっと過ごしやすくなったかも。…薄着で寝ててちょっと風邪引きそうになったのは内緒(・ω・) 題。 クロスドメインでの非同期通信(XMLHttpRequest Level2)をGoogle App Engineで実装したのでメモ。はまったポイントもいくつか書いておきます。 特にハマったのは出力ヘッダ周り。 Access-Control-Allow-Origin これはあちこちのサイトに書かれてますね。このヘッダを「*」で出力してあげると他ドメインからの通信を受け付けるようになります。・・・が、これだけじゃダメなんです。 Access-Control-Allow-Methods こいつを指定してあげないとサーバーが受け付けてくれません。GETならGET、POSTならPOST・・・と指定してあげないといけません。これは

    Google App Engineでクロスドメイン通信
  • 1