[ckan-discuss] Adding other static pages (besides About)

Brian Lee Yung Rowe rowe at muxspace.com
Thu Aug 29 17:05:41 BST 2013


David,

Thanks for your response. There's a lot going on in that project, but I think I see what needs to be done. It's basically overriding 
    def after_map(self, map):
        map.connect(
            'guidelines', '/guidelines',
            controller='ckanext.canada.controller:CanadaController',
            action='view_guidelines'
        )
        return map
and the corresponding controller, yes? I guess the other question is whether it would be easy to hook the editing of the copy into the same screen where you can edit the contents of the About page?

Warm Regards,
Brian



On Aug 29, 2013, at 11:45 AM, David Read <david.read at hackneyworkshop.com> wrote:

> Brian,
> 
> Yes you'll need to make an extension. You can probably still bits of
> that Canadian one. The page needs a URL (route) that points to a new
> controller which calls a template. Create your template in Jinja and
> ensure its file folder is added to the template folders.
> 
> It should be pretty future proof for the foreseeable AFAIC. If you'd
> written this 2 years ago it would still work now on the latest CKAN.
> 
> Docs: http://docs.ckan.org/en/latest/writing-extensions.html
> 
> David
> 
> On 29 August 2013 16:24, Brian Lee Yung Rowe <rowe at muxspace.com> wrote:
>> Hello,
>> 
>> I'm a new CKAN user and would like to make some customizations to the default installation. Is there a standard way of adding additional static pages to a CKAN site? One approach I found based on data.gc.ca is to create an extension, but it wasn't clear to me how to access a view or controller that wouldn't be susceptible to breakage after a CKAN release. Any suggestions or links to documentation are appreciated.
>> 
>> Warm Regards,
>> Brian Rowe
>> 
>> 
>> 
>> _______________________________________________
>> ckan-discuss mailing list
>> ckan-discuss at lists.okfn.org
>> http://lists.okfn.org/mailman/listinfo/ckan-discuss
>> Unsubscribe: http://lists.okfn.org/mailman/options/ckan-discuss

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.okfn.org/pipermail/ckan-discuss/attachments/20130829/3af1ce45/attachment.htm>


More information about the ckan-discuss mailing list