Thanks for your response.  Sorry I think from my most likely
inadequate explaintion you misunderstood my problem.  It actually was
some sort of wierd caching thing... apparently the change made to a
template that is used for layout does not show up unless I stop the
included web server(Ctrl-C to the python start-project.py command).
Once I stop the server and start it again it shows up fine... which is
wierd because it restarts on almost all other changes to regular *.py
files.  I know it doesn't restart when a regular *.kid file is changed
but that change still shows up when the template gets included in a
controller because I think it knows to recompile it.  So my point is
if you are using py:layout you have to manually restart the server
when you make changes during development.  As far as I can tell.

So more specifically I was trying to include a py:def="myFunction()"
and then call it but the call py:replace="myFunction()" wasn't being
recognized because I added that line it after I had started the
server.

 I'll try to recreate the problem again later to triple check that it
wasn't something else wierd going on.

  -Ian

On 9/28/06, Kevin Dangoor <[EMAIL PROTECTED]> wrote:
>
> On Sep 28, 2006, at 9:18 PM, Ian Wilson wrote:
>
> >
> > My battle against technology continues...
> >
> > This probably isn't turbogears specific but I never know.
> >
> > I am trying to use the fancy py:layout but it isn't working.
> >
> > I have two templates layout.kid and product.kid.  I have product.kid
> > using py:layout="'layout.kid'" and I can tell its working(for regular
> > html and matching tages) but I have a function pageSpecificJavascript
> > defined in product.kid that I want to call in layout.kid.  It is doing
> > nothing...actually <?python ?> code isn't even being executing in the
> > layout file.  Is this normal? And if not does anyone else actually
> > have this working?
>
> Yes, this is normal. templates that you extend *only* bring in
> py:defs and py:matches.
>
> <div py:def="pageSpecificJavascript()">
> <script type="text/javascript"><![CDATA[
> ...
> ]]></script>
> </div>
>
> Kevin
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"TurboGears" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/turbogears
-~----------~----~----~----~------~----~------~--~---

Reply via email to