Change Google chrome homepage by extension - google-chrome-extension

Is there anyway to change google chrome homepage url by an extension.
I'm trying to write a simple extension which can change homepage url.
Hope you can help me.

It is possible, and a quick search reveals that such an extension already exists.
If you want to do it yourself, you can have a look at the Override Pages documentation. You can change the New Tab page, and therefore can simply implement an HTTP redirect in Javascript to the page you want.

Insert this code to manifest.json:
"chrome_settings_overrides": {
"homepage": "http://www.homepage.com"
}

Related

Chrome.tabs.executeScript is not working on some URLS like https://thekindlyones.org/2010/10/13/refusing-to-look-through-galileos-telescope/

I wrote a content script file in my chrome extension which i want to be injected on every url I visit which is no longer available/can't be reached. But on some URLS which has errors like This site can’t be reached, it doesn't work. I tried this URL https://thekindlyones.org/2010/10/13/refusing-to-look-through-galileos-telescope/
Anyone has idea regarding this? Is it supposed to work like this?

Browser Console - How to include javascript code on every page redirect?

Is is possible to load special javascript code (created by me) to my browser console (mozilla firefox) on every redirect page? I want to create a special script-robot, which will be do special actions on some website. For example:
Click button: "Add new advert"
... NOW IS REDIRECT
Write to input[name='title'] advert title
Write to input[name='description'] advert description
Click button: "Add now!"
... NOW IS REDIRECT
Click button: "Logout".
So I want to include my own javascript code to my console and I want automatically reinclude this file on every page redirect. Is is possible?
Thanks.
yes, it is possible. What you would do is create your own google extension with links to a js file to run. Here are some instructions on how to make said extension.

Where/How is generated the html code of vsftpd?

I mean the html code generated when you get into ftp://yourserver... I tried to google it with no luck, not found in the project webpage either. I'd like to modify that code to do it more mobile friendly.
Thank you in advance
If you use a browser to load an FTP directory then the HTML page will be generated by the browser from the directory listing.
For example, see this part of the source code for Google Chrome.

how to load iframe using contentscript and override xframe

First of all, is there another built in way to do this like webview is in phonegap, so I can load an external site into a div or div like element. I know webview exists for chrome apps, but i couldn't find anything for extensions.
Basically i want to show preview of pages on links..
To do that I am trying to load urls of links using by setting src of iframes using content script. However, for most urls, I get an error that xframe not allowed.
what are my options.
xframe is pretty full proof, however, if you aren't referring to specifically an iframe, you could always use a web-proxy such as node-unblocker for node.js, or miniProxy for PHP.

chrome extension options change default popup.html

I have a chrome extension where the popup.html simply has an iframe that loads a page.
I want to allow users to select their language, and as I'm helping a charity do this each language page is very different as they need very different content based on the country!
Therefore, I can't just replace some of the fields like the google developer page example does; I need to change the page that is loaded in the iframe.
e.g. In my directory where the pages are stored I have english.html, german.html, spanish.html all of which are completely different pages.
By default the english.html page loads in the iframe, but the user should be able to go into the options file and select german so when they click on the extension the german.html loads by default every time.
Here is the jsfiddle showing what I currently have in the popup.html, and the popup.js:
http://jsfiddle.net/hemang2/EDV82/
You'll see the flickr API being called, but that's only there because I wasn't sure how to get rid of it!
So essentially my question is how to link the options file to change the default url loaded in the iframe.
Use the setPopup method: http://developer.chrome.com/extensions/browserAction.html#method-setPopup
It allows you to set any html file as your popup.

Resources