Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add option to specify parameters in stylesheet.xml #6

Closed
ustroetz opened this issue May 21, 2014 · 5 comments
Closed

Add option to specify parameters in stylesheet.xml #6

ustroetz opened this issue May 21, 2014 · 5 comments
Assignees

Comments

@ustroetz
Copy link

I like to run a query inside my stylesheet to get a certain feature from my database. It would be nice if I could specify a parameter (e.g. an ID) that will be used inside the function in the Style-sheet.

@Zverik Zverik self-assigned this May 21, 2014
@Zverik
Copy link
Owner

Zverik commented May 21, 2014

Great idea, I would need that for my stylesheet also, e.g. for specifying a GPX trace location.

@Zverik Zverik closed this as completed in 65a382e May 21, 2014
@Zverik
Copy link
Owner

Zverik commented May 21, 2014

I've added variables in format ${name:default} (or simply ${name} for required variables). To process them, use --vars name1=value1 name2=value2 option, or --vars without keys to use default values. Special characters in values (not default) are xml-screened, so do not enclose variables in CDATA.

Please test this, in case I missed some obvious bug or use-case.

@ustroetz
Copy link
Author

Test it and it works wonderful! Thanks a lot Zverik for implementing this so quickly. Btw great tool. Saved me a ton of work :)

@ustroetz
Copy link
Author

Zverik, can you please make an account on GITTIP? My boss would like to donate some money to you for building this feature for us so quickly.

@Zverik
Copy link
Owner

Zverik commented May 22, 2014

I didn't know about this service :) Just signed up, thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants