[Radiant] page attachments

2009-04-16 Thread Steven Southard

Why doesn't page attachments show up in snippets?


Steven
___
Radiant mailing list
Post:   Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant


Re: [Radiant] page attachments

2009-04-16 Thread Mohit Sindhwani

Steven Southard wrote:

Why doesn't page attachments show up in snippets?


Because it attaches to a Page?

Cheers,
Mohit.
4/17/2009 | 2:45 AM.

___
Radiant mailing list
Post:   Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant


Re: [Radiant] page attachments

2009-04-16 Thread Andrew Neil

Steven,

Attachments can be inherited from parent pages. So if you attach an  
image to your Home page, then it will be available to all pages,  
layouts and snippets.


Page attachments is a bit fussy: when you ask for a file that doesn't  
belong to the current page (or its ancestors) it raises an exception.  
It could be dangerous if you were to call r:attachment  
name=image.jpg/ in a snippet or layout. If that snippet/layout was  
called from a page which didn't have image.jpg attached, and nor did  
any of its ancestors, then an exception would be raised, and the page  
would not render. However, if you attached a image.jpg file to the  
home page, then it would be available to every page in the site, and  
the problem above would be avoided.


Of course, you could attach an image.jpg file to any section. Then  
that section, and all its ancestors would use that file instead of the  
one attached to the home page.


Does that make sense? The inheritance mechanism means that you can  
treat page attachments in a similar fashion to page parts. When you  
look at it that way, it should no longer seem necessary to be able to  
attach files to snippets and layouts.


Cheers,
Drew


On 16 Apr 2009, at 21:50, Steven Southard wrote:

You mean because the name is page attachments?  I think it'd be  
convenient to locate attachments in snippets too.  Snippets need  
images just as much at pages.  If a snippet had images maybe pages  
wouldn't need quite as many.  I guess, next your going to tell me  
layouts don't need attachments either.  Sure would be convenient.


Steven


On Apr 16, 2009, at 1:45 PM, Mohit Sindhwani wrote:


Steven Southard wrote:

Why doesn't page attachments show up in snippets?


Because it attaches to a Page?

Cheers,
Mohit.
4/17/2009 | 2:45 AM.

___
Radiant mailing list
Post:   Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant


___
Radiant mailing list
Post:   Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant


___
Radiant mailing list
Post:   Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant


[Radiant] filters on layouts

2009-04-16 Thread Steven Southard

Why aren't filters available on layouts?


Steven
___
Radiant mailing list
Post:   Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant


Re: [Radiant] filters on layouts

2009-04-16 Thread Mohit Sindhwani

Steven Southard wrote:

Why aren't filters available on layouts?


That I would like!

Cheers,
Mohit.
4/17/2009 | 8:13 AM.

___
Radiant mailing list
Post:   Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant


Re: [Radiant] filters on layouts

2009-04-16 Thread N. Turnage

Mohit Sindhwani wrote:

Steven Southard wrote:

Why aren't filters available on layouts?


That I would like!


Have you tried using templates? Since I started using them I don't build 
a site without templates anymore.




~Nate
___
Radiant mailing list
Post:   Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant


Re: [Radiant] page attachments

2009-04-16 Thread Steven Southard

inherited from parent pages

Yeah that makes perfect sense and I'm glad I understand it now.

That's useful information.  Anyone using textile editor?  It's pretty  
cool but I was thinking the add image could use a little souping up.   
It'd be nice if when you selected attachments it'd show all the  
attachments that it inherits.  Does that sound useful to anyone else?   
I keep going back and forth in which is better attachments or  
paperclipped they both are very useable and surprisingly different.




Steven


On Apr 16, 2009, at 5:40 PM, Andrew Neil wrote:


Steven,

Attachments can be inherited from parent pages. So if you attach an  
image to your Home page, then it will be available to all pages,  
layouts and snippets.


Page attachments is a bit fussy: when you ask for a file that  
doesn't belong to the current page (or its ancestors) it raises an  
exception. It could be dangerous if you were to call r:attachment  
name=image.jpg/ in a snippet or layout. If that snippet/layout  
was called from a page which didn't have image.jpg attached, and  
nor did any of its ancestors, then an exception would be raised, and  
the page would not render. However, if you attached a image.jpg  
file to the home page, then it would be available to every page in  
the site, and the problem above would be avoided.


Of course, you could attach an image.jpg file to any section. Then  
that section, and all its ancestors would use that file instead of  
the one attached to the home page.


Does that make sense? The inheritance mechanism means that you can  
treat page attachments in a similar fashion to page parts. When you  
look at it that way, it should no longer seem necessary to be able  
to attach files to snippets and layouts.


Cheers,
Drew


On 16 Apr 2009, at 21:50, Steven Southard wrote:

You mean because the name is page attachments?  I think it'd be  
convenient to locate attachments in snippets too.  Snippets need  
images just as much at pages.  If a snippet had images maybe pages  
wouldn't need quite as many.  I guess, next your going to tell me  
layouts don't need attachments either.  Sure would be convenient.


Steven


On Apr 16, 2009, at 1:45 PM, Mohit Sindhwani wrote:


Steven Southard wrote:

Why doesn't page attachments show up in snippets?


Because it attaches to a Page?

Cheers,
Mohit.
4/17/2009 | 2:45 AM.

___
Radiant mailing list
Post:   Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant


___
Radiant mailing list
Post:   Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant


___
Radiant mailing list
Post:   Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant


___
Radiant mailing list
Post:   Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant


Re: [Radiant] page attachments

2009-04-16 Thread Mohit Sindhwani

HI Steven

Steven Southard wrote:
You mean because the name is page attachments?  I think it'd be 
convenient to locate attachments in snippets too.  Snippets need 
images just as much at pages.  If a snippet had images maybe pages 
wouldn't need quite as many.  I guess, next your going to tell me 
layouts don't need attachments either.  Sure would be convenient.


I'm sorry if my answer came across as rude/ mean (cut me some slack - it 
was sent at 2:45AM) - I didn't mean just the name.  I meant to imply 
that it attaches to pages and is designed for that, while snippets often 
are included in multiple pages and may have different contexts.  (I have 
some times used a single known page as the base referred from snippets).


But definitely the explanation that followed my email was better!

Cheers,
Mohit.
4/17/2009 | 1:03 PM.

___
Radiant mailing list
Post:   Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant