![]() |
How are array variables show to post?
Hi everyone,
My table, userid ------ threadid ---------- value 1----------------- 2 -------------- deger1 1----------------- 2 -------------- deger2 2----------------- 3 -------------- deger3 When I write “{vb:raw post.degerler}” at the postbit_legacy template, I want to see “deger1” and “deger2” (deger1 - deger2) the same time in the post, but I can see only “deger 2”. I’d ask you to help me about this situation. Thank you Best regards Sinan Coşkun |
I thikn we need to see the code where you set $post['degerler'].
|
I forgot, sorry :)
PHP Code:
|
You need to do something like this:
Code:
$vericek= $db->query_read("SELECT value FROM ".TABLE_PREFIX."tablo WHERE threadid=2"); |
Ok, but it was required separately as “deger1” and “deger2”, not “deger1-deger2”. Because i want to do hmm..
Examp: PHP Code:
|
OK, you could do this:
PHP Code:
or if you want to keep your html separate from the code you could make a small template for the link and render it. There is a vb:each tag you can use in a template to loop through an array, but I don't know how you'd to the ' - ' between them. Edit:...unless there can only be one or two values? Then you could put them in separate values (like $post['degerler1'] and $post['degerler2']), then you could use a <vb:if... to check if the second one exists. |
Yeees, that's :) thanks... very thanks
|
All times are GMT. The time now is 10:31 AM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|