You are not logged in.

Dear visitor, welcome to krpano.com Forum. If this is your first visit here, please read the Help. It explains in detail how this page works. To use all features of this page, you should consider registering. Please use the registration form, to register here or read more information about the registration process. If you are already registered, please login here.

jordi

Intermediate

  • "jordi" started this thread

Posts: 465

Location: Barcelona

Occupation: creating ideas & coding them

  • Send private message

1

Thursday, June 25th 2015, 12:04pm

include a variable file

I just check it and did not work :

<include url="calc:'%HTMLPATH%/some-folder/' + variable + '/your.xml' " />


should it be possible with calc ?

with a variable that has been defined before xml parsing...
everpano.com step beyond 360

2

Friday, June 26th 2015, 7:29am

Hi,

yes, that should work (at least in the next 1.19 pre-release 3, but I'm not sure about the pre-release 2 yet).

An alternative would be:

Source code

1
<include url="%HTMLPATH%/some-folder/%$variable%/your.xml" />


Best regards,
Klaus

jordi

Intermediate

  • "jordi" started this thread

Posts: 465

Location: Barcelona

Occupation: creating ideas & coding them

  • Send private message

3

Friday, June 26th 2015, 10:06am

None of both ways are able to resolve the variable.
everpano.com step beyond 360

Posts: 1,850

Occupation: Virtual Tours - Photography - Krpano developer

  • Send private message

4

Friday, June 26th 2015, 5:52pm

I think the variable must be set in the embed. Although, I don't see much purpose it can have except for passed query parameters.
KRPano Developer: Portfolio ::Gigapixel Tagging Solutions - Porfolio 2 :: Facebook :: Twitter :: reddit.com/r/VirtualTour

5

Friday, June 26th 2015, 8:22pm

Hi,

the 'variable' would need to be set before the xml parsing. That means before the loadpano() call or when embedding, then by using the 'initvars' setting (the normal vars will be passed after the xml parsing). Since version 1.19 it's also possible the pass the initvars via query parameters.

See here:
http://krpano.com/docu/html/#initvars

Best regards,
Klaus

jordi

Intermediate

  • "jordi" started this thread

Posts: 465

Location: Barcelona

Occupation: creating ideas & coding them

  • Send private message

6

Monday, June 29th 2015, 12:39pm

Ouuxx, my mistake was the vars & initvars, I just had in mind that with vars thery were defined before.

Now it's solved thanks
everpano.com step beyond 360