Get BodyId value in an extension
How would I get the contents of the BodyId variable so that I could decide what to do depending upon what page I was on? I specifically need to identify what body tag id I am on.
0
This discussion has been closed.
Comments
Edit: The global reference was empty, too. What would I need to add?
function GetBodyID(&$Head) { $Head->Contex->PassThroughVars['BodyId'] = &$Head->BodyId; } $Context->AddToDelegate('Head', 'PreRender', 'GetBodyID');
and then wherever you are, you should be able to
$BodyID = &$Context->PassThroughVars['BodyID'];