Hi Andrew,

Thank you for replying, I've been looking through the extensions as  
you say, but can't really see anything close enough to what I want to  
do in this particular case (from my limited knowledge). I think one of  
the closest is perhaps Author, where the ID of the author name gets  
entered in to the page table under the created_by column and the  
Author Name gets returned from the ID on the pages table by it tag.  
Its the connection between the local id and the foreign name that I  
think I need to look up.

I'm a bit code-blind after all the code I've been looking at and  
learning over the past few day's, however I now think I have to  
investigate associations and belongs_to in order to do the above for  
my extension. If I'm heading down the wrong path someone please tell  
me! Hopefully I'll have a fresh look at it tomorrow, I'm hoping its  
just a simple concept I have yet to digest...

I'm voluntarily building a site for a local theatre company as a  
project to learn ruby/rails/radiant, so I'm learning as I go (in at  
the deep end), the min_age and max_age aren't really connected to the  
other date extension I am doing. This one is just going to be a used  
as an aid to find pages for particular age groups (and to show those  
values on the particular events). I don't think having two values will  
prove to be the final/best solution, as a single multiple select  
option box may be a better method to achieve the same ends, but this  
part is working passably for now.

The previous example which you so kindly helped with was based on  
Sean's great Schedular extension. It adds start and end dates for  
event pages (which are slightly different from publish dates in my  
case), it also enables those values to be displayed on the page and to  
order by them. As the information is stored directly on the page table  
it is relatively easy for me to access it directly, the trouble I am  
currently facing is matching a ID of one thing to a value in a  
different DB table.

If anyone can point a good direction to look at for research that  
would be great.

Thanks once again


On 10 Dec 2007, at 22:41, Andrew O'Brien wrote:

> I'm not quite sure what you're trying to do.  My recommendation is to
> check http://wiki.radiantcms.org/Thirdparty_Extensions for existing
> extensions.  Even if they don't have what you want, there's usually
> some good examples.
>
> Incidentally, are you trying to do something like delayed publishing,
> where a page has to be a certain age before it's visible, and it
> expires after a certain age?  Or am I completely misunderstanding your
> age_min and age_max examples...  If that's what you're trying to do,
> check out the Scheduler extension.
>
> -Andrew
>
> On Dec 10, 2007 6:41 AM,  <[EMAIL PROTECTED]> wrote:
>> Hello again,
>>
>> I'm attempting to write a couple of extensions, and have what is
>> hopefully a quick question.
>>
>> I have an extension that creates a table for age and extends pages
>> with two columns age_min, and age_max. From the edit page I can post
>> the id's of age into age_min and age_max, and from the actual page  
>> can
>> return the values of those id's. However, I would like to return the
>> name value connected to those id's in age and not the actual id  
>> itself.
>>
>> What would be a good example to look at, in order to achieve the  
>> above?
>>
>> Many thanks,
>>
>> Dominic
>> _______________________________________________
>> Radiant mailing list
>> Post:   [email protected]
>> Search: http://radiantcms.org/mailing-list/search/
>> Site:   http://lists.radiantcms.org/mailman/listinfo/radiant
>>
> _______________________________________________
> Radiant mailing list
> Post:   [email protected]
> Search: http://radiantcms.org/mailing-list/search/
> Site:   http://lists.radiantcms.org/mailman/listinfo/radiant

_______________________________________________
Radiant mailing list
Post:   [email protected]
Search: http://radiantcms.org/mailing-list/search/
Site:   http://lists.radiantcms.org/mailman/listinfo/radiant

Reply via email to