Vely logo install | documentation | examples | changelog
16.10.0 released May 10, 2023
pf-url

Purpose: Outputs a URL-encoded formatted string.

pf-url [ bytes-written [ define ] <bytes> ] [ to-error ] <format> <expression> [ , <expression> ]...

pf-url is the same as pf-out, except that the output is URL-encoded. This means such output is suited for use in URL parameters.
Examples
Create a URL based on arbitrary strings used as URL parameters - for instance space would be encoded as "%20" in the final output:
@<a href='<<p-path>>/update?val=<<pf-url "Purchased %s for %lld dollars", piece_desc, price>>'>Log transaction</a>

See pf-out for more examples.
See also
Output ( finish-output   flush-output   output_statement   p-dbl   pf-out   pf-url   pf-web   p-num   p-out   p-path   p-url   p-web  )  SEE ALL (documentation)


Copyright (c) 2017-2023 Dasoftver LLC