Forum Discussion

james_scee's avatar
11 years ago

From inside custom component - working out where I am

Would anyone know how to work out what page type you are on from inside a custom component. There is the coreNode, but if I ask

 

coreNode.nodeType, both board and thread report board

 

I did attempt:

 

<#if coreNode.webUi.url?index_of("/td-p/") != -1>

 

but unfortunately on a thread the url returned is that of the board.

 

any ideas?

 

  • PaoloT's avatar
    PaoloT
    Lithium Alumni (Retired)

    Hi James,

     

    if you are interested in the page you are including the component in, have you tried to use the page context object instead?

    I think interactionStyle and name may suffice for you from what you say.

     

    Cheers,