So I am trying to make a chrome extension. I need it to take a URL, and modify a few characters specific characters and send you to newly edited URL. How would I do So?
            Asked
            
        
        
            Active
            
        
            Viewed 38 times
        
    -3
            
            
        - 
                    1See answers for chrome.webRequest.onBeforeRequest to redirect a URL, and a [demo extension](https://developer.chrome.com/extensions/samples#search:onbeforerequest). – wOxxOm Aug 06 '18 at 19:27
- 
                    Possible duplicate of [How can I get the URL of the current tab from a Google Chrome extension?](https://stackoverflow.com/questions/1979583/how-can-i-get-the-url-of-the-current-tab-from-a-google-chrome-extension) – Marvin Fischer Aug 07 '18 at 08:41
1 Answers
0
            
            
        You can use chrome.tabs.query too
chrome.tabs.query({currentWindow: true, active: true}, function (tab) {
      chrome.tabs.update(tab.id, {url: your_new_url});
});
 
    
    
        Pankaj Rupapara
        
- 752
- 4
- 9
 
    