def flatpages_link_list(request):
 from django.contrib.flatpages.models import FlatPage
 link_list = [(page.title, page.url) for page in FlatPage.objects.all()]
 return render_to_link_list(link_list)

def flatpages_link_list ( request ) : from django . contrib . flatpages . models import FlatPage link_list = [ ( page . title , page . url ) for page in FlatPage . objects . all ( ) ] return render_to_link_list ( link_list )
returns a httpresponse whose content is a javascript file representing a list of links to flatpages .