スキップしてメイン コンテンツに移動

投稿

ラベル(https)が付いた投稿を表示しています

Check window.opener permission

Issue I tried to access some properties (or call methods) defined in http parent window via window.opener in pop-upped https window, which is created from the parent window. But it simply fails when accessing window.opener.a_property in the child window because the protocol is different between the child and parent window. e.g. http and https Remember this browser behavior is absolutely correct. The point of this post is how to avoid simply stopping javascript when accessing properties in window.opener. Browsers I confirmed this permission issue happens FireFox 17.0.1 and Internet Explore 9. Somehow Chrome doesn't complain it at all. the code simply passed. Solution In order to avoid this, I wrote the following conditions to detect the window.opener is accessible or not before accessing window.opener, but all of them don't return expected result at all. if(window.opener) // return true :( if(window.opener == undefined) // return true :( Finally I have reached at

Google App Engine

はじめに Google App Engineを試して見ようと思い、 Google App Engine for Java実践クラウド・プログラミング を購入して、ちょっと触って見ました。一通りできることは解説してあるので、とりあえずGoogle App Engineで動くサイトを作りたい人にはいい本かもしれません。 2012年7月8日追記: リンク先をチェックしたら 絶版 になってしまったようです。。。 必要なもの Java SDK: 私はJava SE Development Kit 7u3をインストールしました Eclipse: 私はEclipse IndigoのJava EE IDE for Web Developersをインストールしました Google App Engine Eclipse Plugin:私は以下の画像のものをとりあえずチェックしてインストールしました Bigtable Google App EngineのデータストアサービスであるBigtableのクエリに関しては、以下のリンクが参考になります。 Datastore Queries - Google App Engine — Google Developers 以下のコードでローカル環境に仮想のデータストアサービスがセットアップされます。 package com.dukesoftware.gaej.dao; import org.junit.After; import org.junit.Before; import org.junit.Test; import com.google.appengine.tools.development.testing.LocalDatastoreServiceTestConfig; import com.google.appengine.tools.development.testing.LocalServiceTestHelper; public class DaoTest { private final LocalServiceTestHelper helper = new LocalServiceTestHelper(new LocalDatastoreSer