The support forum is temporarily read-only. For urgent requests, please email contact[at]psyberia.net

I want to define parameters

It's all about maps...
Post Reply
baegas
Posts: 9
Joined: Tue Apr 28, 2020 12:23 pm

I want to define parameters

Post by baegas »

Hello!

Code: Select all

<![CDATA[http://api.mapbox.com/styles/v1/mapbox/light-v10/12345789/{z}/{x}/{y}]]>
If there is an online map like the one above, the number 123456789 changes once a month.

The URL that changes once a month is

Code: Select all

http://api.mapbox.com/styles/v1/mapbox/@2x.png?mt=kb.bbb.vv
If it's like this

Code: Select all

<![CDATA[http://api.mapbox.com/styles/v1/mapbox/light-v10/???/{z}/{x}/{y}]]>
/???/ How can I define this part as parameters?
Psyberia-Support
Site Admin
Posts: 6408
Joined: Wed Apr 14, 2010 9:41 pm

Re: I want to define parameters

Post by Psyberia-Support »

Hi,
If I correctly understand, you want to define a parameter, using the text that come from a remote URL?
Right now this is not possible.
I'm not sure if I will be able to work on this, this is very specific, I guess for this map only. When does the app is supposed to update the parameter value?

I think the solution using what is existing is to use a static parameter at the start of the file (before the first <source>):

Code: Select all

<param name="kb-bbb-vv">12345789</param>
Then use is like this in your map:

Code: Select all

<![CDATA[http://api.mapbox.com/styles/v1/mapbox/light-v10/{$param:kb-bbb-vv}/{z}/{x}/{y}]]>
And once in a while edit the variable value with your text editor.
Do you like AlpineQuest ? Leave a small comment on Google Play !
baegas
Posts: 9
Joined: Tue Apr 28, 2020 12:23 pm

Re: I want to define parameters

Post by baegas »

Hello

thanks for the kind reply
It's a pity that it's not supported, but I think it's okay to use static parameters.
Thank you again
Have a nice day
Post Reply