PermitTempPdf and Conditional Shortcode
PermitTempPdf command Shortcode
The use of permittemppdf is fairly straight forward.options
The shortcode has two different arguments it can accept to change the information it will output: permit and vehicle.
Permit
Shortcode format:
- [permittemppdf permit=______]
barcode,
The lotname,options location,to fill the blank space are:
- barcode
- permitno
- lotshortname
- lotname
- location
- expiry
Expiry will show a snippet of html that is not editable because of the complexity of the expiry information.
Vehicle
Shortcode format:
- [permittemppdf vehicle=______]
plate,
The colour,options make,to fill the blank space are:
- plate
- guest
- year
- colour
- make
- type
Conditional commandShortcode
ConditionalThe conditional shortcode is somewhat complex.
It will only work with shortcodes I'vethat have been set it up for. Right nownow, that only includes the permittemppdf one.shortcode.
The formats that can be used are as follows:
- [conditional var=****** test=!!!!!!!!]CONTENT[/condtional]
or - [conditional var=****** test=!!!!!!!! value=__________]CONTENT[/condtional]
It
This will test the value of ******. If it'sthe value is a success, then it showswill show the CONTENT.
The options for var currently are:permittemp and permit
- permittemp
- permit
ToFor example, to test if there are hours on a temp permitpermit, youthe value would usebe: var=permittemp.hoursIt's
This is the variable name Ithat havehas been defined (permittemp) and the case case-sensitive column you want to check.return the information of.
The second argument "test" can take the following values:
- hasvalue = if not empty or false, returns true
- true = if the variable is a boolean true. i.e. 1, true, "true"
- false = if the variable is a boolean false.
- true = if the variable is a boolean true. i.e. 1, true, "true"
- eq or equal = if the variable matches the contents of "value"
- ne, neq or notequal = if the variable does not match the contents of "value"