Page 1 of 1

Get page name javascript

Posted: Sun Apr 27, 2014 12:11 am
by anon

How do I use an Appery call to get the current page name so that I can create logic for pagination using Appery(myPage, {});


Get page name javascript

Posted: Sun Apr 27, 2014 2:56 am
by Illya Stepanov

Hi -

You can try something like this:
precode
var pagePathName= window.location.pathname;
return pagePathName.substring(pagePathName.lastIndexOf("/") + 1);
/code/pre


Get page name javascript

Posted: Wed Feb 11, 2015 2:39 pm
by Walter Zielony

Apperyio.CurrentScreen seems to do the trick also.


Get page name javascript

Posted: Wed Feb 20, 2019 1:20 pm
by Fernando

When testing in the mobile web test emulator only works Apperyio.CurrentScreen
The other code shows my default start page but not current page in the emulator.


Get page name javascript

Posted: Wed Feb 20, 2019 5:03 pm
by Serhii Kulibaba

Hello,

What project type do you use JQM or Ionic?
Could you please specify do you need any assistance with it?