2013-05-30 4 views
1

inAppBrowser가 phonegap 빌드로 작업하도록하려면 config.xml에 특정 설정을 추가해야합니까?Phonegap Build InAppBrowser

임은 추가 :

var ref = window.open(url, '_blank'); 

또는

var ref = window.open(url, 'blank'); 

하지만 작품을 나던.

내 구성 XML : 당신은 당신이 거기에있는 것보다 더 많이해야 당신의 Config.xml의

window.open(destination, '_blank', 'location=yes,enableViewportScale=yes'); 

: 인 - 응용 프로그램 브라우저를 엽니 다 내가 이렇게

<?xml version="1.0" encoding="UTF-8" ?> 
<widget xmlns = "http://www.w3.org/ns/widgets" xmlns:gap = "http://phonegap.com/ns/1.0" id = "com.phonegap.myapp"> 
    <name>My app</name> 
    <description>test</description> 
    <preference name="phonegap-version" value="2.7.0" /> 
    <access origin="*" /> 
    <preference name="fullscreen" value="false" /> 
</widget> 

답변

1

. 이것은 내 꺼야 :

<?xml version="1.0" encoding="UTF-8"?> 

<widget> 
<preference name="AllowInlineMediaPlayback" value="false" /> 
<preference name="AutoHideSplashScreen" value="true" /> 
<preference name="BackupWebStorage" value="cloud" /> 
<preference name="DisallowOverscroll" value="false" /> 
<preference name="EnableLocation" value="false" /><!-- DEPRECATED --> 
<preference name="EnableViewportScale" value="false" /> 
<preference name="FadeSplashScreen" value="true" /> 
<preference name="FadeSplashScreenDuration" value=".25" /> 
<preference name="HideKeyboardFormAccessoryBar" value="false" /> 
<preference name="KeyboardDisplayRequiresUserAction" value="true" /> 
<preference name="KeyboardShrinksView" value="false" /> 
<preference name="MediaPlaybackRequiresUserAction" value="false" /> 
<preference name="ShowSplashScreenSpinner" value="true" /> 
<preference name="SuppressesIncrementalRendering" value="false" /> 
<preference name="TopActivityIndicator" value="gray" /> 

<content src="index.html" /> 

<plugins> 
    <plugin name="Device" value="CDVDevice" /> 
    <plugin name="Logger" value="CDVLogger" /> 
    <plugin name="Compass" value="CDVLocation" /> 
    <plugin name="Accelerometer" value="CDVAccelerometer" /> 
    <plugin name="Camera" value="CDVCamera" /> 
    <plugin name="NetworkStatus" value="CDVConnection" /> 
    <plugin name="Contacts" value="CDVContacts" /> 
    <plugin name="Debug Console" value="CDVDebugConsole" /> 
    <plugin name="Echo" value="CDVEcho" /> 
    <plugin name="File" value="CDVFile" /> 
    <plugin name="FileTransfer" value="CDVFileTransfer" /> 
    <plugin name="Geolocation" value="CDVLocation" /> 
    <plugin name="Notification" value="CDVNotification" /> 
    <plugin name="Media" value="CDVSound" /> 
    <plugin name="Capture" value="CDVCapture" /> 
    <plugin name="SplashScreen" value="CDVSplashScreen" /> 
    <plugin name="Battery" value="CDVBattery" /> 
    <plugin name="Globalization" value="CDVGlobalization" /> 
    <plugin name="InAppBrowser" value="CDVInAppBrowser" /> 
</plugins> 

<access origin="*" /> 
</widget> 

당신은 폰갭의 모든 기능을 사용하지 않으면 너의 작은 수 있습니다. 그러나 InAppBrowser 플러그인이 꼭 필요합니다!

+0

그게 :) 고마워요. –

관련 문제