Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to inject external javascript code in phone browser

I would like to inject an external javascript code into a certain webpage in a mobile phone browser such as chrome or opera mini. On computers, we can do this directly in the console or through extensions such as Scripty. Unfortunately, phone browsers don't show consoles nor do they have extensions. Please how can I achieve this?

like image 346
Mich25educ Avatar asked Sep 07 '26 15:09

Mich25educ


2 Answers

You can use eruda. It's a console for mobile browsers. It also has many plugins such as eruda-touches which visualizes all current touches and their positions. Personally, I made a bookmark using chrome browser on my phone to implement this console directly in any page when i search for its name. Watch this youtube video for more details.

like image 57
ABOUD Avatar answered Sep 10 '26 04:09

ABOUD


You can use the address-bar to run javascript in that page.

(Tested in Chrome)

Like this:

Step0 Step1 Step2

Since all the codes will be in one line, make sure you use semicolons properly.

like image 29
Labnan Avatar answered Sep 10 '26 04:09

Labnan