Discussions » Demandes de création de scripts

Simple button hyperlink

§
Posté le: 2022-12-01

Good afternoon, I need to make a tampermonkey with a button that allows a certain page that has an id in the URL to redirect to another that also uses said id in the url. Help please it's for work. Example the page is https://backoffice-app.messi.com/#/partners/11111 I need the "11111" to put in https://pedidosya.sa.looker.com/dashboards/26109?Partner+ID=11111&Date+Date=14+day ,where it says ID= .
I need help please, i tried but i cant

§
Posté le: 2022-12-02
Édité le: 2022-12-02

Something like that:

@match https://backoffice-app.messi.com/#/partners/*
...
var path = location.href.split("/");
location.href = `https://pedidosya.sa.looker.com/dashboards/26109?Partner+ID=${path[path.length - 1]}&Date+Date=14+day`

for other questions connect me in Discord: https://discord.com/users/374826718390648833/ or https://discord.gg/sHj5UauJZ4

Poster une réponse

Connectez-vous pour poster une réponse.