The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#11
|
|||
|
|||
Damn, that was simple. I see where I went wrong.
I never put this in the code at all. PHP Code:
--------------- Added [DATE]1333786475[/DATE] at [TIME]1333786475[/TIME] --------------- I read the article, I guess I just wasn't pay attention to it. I really do appreciate it. I've sent you a link to see what I'm trying to accomplish over-all. Just by seeing how it's done, I learned alot faster on how to accomplish this. Now I'm just trying to figure out the foreach statement. I figured I could use the vb:each statement in the template, but that didn't work. |
#12
|
|||
|
|||
I'm going to focus on your second problem now:
PHP Code:
PHP Code:
I've replace your unnecessary variables with an array and, furthermore, I've made sure each row gets it own place in the array. PHP Code:
Now replace all that ugliness in your first template render with: PHP Code:
I'd recommend using {vb:each [, ]} to loop through that array and do that. Read my article, it should help you get the basics down: https://vborg.vbsupport.ru/showthread.php?t=280880 |
#13
|
|||
|
|||
Appreciate it so much. Just some free time during this deployment. I will read this article one more.
--------------- Added [DATE]1333821880[/DATE] at [TIME]1333821880[/TIME] --------------- I've been trying for hours. I've search on google, and read through your article. I'm assuming that I am making a mistake as to where I'm suppose to put the php code foreach. |
#14
|
|||
|
|||
Yo, I am seriously lost.
This is my code in the template PHP Code:
PHP Code:
|
#15
|
|||
|
|||
What are you doing? The code I gave you is what you should be using! What you're doing won't work. vb:each replicates the foreach function, so you shouldn't be using an actual foreach in your php code!
HTML Code:
<vb:each from="musicals" key="key" value="musical"> {vb:raw musical.nr_artists} {vb:raw musical.nr_albums} etc.,. </vb:each> |
#16
|
|||
|
|||
Okay, so I put the php code just like you shown, and I've put the vb:each in just like you just posted. Nothing shows.
I've been reading alot of articles. |
#17
|
|||
|
|||
Post your complete PHP code and template code.
|
#18
|
|||
|
|||
Php Code
PHP Code:
PHP Code:
|
#19
|
|||
|
|||
Is the HTML you're showing me from template: vbmusic_latest, or from template: vbmusic
If it's from template: vbmusic, then you need to add: $templater->register('musicals', $musicals); to the register in that template. |
#20
|
|||
|
|||
Well god damn, I knew it was something simple that I was over looking. That was it.
I see that your site is music related as well. I'm currently deployed to Afghanistan right now. If it's not to much, can I continue to ask you for help from time to time. I get about six hours of free time each day. If possible how may I contact you. |
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|