6 August 2008 at 8:34pm
(Last edited: 6 August 2008 8:37pm),
I've got a problem with the templates again. I'll show you some pseudocode first which should explain my Problem:
<% control MyControl %>
<% end_control %>
Of course the code looks for the SQL Field called MySQLField.jpg which is not existant since it's called MySQLField. So my question is, is there something like an escape-symbol (or whatever it's called, sorry ;)) which helps me with just looking up the MySQLField and add a '.jpg' behind?
6 August 2008 at 9:00pm
I've got a Field in a DataObject Table which contains a number, additionally there is a folder which has several image files in there called (for example) "123456789.jpg". The number itself is actually a ISBN and the pictures are book titles (related to the ISBN). So I grab the ISBN out of the database and look up the book picture called "$isbn.jpg".
6 August 2008 at 9:40pm
I already got a working relation to the books, my problem is just that "$ISBN.jpg" doesn't work, since there is no Field called "ISBN.jpg" or function called "jpg". "$ISBN .jpg" works, "($ISBN).jpg" works, "$ISBN\.jpg" works etc.
Think of the ".XML" function, you can use something like "$Content.XML" ect. but there is no ".jpg" in the core. I just found a solution
<img src="folder/<% control isbn %>$XML<% end_control %>.jpg">