Jump to content

How Can I Get the Page Location ID?

Brian A.

Recommended Posts

Want to display some content on globalTemplate, but I am currently stuck on how can I get the page ID.

I know this code is for displaying to pages only, but I need to know how can I get the page ID to only show on that page that I specify.

{{if $location['app'] == 'cms' and $location['module'] == 'pages' and $location['controller'] == 'page'}}
	Content here

If anyone knows how to do this, please reply below.

Link to comment
Share on other sites

Never mind, I did some searching on the community.

In case someone else trying to solve this, add this piece of code at the end of my code:

\IPS\Request::i()->path == 'LOCATION HERE'

Where it says "location here", you will put your location path of where you want the code to be at.

Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...