I want to get the pageId in the "Site Code" so that I can use it in $w(pageId) to get certain properties and change/add objects in the page accordingly. I was unable to find a solution to do that in the "Site Code". Is there anything like $w(this), $w(Page) or $w(_self)?
Also I was unable to pass a variable from the "Page Code" to the "Site Code" which might be a longer solution but would still work.
If anyone has a solution to share that would be great.