I would like to create a view where the argument validates that the file path of the node that the current user is looking at = the current url being viewed.

I have a core profile field that I use in pathauto to generate the path to the user profile page. I.E. a core profile field labeled url with value = abc

so the path to that users profile page would be http://mysite.com/abc

I would like to create a view that shows the visitors to that page and filters out all the other pages the visitors visited outside of that page when the user is looking at that particular profile page.

I was previously using the argument access log: page title = username. This filtered all the other pages the visitor visited and only showed the visits where the page title was the user name. The page title of the core user profile is the user name so the view only showed visits to the current user profile page being viewed.

However, I have enabled the realname module and now the page title of the user profile page is not the user name but the realname which is not unique thus can't be used.

That's why I created a unique profile field labeled url and set that as a path to the profile page. Now I need a php code snippet to make the new argument work where the file path for the visited page must equal the current file path that the user is viewing i.e. the user profile page path http://mysite.com/abc

Can anyone provide me with a php code snippet to use in the file path argument?

Edited by WorldFallz - reverted empty post to original content.

Comments

WorldFallz’s picture

Please don't abuse edit privileges to wipe out posts-- we don't delete content on drupal.org. The best way to handle solved threads is to post your solution for the future reference of other users. Thanks.