You are not logged in.
I would add something to the docs about how to actually output the variables, it was not immediately clear.
Also, you could describe it as site-wide or global custom fields, might help new users grok it.
Thanks for the plugin :)
Offline
milkshake wrote:
I would add something to the docs about how to actually output the variables, it was not immediately clear.
Also, you could describe it as site-wide or global custom fields, might help new users grok it.
Thanks for the plugin :)
Hi William, glad you find adi_variables useful.
Because variables are a built-in feature of Textpattern their usage is probably best left to the official documentation.
Offline
Hello,
I have a little problem with this plugin.
I made a variable named totpages : <txp:variable name=“totpages” value=“0” />
Then I do this :
<txp:if_different>
<txp:variable name=“totpages” value=’<custom_field name=“pagenr”/>’ />
</txp:if_different>
But when i do this :
<txp:output_form form=“adi_variables” />
on any place where on the page no output
What have I done wrong ?
Roelof
Offline
roelof wrote:
I made a variable named totpages : <txp:variable name=“totpages” value=“0” />
Variables for use by adi_variables should be set in the Variables tab under Content. Is this where you set “totpages”?
Then I do this :
<txp:if_different> <txp:variable name=“totpages” value=’<custom_field name=“pagenr”/>’ />
</txp:if_different>
You don’t really need adi_variables if all you’re are doing is using a variable as a counter or flag. In this case just initialise “totpages” where you need to use it.
But when i do this :
<txp:output_form form=“adi_variables” />on any place where on the page no output
The <txp:output_form> code simply runs a series of <txp:variable> tags from the “adi_variables” form, so it doesn’t generate any output. It should be executed at the top of the page. You can check to see if the “adi_variables” form exists & what it contains. With regards to the <txp:if_different> code above, I can’t really comment on why it is or isn’t working.
Offline
Oke,
Then I have to look for another way to check the values of a variable.
Thank you for the help.
Roelof
Offline
roelof wrote:
Then I have to look for another way to check the values of a variable.
<txp:if_variable> any good to you?
Offline
Hello,
I know that one.
What I mean is that I have to print some variables so I can debug a script im testing now.
Roelof
Offline
Hello,
Thank you.
I now can see that the script is not working,
So back to the drawing table.
Roelof
Offline