1. Are you ready for the Galaxy S20? Here is everything we know so far!

angular cordova application html5 video tag does not play on android

Discussion in 'Android Development' started by chinnar, Jul 10, 2020.

  1. chinnar

    chinnar Lurker
    Thread Starter

    I have an angular cordova application which has got the html video tag that plays on IOS but not on Android. Play button does not show on android

    html tag is as below:

    Code (Text):
    1.  
    2. <video width="320" height="240" controls="controls">
    3.   <source src="https://sample1.mp4" type="video/mp4" />
    4. </video>

    config.xml of Cordova is as below:
    Code (Text):
    1. <content src="index.cordova.html" />
    2.     <plugin name="cordova-plugin-whitelist" spec="1" />
    3.     <access origin="*://*.xxx.com" />
    4.     <allow-intent href="http://*/*" />
    5.     <allow-intent href="https://*/*" />
    6. <platform name="android">
    7.         <allow-intent href="market:*" />
    8.         <icon src="assets/android/ldpi.png" density="ldpi" />
    9.         <icon src="assets/android/mdpi.png" density="mdpi" />
    10.         <icon src="assets/android/hdpi.png" density="hdpi" />
    11.         <icon src="assets/android/xhdpi.png" density="xhdpi" />
    12.         <icon src="assets/android/xxhdpi.png" density="xxhdpi" />
    13.         <icon src="assets/android/xxxhdpi.png" density="xxxhdpi" />
    14.     </platform>
    15. <platform name="ios">
    16.         <allow-intent href="itms:*" />
    17.         <allow-intent href="itms-apps:*" />
    18.  
    19.         <edit-config target="NSCameraUsageDescription" file="*-Info.plist" mode="merge">
    20.             <string>Need camera access to take pictures</string>
    21.         </edit-config>
    22.  
    23.         <edit-config target="NSPhotoLibraryUsageDescription" file="*-Info.plist" mode="merge">
    24.           <string>Need photo library access to get pictures from there</string>
    25.         </edit-config>
    26.  
    27.         <!-- iOS 8.0+ -->
    28.         <!-- iPhone 6 Plus  -->
    29.         <icon src="assets/ios/icon-60@3x.png" width="180" height="180" />
    30.         <!-- iOS 7.0+ -->
    31.         <!-- iPhone / iPod Touch  -->
    32.         <icon src="assets/ios/icon-60.png" width="60" height="60" />
    33.         <icon src="assets/ios/icon-60@2x.png" width="120" height="120" />
    34.         <!-- iPad -->
    35.         <icon src="assets/ios/icon-76.png" width="76" height="76" />
    36.         <icon src="assets/ios/icon-76@2x.png" width="152" height="152" />
    37.         <!-- Spotlight Icon -->
    38.         <icon src="assets/ios/icon-40.png" width="40" height="40" />
    39.         <icon src="assets/ios/icon-40@2x.png" width="80" height="80" />
    40.         <!-- iOS 6.1 -->
    41.         <!-- iPhone / iPod Touch -->
    42.         <icon src="assets/ios/icon.png" width="57" height="57" />
    43.         <icon src="assets/ios/icon@2x.png" width="114" height="114" />
    44.         <!-- iPad -->
    45.         <icon src="assets/ios/icon-72.png" width="72" height="72" />
    46.         <icon src="assets/ios/icon-72@2x.png" width="144" height="144" />
    47.         <!-- iPad Pro -->
    48.         <icon src="assets/ios/icon-167.png" width="167" height="167" />
    49.         <!-- iPhone Spotlight and Settings Icon -->
    50.         <icon src="assets/ios/icon-small.png" width="29" height="29" />
    51.         <icon src="assets/ios/icon-small@2x.png" width="58" height="58" />
    52.         <icon src="assets/ios/icon-small@3x.png" width="87" height="87" />
    53.         <!-- iPad Spotlight and Settings Icon -->
    54.         <icon src="assets/ios/icon-50.png" width="50" height="50" />
    55.         <icon src="assets/ios/icon-50@2x.png" width="100" height="100" />
    56.         <!-- iPad Pro -->
    57.         <icon src="assets/ios/icon-83.5@2x.png" width="167" height="167" />
    58.     </platform>
    59.     <preference name="webviewbounce" value="false" />
    60.     <preference name="UIWebViewBounce" value="false" />
    61.     <preference name="DisallowOverscroll" value="true" />
    62.     <preference name="android-minSdkVersion" value="23" />
    63.     <preference name="BackupWebStorage" value="none" />

    Not sure if there is a problem with the video tag or any configuration specific to Android in Cordova. Is there any plugin specific to Android Cordova need to be installed or changes to video tag to be done.
     


    #1 chinnar, Jul 10, 2020
    Last edited: Jul 11, 2020
Loading...
Similar Threads - angular cordova application
  1. UndefinedN00B
    Replies:
    7
    Views:
    526
  2. andrey2211
    Replies:
    0
    Views:
    517
  3. Kavinraj M
    Replies:
    3
    Views:
    651
  4. akaskhu
    Replies:
    2
    Views:
    350
  5. Samsung
    Replies:
    0
    Views:
    216
  6. SeanRouxWTB
    Replies:
    0
    Views:
    257
  7. Senchi007
    Replies:
    4
    Views:
    370
  8. TheOuz
    Replies:
    0
    Views:
    421
  9. Mikul Patel
    Replies:
    0
    Views:
    374
  10. Mikul Patel
    Replies:
    0
    Views:
    334

Share This Page

Loading...