Closed myfrndjk closed 7 years ago
I think you could probably do that in your /etc/hosts file. Is this something that you can do in Chrome or Firefox? (It'd help if I could see an existing implementation)
Hi,
I tried some thing like below code in some other sample electron browser it is working fine but unfortunately it is not working with your version.I dont know where to modify your code exactly ` const {app, BrowserWindow} = require('electron');
let mainWindow;
app.on('window-all-closed', function() { app.quit(); });
app.on('ready', function() { mainWindow = new BrowserWindow({width: 1024, height: 768 }); var myVar = setInterval(myTimer, 5000);
function myTimer() { mainWindow.webContents.session.setProxy({pacScript:'file://' + dirname + '/proxy.pac'}, function () {}); } mainWindow.loadURL('file://' + dirname + '/browser.html'); mainWindow.openDevTools(); }); `
Sorry, I don't have enough free time to offer coding support like this. You'll have to solve this one on your own!
Sure. :)
Hi,
Can we set proxy dynamically in this browser. Something like
if the url is google.com --> '123.123.123.1':80 if the url is facebook.com --> '222.122.122.2':80
If yes where do i have to set that