How to set referer when user comes from Google Chrome app icon? - google-chrome

I have a chrome app which basically is just a visual bookmark which sends the visitors to my website.
Currently it doesn't show any referer because technically the user came directly to the website.
Is there a way to detect this?
I understand I can append some query parameters in the URL of the chrome app but I am wondering if there's a cleaner solution than this.

The chrome.webRequest property should allow you to set the information you need. I couldn't find exact details that would help but there is an Auth option which you may be able to use as a referrer.
Hope this helps. Sorry I could not help further.
https://developer.chrome.com/extensions/webRequest.html

Related

How to make a html request without changing current URL?

Think of it like a login page. You type in all the credentials and click login. But I wanna check the username and password are correct or not and they will be in my database. So i use a API to communicate. And then u click login then through JavaScript i send a request but then the browser totally changes the page. All i want is the result but the browser changes the URL. Is there a way to do it?. Currently I am letting the page redirect back, its working fine but it just looks ugly.
Sorry i didn't include any code, I thought Code isn't necessary.
It's difficult to guess without seeing the code.
Anyway, are you using fetch?
Fetch is used if a browser should not navigate to a new page. The response is processed using Javascript instead.
Take a closer look at the fetch API, I think it can solve your problem.

Can I deduce HTML POST data from the front end?

please may I have a little help I'm stuck not being able to google for a solution because of very common words.
There is a web page that uses POST to send data to a page on a subdomain when a button is clicked.
I need to recreate a button and send the same information.
My question is: Is it possible just by looking at the page (and the console??) when you click the button, to observer what happens and recreate/implement the same POST method?
Can I say for example: It does this, therefore I need this code to do the same thing?
Or is it not possible to reverse engineer? Will I have to seek help form the web page developer (not really an option in this case).
It is perfectly possible to inspect the request and reverse engineer this. You can use tools like the developer console in your Chrome/Edge browser (press F12), and tools like Postman to simulate requests. Also inspect the form and eventual javascript events attached to the button.

URL Scheme fallback

Is it possible to have a fallback href?
I put an URL Scheme in a website, code below:
Tweet!
This sends out a Tweet with the app Tweetbot containing "test". If people haven't installed Tweetbot, nothing will happen clicking the link. Is there a way to do a fallback to the web version of twitter and/or different apps?
Thanks
I remember seeing similar questions regarding the tel:// URL scheme a while ago. Unfortunately, I don't think this is possible directly from a webpage, but check out this question as it may offer some useful hacks (such as using a setTimeout for if the scheme isn't present - I can't confirm that they work). My personal favorite answer there is from mrahman, who uses the Date().getTime() method so that users who do have the App won't get the message / be redirected.
I guess if your users are going to be using the functionality frequently then you could save their choice of whether to use the app or the web version.

Is there anyway to install an extention without visiting to google app store?

Is there anyway to install an extention without visiting to google app store?
For example I want visitors, can install my extention just one clicking a facebook ad or a banner?
Is it possible?
I read some article that mentioning about to verified site ownership to do this. But I want to make advertisement on facebook so I wouldn't be owner of the web page...
Does anyone have information on this subject?
Thanks.
Right click on the Chrome shortcut
In the Target field, add --enable-easy-off-store-extension-install after what's already there, let a space before
Save and start Chrome
You're probably looking for inline installation, performed via chrome.webstore.install.
In your webpage:
include <link rel="chrome-webstore-item" href="https://chrome.google.com/webstore/detail/itemID">, where the URL is the address of your extension
then. call chrome.webstore.install().
Unfortunately, you can't do either of those things on a basic Facebook page, but you could do it on a web page you can fully control.

How to block a specific URL in google chrome extension?

I am trying to develop a chrome extension which blocks a specific URL like gmail.com and when someone goes to gmail.com they got pop up to enter the password to continue to that website, this may decrease unauthorized way of accessing your personal sites.
If you know something about let me know, I have googled some extension and there are two-three extensions which block sites like stay focused.
The simplest way to do this is to inject a content script to all pages that should be 'protected' (you can set it up using "content_scripts"/"matches" setting in manifest.json). When script is injected and fired it should display the login dialog and handle the sign in process. You may use this code as a starting point for your extension.
BTW, I don't think that your extension can really protect anything working the way you described it. Extensions may be easily deactivated/uninstalled.