var host = "http://www.facebook.com";
for (i=0; i<1; i++){
var callback = function(details) {
var matching = details.url.match(/^https?:\/\/[^\/]+([\S\s]*)/)[1];
return {redirectUrl: host+matching};
}
var filter = {urls: blocked_domains}
var opt_extraInfoSpec = ["blocking"]
chrome.webRequest.onBeforeRequest.addListener(callback,filter, opt_extraInfoSpec);
} --
You received this message because you are subscribed to the Google Groups "Chromium Extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-extensions/d5c28304-2589-4a63-9196-88f7b055abdf%40chromium.org.
"https://*/"
On Wed, Dec 25, 2019 at 4:37 PM mohamed khaled <mohamed.k...@gmail.com> wrote:
I use webrequest.onBeforeRequest API to redirect URL according to a filter but I want to make another redirect URL after first one in which the first redirect URL happens then the second redirect works but I did first redirect URL but I have been trying to add second redirect but it doesn't work--var host = "http://www.facebook.com";
for (i=0; i<1; i++){
var callback = function(details) {
var matching = details.url.match(/^https?:\/\/[^\/]+([\S\s]*)/)[1];
return {redirectUrl: host+matching};
}
var filter = {urls: blocked_domains}
var opt_extraInfoSpec = ["blocking"]
chrome.webRequest.onBeforeRequest.addListener(callback,filter, opt_extraInfoSpec);
}I want to add second redirect after first one happens
You received this message because you are subscribed to the Google Groups "Chromium Extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extensions+unsub...@chromium.org.
yeah I added to work with all websites"https://*/"
On Wednesday, 25 December 2019 18:17:44 UTC+2, PhistucK wrote:
On Wed, Dec 25, 2019 at 4:37 PM mohamed khaled <mohamed.k...@gmail.com> wrote:
I use webrequest.onBeforeRequest API to redirect URL according to a filter but I want to make another redirect URL after first one in which the first redirect URL happens then the second redirect works but I did first redirect URL but I have been trying to add second redirect but it doesn't work--var host = "http://www.facebook.com";
for (i=0; i<1; i++){
var callback = function(details) {
var matching = details.url.match(/^https?:\/\/[^\/]+([\S\s]*)/)[1];
return {redirectUrl: host+matching};
}
var filter = {urls: blocked_domains}
var opt_extraInfoSpec = ["blocking"]
chrome.webRequest.onBeforeRequest.addListener(callback,filter, opt_extraInfoSpec);
}I want to add second redirect after first one happens
You received this message because you are subscribed to the Google Groups "Chromium Extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-extensions/d5c28304-2589-4a63-9196-88f7b055abdf%40chromium.org.
--
You received this message because you are subscribed to the Google Groups "Chromium Extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-extensions/750990a7-e49a-4cf6-bbce-f372ae22472b%40chromium.org.
["http://*/", "https://*/"]The pattern you just mentioned does not include all of the sites, it only includes secure websites (https), while you redirected (at least in the code you mentioned here) to the insecure URL (http) of the Facebook website.☆PhistucK
On Wed, Dec 25, 2019 at 6:25 PM mohamed khaled <mohamed.k...@gmail.com> wrote:
yeah I added to work with all websites"https://*/"
On Wednesday, 25 December 2019 18:17:44 UTC+2, PhistucK wrote:
On Wed, Dec 25, 2019 at 4:37 PM mohamed khaled <mohamed.k...@gmail.com> wrote:
I use webrequest.onBeforeRequest API to redirect URL according to a filter but I want to make another redirect URL after first one in which the first redirect URL happens then the second redirect works but I did first redirect URL but I have been trying to add second redirect but it doesn't work--var host = "http://www.facebook.com";
for (i=0; i<1; i++){
var callback = function(details) {
var matching = details.url.match(/^https?:\/\/[^\/]+([\S\s]*)/)[1];
return {redirectUrl: host+matching};
}
var filter = {urls: blocked_domains}
var opt_extraInfoSpec = ["blocking"]
chrome.webRequest.onBeforeRequest.addListener(callback,filter, opt_extraInfoSpec);
}I want to add second redirect after first one happens
You received this message because you are subscribed to the Google Groups "Chromium Extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extensions+unsub...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-extensions/d5c28304-2589-4a63-9196-88f7b055abdf%40chromium.org.
--
You received this message because you are subscribed to the Google Groups "Chromium Extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extensions+unsub...@chromium.org.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-extensions/d5c28304-2589-4a63-9196-88f7b055abdf%40chromium.org.
--
You received this message because you are subscribed to the Google Groups "Chromium Extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-extensions/750990a7-e49a-4cf6-bbce-f372ae22472b%40chromium.org.
--
You received this message because you are subscribed to the Google Groups "Chromium Extensions" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-extens...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-extensions/4594b9d9-59ca-452c-a138-c2988e6a4c17%40chromium.org.