* Processing URL with TeX macros
@ 2013-05-15 7:23 Jaroslav Hajtmar
2013-05-15 7:40 ` Wolfgang Schuster
0 siblings, 1 reply; 3+ messages in thread
From: Jaroslav Hajtmar @ 2013-05-15 7:23 UTC (permalink / raw)
To: mailing list for ConTeXt users
Hello ConTeXist.
I would like get right URL, when I use \useURL command.
Is there possibilities put any TeX macro to first and second parameter?
It was clear to me why this is about, but I need it for one application
(in the cycle I change URL addresses).
Thanx Jaroslav Hajtmar
Here is my minimal example:
\setupinteraction[state=start]
\def\myurl{http://mydomain.com/path/}
\def\myfile{mypdffile.pdf}
\def\urltext{This is link to my file}
\useURL[okexample][http://mydomain.com/path][mypdffile.pdf][\urltext]
\useURL[problemexample][\myurl][\myfile][\urltext]
\starttext
\from[okexample] -- OK
\from[problemexample] -- link problem
\stoptext
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Processing URL with TeX macros
2013-05-15 7:23 Processing URL with TeX macros Jaroslav Hajtmar
@ 2013-05-15 7:40 ` Wolfgang Schuster
2013-05-15 8:07 ` Jaroslav Hajtmar
0 siblings, 1 reply; 3+ messages in thread
From: Wolfgang Schuster @ 2013-05-15 7:40 UTC (permalink / raw)
To: hajtmar, mailing list for ConTeXt users
Am 15.05.2013 um 09:23 schrieb Jaroslav Hajtmar <hajtmar@gyza.cz>:
> Hello ConTeXist.
> I would like get right URL, when I use \useURL command.
> Is there possibilities put any TeX macro to first and second parameter?
> It was clear to me why this is about, but I need it for one application (in the cycle I change URL addresses).
Why can you change the \def lines but not the \useURL settings, both are set at the begin of the document?
> Thanx Jaroslav Hajtmar
>
> Here is my minimal example:
>
>
> \setupinteraction[state=start]
>
> \def\myurl{http://mydomain.com/path/}
> \def\myfile{mypdffile.pdf}
> \def\urltext{This is link to my file}
>
> \useURL[okexample][http://mydomain.com/path][mypdffile.pdf][\urltext]
> \useURL[problemexample][\myurl][\myfile][\urltext]
\expanded{\useURL[…][…][…][…]}
Wolfgang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Processing URL with TeX macros
2013-05-15 7:40 ` Wolfgang Schuster
@ 2013-05-15 8:07 ` Jaroslav Hajtmar
0 siblings, 0 replies; 3+ messages in thread
From: Jaroslav Hajtmar @ 2013-05-15 8:07 UTC (permalink / raw)
Cc: mailing list for ConTeXt users
Hello Wolfgang.
Thanks for the reply. Now it's even more complicated. I think I need a combination of expanded and unexpanded macros. Both of the following examples do not work quite right.
Thanx Jaroslav Hajtmar
Here is other example:
\setupinteraction[state=start]
\def\myurl{http://mydomain.com/path}
\def\myfile{mypdffile\recurselevel.pdf}
\def\urltext{This is link to my file \recurselevel}
\unexpanded\def\unexpurltext{This is other link to my file \recurselevel}
\expanded{\useURL[problemexample][\myurl][\myfile][\urltext]}
\useURL[otherproblemexample][\myurl][\myfile][\unexpurltext]
\starttext
\dorecurse{5}{
\from[problemexample] \par
}
\blank[big]
\dorecurse{5}{
\from[otherproblemexample] \par
}
\stoptext
Am 15.05.2013 um 09:23 schrieb Jaroslav Hajtmar<hajtmar@gyza.cz>:
> Hello ConTeXist.
> I would like get right URL, when I use \useURL command.
> Is there possibilities put any TeX macro to first and second parameter?
> It was clear to me why this is about, but I need it for one application (in the cycle I change URL addresses).
Why can you change the \def lines but not the \useURL settings, both are set at the begin of the document?
> Thanx Jaroslav Hajtmar
>
> Here is my minimal example:
>
>
> \setupinteraction[state=start]
>
> \def\myurl{http://mydomain.com/path/}
> \def\myfile{mypdffile.pdf}
> \def\urltext{This is link to my file}
>
> \useURL[okexample][http://mydomain.com/path][mypdffile.pdf][\urltext]
> \useURL[problemexample][\myurl][\myfile][\urltext]
\expanded{\useURL[…][…][…][…]}
Wolfgang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-05-15 8:07 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-05-15 7:23 Processing URL with TeX macros Jaroslav Hajtmar
2013-05-15 7:40 ` Wolfgang Schuster
2013-05-15 8:07 ` Jaroslav Hajtmar
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).