how to fetch a url from a chrome extension? - google-chrome

I'm building a chrome extension where it needs to fetch the URL of the current website, the person is on.
For example, a person is watching a live stream on twitch. i want to fetch the twitch URL.
so how to do the same?

Related

Download files/videos from url and write them to disk without prompting save location dialoge using chrome app

I am writing a chrome app which needs to download videos from urls in background after specific time intervals.
Unlike chrome extension ( which has chrome.downloads api to deal with downloads ) chrome.downloads in not available for chrome apps.
If I use filesystem api, it shows the save location dialogue which I do not want. As, I need downloads to be dealt in the backgorund.
Is there any work around for this requirement ?

Eddystone for internal URLs

I programmed a service for the teachers of a school a tool which they can use to automate their classroom.
For easier access, i want to implement authentication via URL. The teacher WLAN is on a seperate subnet than the others.
The URL is a subdomain of a domain I own and added a SSL certificate. Now I am ready to deploy some beacons for test purposes and I noticed that Google Chrome won't show the beacons with my internal URL. URLs like google.com and facebook.com work just fine.
The physical Web browser app recognizes the internal URL.
What should I do?
Unfortunately, you cannot use Chrome to display physical web URLs pointing to a private subnet. Part of the Chrome system is a server-side component hosted at Google that checks the URL, validates that it resolves, and pulls metadata about the page it points to. If the page is not accessible on the open Internet, this check will fail and Chrome will silently ignore the physical web URL transmitted by the beacon.
While you cannot use Chrome to display such URLs, you can display them in your own custom app using detection SDKs like the Android Beacon Library.

Login on a site via google chrome extension

I want to make an extension for google chrome that watches for updating of information on a site. The problem is to do this I must to be logined on the site. Can I make an exsension so as it would ask a login and password from the site at start and then stores this information in the cookies? Does Chrome maintain abilities to make extension like this?
You don't have to do it. If you send a request from chrome extension to www.example.com - for example, the chrome extension adds the cookies from this site to your request. If the user isn't connected to example site, you can redirect him to login page in example.com and then continue. (Of course, you have to type "www.example.com" permission in manifest.json).
You can see sample from google- google mail checker.
(I'm sorry about my English).

Google Chrome plug in to read saved cookies

I'm new to Google Chrome plug in development. I have learnt how to develop a basic plug in. Now the problem is I'm trying to make a plug in that can read saved cookies of a particular website you visit.
For instance, a user visits www.facebook.com, after login he will click on our plug-in icon and a drop down window will appear and show all the cookies saved by Facebook.
Here I want to ask how to read the cookies of the site you are visiting? Is that possible to sort cookies with respect to site you visit?
If yes? Can you provide me a reference of how it could be done?
There is a Cookies API that allows Chrome extensions to access the browser's cookies, without having to send HTTP requests to obtain those cookies. More references
This thread might also be helpful.

Get the url of the website the user is about to open?

I am just developing an extension to kill time so I was wondering is it possible get the url of a website the person is about to open? like say suppose I open up a new tab and type in google.com. It is possible for me to get url as soon as I hit enter or go?