On Jun 18, 8:49 pm, Paul Howell <[EMAIL PROTECTED]> wrote:
> Christoph Zwerschke wrote:
> > aspineux schrieb:
> >> but after moving my apps into path "/my_app" I have to update all
> >> my href= and src= using tg.url.
> >> <img src="${tg.url('/static/images/logo.png')}" alt="logo"/>
> >> But this make my template editing more painful, because images are
> >> missing !
>
> > What you can do with Kid is the following:
>
> > <img src="../static/images/logo.png"
> > py:attrs="src=tg.url('/static/images/logo.png')"/>
>
> > Not nice but it works.
>
> > -- Chris
>
> Chris, all,
>    Good point, thanks.  Personally, I think this is a GOOD (ie., NICE)
> solution.  I tend to use the py:attrs approach routinely in place of
> using ${var} in <A>, <IMG> attributes.  It's cleaner and ignored by
> WYSIWYG editors.

I like your definition of cleaner:

<img src="../static/images/logo.png" py:attrs="src=tg.url('/static/
images/logo.png')"/>
vs
<img src="../static/images/logo.png"/>
:-)

Yes I know that I'm old user of Zope ZTP. Their is no ${} and no
embeded python into ZPT
.
I was just "exploring" a different way to do thing.
Python make things easier for the developer whatever the complexity
for the code behind.
I was suggestion to make KID more complex to  make developer work more
natural, IMO.

Regards


> Paul


--~--~---------~--~----~------------~-------~--~----~
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?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to