Go Back   vb.org Archive > Community Discussions > Modification Requests/Questions (Unpaid)
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #11  
Old 09-01-2001, 07:20 PM
Ruth Ruth is offline
 
Join Date: Oct 2001
Posts: 171
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Thanks bargie for the hack, is it possbile to use this hack so that guests/unregistered view header_1 and registered members view header_2 ?

thanks again
Reply With Quote
  #12  
Old 09-01-2001, 08:47 PM
bargie bargie is offline
 
Join Date: Dec 2001
Posts: 33
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

it might be possible, but this would have to be done by setting a cookie, which may mean some people cant use it say, if they haven't got cookies enabled (most people have), that is the only way i can think of. but then if they are using a different computer and log in then they would have to change style on every computer, where as the hack allows users to log in and go straight to the style.

if ne 1 could help me with a fuction i want to add, or is this built into vb? is admin can select which style they want as there default.

I would like my site to say have christmas, easter, summer, winter, auterm, spring etc.. styles, and for me to say select the defult i want, say at xmas i want the xmas style as my default. Ok every one how has allready choosen a style won't be able to see it, but its a goood idea i think. also you could have this set up automaticly so on set dates the headers and footers change to the time of year, which means when it is all set up you want have to worry about it?

it will probably go something like
if ($styleid=="1") {
if ($date=="$xmasdates") {
if (!$header) {
eval("\$header = \"".gettemplate('headerxmas')."\";");
} else {
eval("\$header .= \"".gettemplate('headerxmas')."\";");
}
if (!$footer) {
eval("\$footer = \"".gettemplate('footerxmas')."\";");
} else {
eval("\$footer .= \"".gettemplate('footerxmas')."\";");
}
}
if ($date=="$summerdates") {
etc.

if any one know how this would be done then pls help

regards
jamie
Reply With Quote
  #13  
Old 09-02-2001, 11:55 AM
bargie bargie is offline
 
Join Date: Dec 2001
Posts: 33
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

so i read your post wrong this is how i think it would work in theroy it should could you tell me if it does?

in global.php find

if (!$header) {

add before

if ($bbuserinfo['userid']!=0) {

that bit checks if the user is loged on (registered)

now you should have

if ($bbuserinfo['userid']!=0) {
if (!$header) {
eval("\$header = \"".gettemplate('header_2')."\";");
} else {
eval("\$header .= \"".gettemplate('header_2')."\";");
}
if (!$footer) {
eval("\$footer = \"".gettemplate('footer_2')."\";");
} else {
eval("\$footer .= \"".gettemplate('footer_2')."\";");
}

then add below that

} else {
if (!$header) {
eval("\$header = \"".gettemplate('header_1')."\";");
} else {
eval("\$header .= \"".gettemplate('header_1')."\";");
}
if (!$footer) {
eval("\$footer = \"".gettemplate('footer_1')."\";");
} else {
eval("\$footer .= \"".gettemplate('footer_1')."\";");
}
}

that should be it, remember to add to the get templates, the templates you want to have used!

regards

jamie
Reply With Quote
  #14  
Old 09-02-2001, 03:05 PM
Ruth Ruth is offline
 
Join Date: Oct 2001
Posts: 171
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

it is working

this will save me lots of time changing the templates

Thanks so much bargie!
Reply With Quote
  #15  
Old 09-04-2001, 04:17 PM
bargie bargie is offline
 
Join Date: Dec 2001
Posts: 33
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

ruth can i have the url for your board as i wish to have a look
Reply With Quote
  #16  
Old 09-04-2001, 04:44 PM
Ruth Ruth is offline
 
Join Date: Oct 2001
Posts: 171
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

i had to resit everything back to original until i finish designing the headers and footers, i'll show it to you once it's comlete.

cheers,
Reply With Quote
  #17  
Old 09-09-2001, 12:26 PM
imom
Guest
 
Posts: n/a
Default

you are a LIFESAVER! Thanks! And I'll let you know how it goes.

Liz
Reply With Quote
  #18  
Old 10-14-2001, 09:17 PM
bargie bargie is offline
 
Join Date: Dec 2001
Posts: 33
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

anyone want this or can i get rid of it,
Reply With Quote
  #19  
Old 10-25-2001, 11:38 PM
Robert9 Robert9 is offline
 
Join Date: Oct 2001
Location: super
Posts: 171
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Your hack do the trick, but only at the first page!

Then the var will not passed and the old style comes again.

Robert
Reply With Quote
  #20  
Old 10-26-2001, 01:41 PM
bargie bargie is offline
 
Join Date: Dec 2001
Posts: 33
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

it does work, but the problem is that the cookie dosen't over write i'm working on not using the cookie.

can you explain you problem fully pls.

jamie
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 05:24 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
  • Page Generation 0.04299 seconds
  • Memory Usage 2,261KB
  • Queries Executed 12 (?)
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
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (10)post_thanks_box
  • (10)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (10)post_thanks_postbit_info
  • (10)postbit
  • (9)postbit_onlinestatus
  • (10)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
  • pagenav_page
  • pagenav_complete
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete