[LON-CAPA-users] Finding page title
Thu, 25 Jan 2007 13:37:39 -0500
Oh, I didn't catch the second parameter. Duh, I thought you were just
indicating another first parameter that could be used.
This sounds great, and makes sense - I will try it tonight.
-----firstname.lastname@example.org wrote: -----
From: Guy Albertelli II <email@example.com>
Sent by: firstname.lastname@example.org
Date: 01/24/2007 09:17PM
Subject: Re: [LON-CAPA-users] Finding page title
> An author's directory listing shows
> Name Title
> EmptyJudge.page Empty Judge 12
> consists of
> EmptyProb.problem [untitled]
> JudgeCheck.problem Play Judge Check
> In the Course Documents/Administrative folder, EmptyJudge.page is
> and renamed to
> Empty Judge 15
> (the 12 and 15 are just random numbers so I can distinguish what title I
> Goal: I want to get "Empty Judge 15", the title the student sees at the
> of the page.
> resource.title gives Play Judge Check, the title of the current problem
> resource.map (and resource.map.title, resource.map.name,
> resource.map.displaytitle, resource.map.map.title, resource.map.map.name,
> resource.map.map.displaytitle, resource.map.garbage) gives
> Apparently once I say resource.map, it doesn't matter what I append to
Did you try
$map_title = &EXT('resource.title',&EXT('resource.map'));
as I suggested?
(What is going on here is
- by default &EXT() returns information about the resource it is
- you want to get information about a different resource (not the
.problem but the .page container)
- To do this you can give &EXT() a second argument that specifies what
resource you want the information about
- To specify a separate resource you need the internal name for the
resource (we call that the symb) you can either get that from DOCS
(there is button that will give you all of the symbs in the course)
or you can ask.
- &EXT('resource.map') returns the internal name of the
map that contains the resource that called &EXT()
$symb_of_the_page = &EXT('resource.map');
$title_of_the_current_resource = &EXT('resource.title');
$title_of_the_page_this_resource_is_in = &EXT('resource.title',
And if we want to go up another level:
$symb_of_the_map_the_page_is_in = &EXT('resource.map',$symb_of_the_page);
> map.anything returns blank.
> So, close but no cigar. I still can't quite get the "Empty Judge 15"
> into my script.
> -----email@example.com wrote: -----
> To: firstname.lastname@example.org
> From: Guy Albertelli II <email@example.com>
> Sent by: firstname.lastname@example.org
> Date: 01/24/2007 04:52PM
> Subject: Re: [LON-CAPA-users] Finding page title
> Hi Brew,
> > Within a problem on a page, I am trying to retrieve the name of the
> > have spent several hours now trying various combinations of &EXT()
> > with no luck.
> > Structure is:
> > myPage.page has a title of "My Page"
> > contains problem1.problem
> > problem2.problem
> > problem2 needs to obtain the string "My Page".
> Let me know if any of that needs explaining...
> I'll likely try to work on the ext_examples.problem more to get more
> complete documentation in there...
> > I thought I should be able to use displaytitle somehow,
> Hmm, I could add something like <displaytitle level="1" /> or
> maybe <displaytitle resource="...symb or url..." />
> email@example.com 0-7-0-9-27,137
> LON-CAPA-users mailing list
> LON-CAPA-users mailing list
LON-CAPA-users mailing list