2010-11-05 85 views
1

對於Facebook iframe應用程序,我們加載文件瀏覽器Java applet。在PC上的所有主流瀏覽器以及Mac上的Firefox上都可以正常工作。它也可以在Mac上的Safari中的iframe之外加載。iframe中的Java Applet無法在Mac Safari中加載

但是,只要在Safari/Mac中的iframe中調用頁面,小程序就不會加載。我們確實彈出了已簽名的applet許可權,但在此之後,加載只會旋轉,直到超時。

我已經在Facebook以外的iframe中測試過了,所以我知道這不是Facebook問題。還確保在Safari中啓用了Java並使其處於最新狀態,並且在控制檯中未觀察到相關的錯誤消息。

是否有其他人遇到此問題,如果有,是否有可以實施的解決方案或解決方法?

更新:從下面的Java控制檯輸出。始終掛在liveconnect調用的相同位置,不會拋出錯誤。

Java Plug-in 1.6.0_22 
Using JRE version 1.6.0_22-b04-307-10M3261 Java HotSpot(TM) Client VM 
User home directory = /Users/user 
Java Plug-in 1.6.0_22 
Using JRE version 1.6.0_22-b04-307-10M3261 Java HotSpot(TM) Client VM 
User home directory = /Users/user 
network: Loading user-defined proxy configuration… 
network: Done. 
network: Loading proxy configuration from Netscape Navigator… 
network: Done. 
network: Loading direct proxy configuration… 
network: Done. 
network: Proxy Configuration: No proxy 
basic: Referencing classloader: [email protected], refcount=1 
basic: Added progress listener: [email protected] 
basic: Loading applet… 
basic: Initializing applet… 
basic: Starting applet… 
basic: completed perf rollup 
network: Cache entry not found [url: http://[server_address_removed]/testutility10_21_2009_10_27_45.jar, version: null] 
network: Connecting http://[server_address_removed]/testutility10_21_2009_10_27_45.jar with proxy=DIRECT 
network: Connecting socket://[server_address_removed]:80 with proxy=DIRECT 
network: Cache entry not found [url: http://[server_address_removed]/testutility10_21_2009_10_27_45.jar, version: null] 
network: Cache entry not found [url: http://[server_address_removed]/testutility10_21_2009_10_27_45.jar, version: null] 
network: Connecting http://[server_address_removed]/testutility10_21_2009_10_27_45.jar with proxy=DIRECT 
network: Downloading resource: http://[server_address_removed]/testutility10_21_2009_10_27_45.jar 
Content-Length: 3,686 
Content-Encoding: null 
security: Blacklist revocation check is enabled 
network: Cache entry not found [url: http://[server_address_removed]/testutility10_21_2009_10_27_45.jar, version: null] 
network: Cache entry not found [url: http://[server_address_removed]/testutility10_21_2009_10_27_45.jar, version: null] 
network: Cache entry not found [url: http://[server_address_removed]/testutility10_21_2009_10_27_45.jar, version: null] 
network: Cache entry not found [url: http://[server_address_removed]/testutility10_21_2009_10_27_45.jar, version: null] 
network: Connecting http://[server_address_removed]/testutility10_21_2009_10_27_45.jar with proxy=DIRECT 
network: Cache entry not found [url: http://[server_address_removed]/testutility10_21_2009_10_27_45.jar, version: null] 
network: Cache entry not found [url: http://[server_address_removed]/testutility10_21_2009_10_27_45.jar, version: null] 
network: Cache entry not found [url: http://[server_address_removed]/testutility10_21_2009_10_27_45.jar, version: null] 
network: Cache entry not found [url: http://[server_address_removed]/testutility10_21_2009_10_27_45.jar, version: null] 
BaseApplet:init-complete 
applet:start 
invoking startup callback testAppletInitialized 
liveconnect: JSObject::call: name=open 
basic: Referencing classloader: [email protected], refcount=1 
basic: Added progress listener: [email protected] 
basic: Loading applet… 
basic: Initializing applet… 
basic: Starting applet… 
basic: completed perf rollup 
network: Cache entry not found [url: http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar, version: null] 
network: Connecting http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar with proxy=DIRECT 
network: Connecting socket://[server_address_removed]:80 with proxy=DIRECT 
network: Cache entry not found [url: http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar, version: null] 
network: Cache entry not found [url: http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar, version: null] 
network: Connecting http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar with proxy=DIRECT 
network: Downloading resource: http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar 
Content-Length: 33,019 
Content-Encoding: null 
network: Cache entry not found [url: http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar, version: null] 
network: Cache entry not found [url: http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar, version: null] 
network: Cache entry not found [url: http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar, version: null] 
security: Loading Root CA certificates from /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/lib/security/cacerts 
security: Loaded Root CA certificates from /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/lib/security/cacerts 
security: Loading certificates from Deployment session certificate store 
security: Loaded certificates from Deployment session certificate store 
security: Loading Root CA certificates from from keychain 
security: Loaded Root CA certificates from from keychain 
security: Validate the certificate chain using CertPath API 
security: Obtain certificate collection in Root CA certificate store 
security: Obtain certificate collection in Root CA certificate store 
security: Obtain certificate collection in Root CA certificate store 
security: jpicertstore.cert.getkeystore 
security: No timestamping info available 
security: Cannot find jurisdiction list file 
security: The CRL support is disabled 
security: The OCSP support is disabled 
security: This OCSP End Entity validation is disabled 
security: Checking if certificate is in Deployment denied certificate store 
security: Checking if certificate is in Deployment permanent certificate store 
security: Checking if certificate is in Deployment session certificate store 
security: Creating MacOSXTrust 
security: Evaluating MacOSXTrust 
security: MacOSXTrust: cert chain is valid, no explict intent 
security: MacOSXTrust: cert chain is valid, keychain explicity requested user confirmation 
security: Evaluating trust of site: [server_address_removed] 
security: Did not find a trusted site record for: http://[server_address_removed]<ab7662bf> 
security: Showing MacOSXTrustSiteDialog 
security: User permitted app to continue with priviledges 
security: MacOSXTrustUI.evaluateTrustAfterShow: returning GrantThisSession 
security: User has granted the privileges to the code for this session only 
security: Adding certificate in Deployment session certificate store 
security: Added certificate in Deployment session certificate store 
security: Saving certificates in Deployment session certificate store 
security: Saved certificates in Deployment session certificate store 
network: Cache entry not found [url: http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar, version: null] 
network: Connecting http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar with proxy=DIRECT 
network: Cache entry not found [url: http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar, version: null] 
network: Cache entry not found [url: http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar, version: null] 
network: Cache entry not found [url: http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar, version: null] 
network: Cache entry not found [url: http://[server_address_removed]/fileutility10_21_2009_10_27_45.jar, version: null] 
calling workaround: javascript:testAppletInitialized("1.6.0_22");BaseApplet:init-complete 
SingleFileServer23196574: server at http://127.0.0.1:3145 
SingleFileServer23196574: server running 
XMLSocketServer18107298:server at xmlsocket://127.0.0.1:7711 
XMLSocketServer18107298:policy <cross-domain-policy><allow-access-from domain='[server_address_removed]' secure='false' to-ports='7711' /></cross-domain-policy> 
applet:init-complete 
XMLSocketServer18107298:running 
applet:start 
SingleFileServer23196574: now serving certificate e848b62e2782e2cef20fe2d075d9e633 at http://127.0.0.1:3145/certificate1290016856751 
invoking startup callback 
calling workaround: javascript:appletInitialized("http://127.0.0.1:3145","xmlsocket://127.0.0.1:7711","http://127.0.0.1:3145/certificate1290016856751");running on Mac OS X 
applet:start-complete 
liveconnect: JSObject::call: name=open 

回答

1

UPDATE:解決以下不工作始終;在相同的環境下(Safari版本,操作系統版本,所有設置相同),這隻適用於我測試過的4個Mac中的1個。仍在尋找一個一致的解決方案。

我們可以通過修改的Mac OS的Java偏好來解決此問題:

  1. 打開Java首選項(應用程序>工具> Java首)
  2. 在常規選項卡,更改默認的「在瀏覽器進程「改爲」在他們自己的進程中「
  3. 確保在重新啓動Safari時清空緩存。

Mac版本:10.6.5; Safari版本:5.0.2; Java版本:1.6.0_22-604-307

Screenshot of Mac OS Java Preferences dialog

1

我仍然不知道原因,但我發現,對我們工作的解決方法。我意外發現的是,如果您重新加載小程序框架,它將第二次加載小程序。一個問題就是如果你做得太快,它就無法工作,所以我在延遲一秒鐘的時間裏添加了setTimeout。這似乎對我們有用。

if ((navigator.platform.toUpperCase().indexOf("MAC") != -1) && (navigator.vendor.toUpperCase().indexOf("APPLE") != -1)) { 
setTimeout("ReloadImageFrame('028-2007-009844', '', " + currentAppID + ")", 1000); }