Former Member
inherit
guest@proboards.com
259598
0
Nov 27, 2024 1:54:30 GMT -8
Former Member
0
January 1970
Former Member
|
Post by Former Member on Sept 30, 2021 13:09:39 GMT -8
Hi How can I find route name of some page for example techdot.proboards.com/user/1/activity I have sidebar redux plugin so I need to remove It from user profile,but I need route name so I can do that.
|
|
inherit
Official Code Helper
65613
0
1
Oct 22, 2024 1:56:19 GMT -8
Chris
"'Oops' is the sound we make when we improve"
9,018
December 2005
horace
RedBassett's Mini-Profile
|
Post by Chris on Sept 30, 2021 15:36:06 GMT -8
{ "name": "show_user_activity", "params": { "user_id": "1" } } You can open your browser's developer console and type pb.data('route') to get that info. You should however be aware that the route on a page can change if an action is performed that generates an ajax response. So for example, opening the participated threads dialog or liking a post will change the route accordingly and no longer reflect the route that originally brought you to the page. This is why it is advised you save this to a variable in your code when the page first loads so you have access to it later should it change. Alternatives I've used in the past is to add the route directly in the wrapper of the theme in your test forum to see the route on every page. A broader solution would be to type [*] javascript:alert(JSON.stringify(pb.data('route'),null,2)) in the address bar on any page to see the route. You could even add that to a bookmark for a quick one-click process.
|
|
Former Member
inherit
guest@proboards.com
259598
0
Nov 27, 2024 1:54:30 GMT -8
Former Member
0
January 1970
Former Member
|
Post by Former Member on Sept 30, 2021 16:27:57 GMT -8
{ "name": "show_user_activity", "params": { "user_id": "1" } } You can open your browser's developer console and type pb.data('route') to get that info. You should however be aware that the route on a page can change if an action is performed that generates an ajax response. So for example, opening the participated threads dialog or liking a post will change the route accordingly and no longer reflect the route that originally brought you to the page. This is why it is advised you save this to a variable in your code when the page first loads so you have access to it later should it change. Alternatives I've used in the past is to add the route directly in the wrapper of the theme in your test forum to see the route on every page. A broader solution would be to type javascript:alert(JSON.stringify(pb.data('route'),null,2)) in the address bar on any page to see the route. You could even add that to a bookmark for a quick one-click process. Thank you so much,it works,
|
|