Go Back   vb.org Archive > vBulletin 3 Discussion > vB3 General Discussions
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 04-28-2006, 04:05 AM
Connector Connector is offline
 
Join Date: Dec 2005
Location: Spain
Posts: 97
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Questions About phrase

Hello

there is something is confuse me i have phpcode and i need to use some phrase like "Username"PostCount"Welcome"Rank"avatars" i get the Username work fine without use any vbphrase

In the PHPCode i have add this .

PHP Code:
                        $vbphrase['content'] = construct_phrase($vbphrase['gtcustom_page1_msg'],strtoupper

($vbulletin->options['usnername'])); 

in the template i have add this

Code:
<strong><phrase 1="$bbuserinfo[username]">$vbphrase[gtcustom_permissionsadmin_msg]</phrase>
The first think is i dont no how can i add multi phrase and how can i get The UserPostcount etc.. ?

Thankyou
Reply With Quote
  #2  
Old 04-28-2006, 04:24 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Connector
Hello

there is something is confuse me i have phpcode and i need to use some phrase like "Username"PostCount"Welcome"Rank"avatars" i get the Username work fine without use any vbphrase

In the PHPCode i have add this .

PHP Code:
 $vbphrase['content'] = construct_phrase($vbphrase['gtcustom_page1_msg'],strtoupper
 
($vbulletin->options['usnername'])); 

in the template i have add this

Code:
<strong><phrase 1="$bbuserinfo[username]">$vbphrase[gtcustom_permissionsadmin_msg]</phrase>
The first think is i dont no how can i add multi phrase and how can i get The UserPostcount etc.. ?

Thankyou
Did you forget something after strtoupper?
Reply With Quote
  #3  
Old 04-28-2006, 04:25 AM
Connector Connector is offline
 
Join Date: Dec 2005
Location: Spain
Posts: 97
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hmm what do i forget ? The Space ?

Here i was trying this

PHP Code:
$vbphrase['gtcustom_page1_msg'] = construct_phrase($vbphrase ['gtcustom_page1_msg'], strtoupper($vbulletin->options['username']), strtoupper($vbulletin->options['avatar']), strtoupper($vbulletin->options['rank'])); 
and in the template

<strong><phrase 1="$vboptions[username]">$vbphrase[gtcustom_page1_msg]</phrase>


in the vBphrase i add a new phrase called

gtcustom_page1_msg

i try to test and add {1} but it dont work

i'm not sure what wrong

Thankyou
Reply With Quote
  #4  
Old 04-28-2006, 06:11 AM
Boofo's Avatar
Boofo Boofo is offline
 
Join Date: Mar 2002
Location: Des Moines, IA (USA)
Posts: 15,776
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Quote:
Originally Posted by Connector
Hmm what do i forget ? The Space ?

Here i was trying this

PHP Code:
$vbphrase['gtcustom_page1_msg'] = construct_phrase($vbphrase ['gtcustom_page1_msg'], strtoupper($vbulletin->options['username']), strtoupper($vbulletin->options['avatar']), strtoupper($vbulletin->options['rank'])); 
and in the template

<strong><phrase 1="$vboptions[username]">$vbphrase[gtcustom_page1_msg]</phrase>


in the vBphrase i add a new phrase called

gtcustom_page1_msg

i try to test and add {1} but it dont work

i'm not sure what wrong

Thankyou
Try this:

<strong><phrase 1="$userinfo[username]">$vbphrase[gtcustom_page1_msg]</phrase>
Reply With Quote
  #5  
Old 04-28-2006, 05:52 PM
Connector Connector is offline
 
Join Date: Dec 2005
Location: Spain
Posts: 97
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hello

i try this and it dont work here is the php code

Quote:
$vbphrase['gtcustom_page1_msg'] = construct_phrase($vbphrase ['gtcustom_page1_msg'], strtoupper($vbulletin->options['username']), strtoupper($vbulletin->options['avatar']), strtoupper($vbulletin->options['rank']));

Here in the template

<phrase 1="$userinfo[username]" 2="$userinfo[rank]">$vbphrase[gtcustom_page1_msg]</phrase>


So in the page i created it should look like

Hello {1} Your Rank {2}

but it dont work with me for some reson .. :tired:
Reply With Quote
  #6  
Old 04-28-2006, 06:49 PM
Delphiprogrammi Delphiprogrammi is offline
 
Join Date: Feb 2004
Location: Landen(Belgium)
Posts: 1,335
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i see no problem in your code however note that not all phrasegroups are loaded on all vbulletin pages ... and that might be the cause of your problem at the top of vbulletin source files you will find

PHP Code:
$phrasegroups = array(); 
there you find what phrasegroups are loaded by which pages ...for example if your phrase should show up in the members profile of a user at your board (member.php?u=$userid) then your phrase must be in a phrasesgroup that get's loaded when that page is viewed or you won't get any output
Reply With Quote
  #7  
Old 04-28-2006, 07:10 PM
Connector Connector is offline
 
Join Date: Dec 2005
Location: Spain
Posts: 97
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hmm Then why it dont work with me

if i use

$vboptions[bbtitle]
$vboptions[companyname]

this work fine .. just the above code dose not work ..
Reply With Quote
  #8  
Old 04-28-2006, 07:59 PM
Delphiprogrammi Delphiprogrammi is offline
 
Join Date: Feb 2004
Location: Landen(Belgium)
Posts: 1,335
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

try to rebuild the languages you have installed (admincp => phrasemanager => languagemanager => rebuild) that helped me before when i had a similar problem
Reply With Quote
  #9  
Old 04-28-2006, 08:33 PM
Connector Connector is offline
 
Join Date: Dec 2005
Location: Spain
Posts: 97
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Hello

Thankyou For the help i dont think this work for me i try this before alot and it dont work

know i use anther way and it seem to me work fine .. i use $bbuserinfo[something] and it work without i need to add the construct_phrase() in the php code.. hmm.

Peace.
Reply With Quote
Reply


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

Forum Jump


All times are GMT. The time now is 06:27 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.04603 seconds
  • Memory Usage 2,258KB
  • Queries Executed 11 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (2)bbcode_code
  • (5)bbcode_php
  • (3)bbcode_quote
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (9)post_thanks_box
  • (9)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (9)post_thanks_postbit_info
  • (9)postbit
  • (9)postbit_onlinestatus
  • (9)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete