Categories > TinyButStrong general >

Can someone help me out, adding image srces from database...

The forum is closed. Please use Stack Overflow for submitting new questions. Use tags: tinybutstrong , opentbs
By: Spod
Date: 2010-04-14
Time: 21:58

Can someone help me out, adding image srces from database...

I would like to add following blocks into html from template and db:

<li><img src='sads1.jpg'></li>
<li><img src='sads2.jpg'></li>
<li><img src='sads3.jpg'></li>
...

The more i am reading the documentation and looking the examples the more stupid i feel. I am just before giving up on tbs and write my own template system. Am i really that dumb or i can comprehend logic behind this blocks... i tryed to format the whole block within php and insert it into template as a variable but the tbs escaped it... i feel like the tbs is making fun out of me, everything i touch works differently as i would expect...
By: TomH
Date: 2010-04-15
Time: 01:23

Re: Can someone help me out, adding image srces from database...

Slow down, calm down... and read the examples here...
http://www.tinybutstrong.com/examples.php

Choose the "Data" example and then use the Display selections to view the PHP and template files.

If you can't figure out how to use TBS from the Examples then you certainly would have to rethink wheter you could actually write your own template system ;) pardon the sarcasm sometimes I can't stop myself

And... there's always been plenty of help on this forum for anyone who does their homework.
By: Spod
Date: 2010-04-15
Time: 10:07

Re: Can someone help me out, adding image srces from database...

I did check the examples but the TBS syntax on template side is highly unintuitive to me. But on the other side the same goes for html so maybe it just fits fine (sorry i am coming from the other side, normally it is more likely for me that i would be writting php module or web server than touching html/php/javascript (c/c++ system developer for platforms ranging from windows to solaris and hpux) but i just got a baby and i wanted to QUICKLY setup some web gallery ... well everything else was quick (reading files) but i decided to use some small template system but unfortunally tbs isnt that tiny (search and replace would fit just fine)... meanwhile i figured it out but looks like the tbs sources are more understandable to me than those samples where the usage of blocks is shown but the logic how they actually work is ignored... thanks for trying to help anyway.