I've spent some time with the book recommend as well as other tutorials on Python. My question here is directly related to Chapter 7 of the Tutorial/Definative guide to Django, which does not seem to provide a comprehensive list of imports for the code for doing a data search it works the reader through.
The snag I hit and possibly other people hit, Where the book says from django.db.models import Q from django.shortcuts import render_to_response from mysite.books.models import Book # The book omits from django.template.loader import get_template Now this can be an assumption that it is loaded earlier. Yet working through the book I don't see anywhere that is mentioned. __So to rephrase my questions * Does Django assume that certain modules are loaded? * Does the tutorial assume certain modules are loaded? And if so -- what modules are these and where is this stated? On Sep 26, 5:07 pm, Håkan Waara <[EMAIL PROTECTED]> wrote: > from django.template.loader importget_template > > I recommend learning some general python before you dive into django. > There are lots of great sites for this, for examplewww.diveintopython.org > > /H > > 26 sep 2008 kl. 15.44 skrev NoviceSortOf: > > > > > this works > > >>>> from django.template import loader > >>>> loader.get_template('myfile.html') > > > but how do i get this syntax to work? > > >>>>get_template('myfile.html') > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---