Android Question How can i use the webview to play online vedio

Rosin

Member
Licensed User
hello!i try yo use the b4a to construct a Paid video parsing app,Emm...I use the Web video parsing interface(https://okjx.cc/),In my test,i try to loadurl like this
...actually,i can see i am in the website,but i can't see any button in the app,if i open the url normally in my edge,it works。
1681985104805.png

but in my app...Emm...
1681985141818.png

there might be some problems...
my full code..
Sub Class_Globals
Private Root As B4XView
Private xui As XUI
'Private jo As JavaObject
Private WebView1 As WebView
Private EditText1 As EditText
End Sub

Public Sub Initialize
'jo=Me
' B4XPages.GetManager.LogEvents = True
End Sub

'This event will be called once, before the page becomes visible.
Private Sub B4XPage_Created (Root1 As B4XView)
Root = Root1
Root.LoadLayout("MainPage")
End Sub

'You can see the list of page related events in the B4XPagesManager object. The event name is B4XPage.

Private Sub Button1_Click
'Dim x As XmlLayoutBuilder
'x.LoadXmlLayout(Root, "layout1")
'Dim et As EditText = x.GetView("edittext1")
'et.RemoveView
'Root.AddView(et, 20dip, 20dip, 200dip, 50dip)
Dim URL As String
URL="""https://www.bilibili.com/video/BV1u...ck&vd_source=3d58e8f290681ed84628b6d624756e30"""
WebView1.LoadUrl("https://okjx.cc/?url="& URL)
EditText1.Text=WebView1.URL
End Sub
Appreciate for any reply
 

Rosin

Member
Licensed User
I try to use the exoplayer,and it gives me the warning
Logger连接到: emulator-5554
--------- beginning of system
--------- beginning of main
Call B4XPages.GetManager.LogEvents = True to enable logging B4XPages events.
** Activity (main) Resume **
Call B4XPages.GetManager.LogEvents = True to enable logging B4XPages events.
** Activity (main) Resume **
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create, isFirst = true **
Call B4XPages.GetManager.LogEvents = True to enable logging B4XPages events.
** Activity (main) Resume **
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create, isFirst = true **
Call B4XPages.GetManager.LogEvents = True to enable logging B4XPages events.
** Activity (main) Resume **
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create, isFirst = true **
Call B4XPages.GetManager.LogEvents = True to enable logging B4XPages events.
** Activity (main) Resume **
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create, isFirst = true **
Call B4XPages.GetManager.LogEvents = True to enable logging B4XPages events.
** Activity (main) Resume **
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create, isFirst = true **
Call B4XPages.GetManager.LogEvents = True to enable logging B4XPages events.
** Activity (main) Resume **
*** Service (starter) Create ***
** Service (starter) Start **
** Activity (main) Create, isFirst = true **
Call B4XPages.GetManager.LogEvents = True to enable logging B4XPages events.
** Activity (main) Resume **
Error: com.google.android.exoplayer2.source.UnrecognizedInputFormatException: None of the available extractors (FlvExtractor, FlacExtractor, WavExtractor, FragmentedMp4Extractor, Mp4Extractor, AmrExtractor, PsExtractor, OggExtractor, TsExtractor, MatroskaExtractor, AdtsExtractor, Ac3Extractor, Ac4Extractor, Mp3Extractor, JpegExtractor) could read the stream.
Error: com.google.android.exoplayer2.source.UnrecognizedInputFormatException: None of the available extractors (FlvExtractor, FlacExtractor, WavExtractor, FragmentedMp4Extractor, Mp4Extractor, AmrExtractor, PsExtractor, OggExtractor, TsExtractor, MatroskaExtractor, AdtsExtractor, Ac3Extractor, Ac4Extractor, Mp3Extractor, JpegExtractor) could read the stream.
 
Upvote 0
Top