It looks like you're new here. If you want to get involved, click one of these buttons!
::Street You are on <<print $activeStreet>>. You can go to: <<for $i to 0; $i lt $houses.length; $i++>> [[$houses[$i].housenumber + " " + $houses[$i].street|House][$activeHouse to $houses[$i]]] <</for>>
::House You are standing in front of <<print $activeHouse.housenumber>> <<print $activeHouse.street>>.
Error: <<print>>: bad evaluation: Cannot read property 'housenumber' of undefined Error: <<print>>: bad evaluation: Cannot read property 'street' of undefined.
Comments
Is there a way I can get around this so it creates the link with the correct value of $i for each link?
You will need to use a <<print>> macro to dynamically create the markup link, the line within your for loop needs to look something like the following: ... notice the usage of single quotes to define each of the String literals, this is to allow the double quotes to be used within the literals.
IOW, you need to capture the value of your index variable when you create the link. You'd do this with the Stupid Print Trick™.
For example: Notes: