[ckan-dev] customize homepage ckan

Hildegard Gerlach hildegard.gerlach at jrc.ec.europa.eu
Wed Dec 11 12:06:18 UTC 2013


Hi Aaron,

thanks a lot. This was a great help to get easily some nice results.

Hilde

On 12/9/2013 12:59 AM, Aaron McGlinchy wrote:
> Hi Hilde,
>             I too am a bit of a novice when it comes to css etc.  I have found with the help of people on here some ways to customise my front screen using the 'custom css' box in the sysadmin| config section (code appended below).
>
> You could copy and paste this code in, and change the paths to image files to suit yourself.  The image "LCR-ckan-homepage-background.jpg" is loaded into our CKAN install, but the others are just borrowed from our public website (so they will work for you as a test).  Depending on your images you might want to tweak the height, padding etc settings.  I found that IE and Firefox render things slightly differently, so experimented to get values that looked OK in both.
>
> Unfortunately our install has crashed at the moment, so I can't point you to see what it looks like.
>
> Regards
> Aaron
>
> .hero { background: lightsteelblue; }
> .hero { background-image: url("/base/images/LCR-ckan-homepage-background.jpg");}
>
> /* Remove the feature image */
> div.hero-primary section.featured.media-overlay {
> display: none;
> }
> /* Style up front page */
> div.hero-primary header {
> background-image: url(http://www.landcareresearch.co.nz/__data/assets/image/0015/15504/6-Measuring-Biodiversity.jpg);
>
> background-size: cover;
> background-repeat: no-repeat;
> background-position: center;
> height: 185px; /* 185 = works in both IE and Firefox, 250=good, 264=height of main background image */
> padding-top: 24px; /* originally was 42, but 24 works better in IE at height 185 */
> padding-bottom: 24px;
> border-radius: 3px;
> font-size: 1.3em;
> font-weight: bold;
> color: white;
> text-shadow: 2px 2px 2px black;
> text-align: center;
> }
>
> Today's Topics:
>
>     2. customize homepage ckan (Hildegard Gerlach)
>
> ----------------------------------------------------------------------
>
> Message: 2
> Date: Thu, 05 Dec 2013 10:41:14 +0100
> From: Hildegard Gerlach <hildegard.gerlach at jrc.ec.europa.eu>
> To: ckan-dev at lists.okfn.org
> Subject: [ckan-dev] customize homepage ckan
> Message-ID: <52A04A3A.5090001 at jrc.ec.europa.eu>
> Content-Type: text/plain; CHARSET=US-ASCII; format=flowed
>
> Dear all,
>
> I would like to add some cutomization to our CKAN home page without too much commitment. I would like to something similar to http://data.codeforhouston.com/ http://data.kk.dk/
>
> I am  not really confident in writing css and don't know where to start.
> Is there an easy way to at least substitute the placeholder.it and background-tile.png ?
>
> Thanks
>
> Hilde
>
>
> ------------------------------
>




More information about the ckan-dev mailing list