Updating rotating sponsor logos on home page

From OSGeo
Revision as of 02:06, 12 March 2016 by Wiki-Ian (talk | contribs) (Created page with "Updating the rotating logos on the home page currently requires admin privileges to edit the required block and then some basic knowledge of javascript to do the update. 1. E...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Updating the rotating logos on the home page currently requires admin privileges to edit the required block and then some basic knowledge of javascript to do the update.

1. Edit the block containing the logos: /admin/build/block/configure/block/9

2. At the bottom of the code, add/remove the path of logo in the `logos` array:

 var logos = [
   "/sites/osgeo.org/files/Page/GeoCat.svg",
   "/files/sponsors/thinkwhere_logo.png",
   "/sites/osgeo.org/files/images/chameleon-john-logo.png"
 ];
 var logoNum = Math.floor((Math.random() * logos.length));
 document.getElementById('idRotatingLogo').src = logos[logoNum];

The logos are cycled randomly.

This process is intended to be fairly temporary - in the future the logos should just be picked up automatically from a view.