Register Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools
  #1  
Old 19 Sep 2005, 09:41
MamboCube's Avatar
MamboCube MamboCube is offline
 
Join Date: Jul 2005
phrases-what is the template engine?

what exactly is the template engine and how do i use it?

i want to use vb phrases on my non vb pages and was told that u can use the template engine, but i have no idea wat thta is lol

any replies would b great

thnx
Reply With Quote
  #2  
Old 19 Sep 2005, 09:49
Andreas's Avatar
Andreas Andreas is offline
 
Join Date: Jan 2004
Real name: Andreas
vBulletin has it's own Template Engine, but that does not have thaat much to do with Phrases.
If you want to use the vBulletin Backend, just require global.php and you will be able to use its Template Engine, Language System, etc.
Reply With Quote
  #3  
Old 19 Sep 2005, 10:27
MamboCube's Avatar
MamboCube MamboCube is offline
 
Join Date: Jul 2005
i have required global.php and the phrases work when i use

Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

but i want to use the phrase tags so that i can use values from forms (database) for example


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

but when i use phrase tags i just get $vbphrase[welcome_x] as text

i tried making a custom phrase but i cant get it to work with php variables

does anyone know how to either use the phrase tags or to include php variables in custom phrases (if its even possible)

??
Reply With Quote
  #4  
Old 19 Sep 2005, 10:33
Marco van Herwaarden Marco van Herwaarden is offline
 
Join Date: Jul 2004
1. Set the 4 required arrays ($phrasegroups, $specialtemplates, $globaltemplates & $actiontemplates), require global.php

2. echo "Phrase: $vbphrase[phrasename]";

3. echo "Phrase with parameters: " . construct_phrase($vbphrase['phrasename'], $myparameter);
__________________
Marco van Herwaarden
Ex vBulletin.org Coordinator

Last edited by Marco van Herwaarden; 19 Sep 2005 at 10:35.
Reply With Quote
  #5  
Old 19 Sep 2005, 10:49
MamboCube's Avatar
MamboCube MamboCube is offline
 
Join Date: Jul 2005
like this ?


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

because i get this error message

Fatal error: Call to undefined function: contsruct_phrase() in /home/****/public_html/*****/header.php on line 81

have i done something wrong or is it all wrong ?

----------------------------------------------------------------------





right i found out the reason i was getting an error message, it was because i was spelling construct wrong lol, but................ when i put this


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.

i get this

MambocubeWelcome, Mambocube

i cant seem to get rid of the username in front

any ideas?

-------------------------------------------------------------------------
ok i managed to do it by doing this


Block Disabled:      (Update License Status)  
Suspended or Unlicensed Members Cannot View Code.



thnx for the help guys

Last edited by MamboCube; 19 Sep 2005 at 11:27. Reason: Automerged Doublepost
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


New To Site? Need Help?

All times are GMT. The time now is 00:07.

Layout Options | Width: Wide Color: