Skip to content

Commit

Permalink
Added the option to easily change the favicon size.
Browse files Browse the repository at this point in the history
  • Loading branch information
michaelx committed Dec 6, 2013
1 parent b56587e commit dbee5ff
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -71,22 +71,26 @@ <h3>Favorite Sites</h3>
var favSites = ["michaelxander.com", "mymorningroutine.com", "mail.google.com", "drive.google.com", "twitter.com", "hootsuite.com", "nytimes.com", "news.ycombinator.com", "onethingwell.org", "brettterpstra.com", "instantwatcher.com", "hypetrak.com", "toucharcade.com"];
// 2) Sets: enter your urls without 'http://'. First array element is the name of the set.
var siteSets = [ ["evening set", "nytimes.com", "news.ycombinator.com", "onethingwell.org", "macstories.net", "stadt-bremerhaven.de", "brettterpstra.com", "instantwatcher.com", "hypetrak.com"], ["NYC", "michaelxander.com/static/nyc-cams.html", "hellonewyork.us", "newyork-ny-130.tumblr.com", "candidnewyork.tumblr.com", "uppereasttside.tumblr.com"], ["Travel", "skyscanner.de", "kayak.com", "en.wikivoyage.org", "wikitravel.org"] ];
// 3) Weather Forecast (optional): enter your zip code and country.
var zipCode = "10439";

/* OPTIONAL settings */
// 3) Weather Forecast: enter your zip code and country.
var zipCode = 10439;
var country = "Germany";
var unit = "c"; // c or f (for Celsius or Fahrenheit)
// 4) Search Field Focus (optional): uncomment to actiave (can be annoying if you immediately want to open an url)
// 4) Search Field Focus: uncomment to actiave (can be annoying if you immediately want to open an url)
//document.searchForm.q.focus();
// 5) Change Search Engine (optional): edit to search for example with DuckDuckGo (https://duckduckgo.com) instead of Google (https://www.google.com/search).
// 5) Change Search Engine: edit to search for example with DuckDuckGo (https://duckduckgo.com) instead of Google (https://www.google.com/search).
var searchEngine = "https://www.google.com/search";
// 6) Favicon size: edit to change the favicon size (default = 16)
var faviconSize = 16;
/* Configuration finished */


var favs = "";
var setOutput;

for (var i in favSites) {
favs += "<a href=\"http://" +favSites[i]+ "\" title=\"" +favSites[i]+ "\" target=\"_blank\"><img src=\"http://g.etfv.co/http://" +favSites[i]+ "\" alt=\"" +favSites[i]+ "\" width=\"16\" height=\"16\"></a> ";
favs += "<a href=\"http://" +favSites[i]+ "\" title=\"" +favSites[i]+ "\" target=\"_blank\"><img src=\"http://g.etfv.co/http://" +favSites[i]+ "\" alt=\"" +favSites[i]+ "\" width=\"" +faviconSize+ "\" height=\"" +faviconSize+ "\"></a> ";
};
document.getElementById("favoriteSites").innerHTML = favs;

Expand All @@ -102,7 +106,7 @@ <h3>Favorite Sites</h3>
setOutput += "\">" +siteSets[i][0]+ "<\/a> <br>";

for (var u = 1; u < siteSets[i].length; u++) {
setOutput += "<a href=\"http://" +siteSets[i][u]+ "\" title=\"" +siteSets[i][u]+ "\" target=\"_blank\"><img src=\"http://g.etfv.co/http://" +siteSets[i][u]+ "\" alt=\"" +siteSets[i][u]+ "\" width=\"16\" height=\"16\"></a> ";
setOutput += "<a href=\"http://" +siteSets[i][u]+ "\" title=\"" +siteSets[i][u]+ "\" target=\"_blank\"><img src=\"http://g.etfv.co/http://" +siteSets[i][u]+ "\" alt=\"" +siteSets[i][u]+ "\" width=\"" +faviconSize+ "\" height=\"" +faviconSize+ "\"></a> ";
};
setOutput += "</li>";

Expand Down

0 comments on commit dbee5ff

Please sign in to comment.