vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.6 Template Modifications (https://vborg.vbsupport.ru/forumdisplay.php?f=192)
-   -   New Posting Features - User Selected Default Posting Font and Color (https://vborg.vbsupport.ru/showthread.php?t=171868)

Theoldwiz 03-01-2008 10:00 PM

User Selected Default Posting Font and Color
 
Hello,

This mod allows users to select their default posting font and color. You will have to select this at registration and can update it whenever you want in profile.

First you must make two new single selection menu user profile fields. Options for them are below.

Profile field one:

Title: Default Post Color

Description: What color your posts show up as?

Options:

Black
Blue
Green
Red
Pink
Orange
Purple

Set Default: Yes, but no first blank option

Display Order: Doesnt Matter

Field Requiried: Yes, at registration and profile updating

Field Editable by User: Yes

Private Field: No

Field Searchable on Members List: No

Show on Members List: No


Profile field two:

Title: Default Post Font

Description: What do you want your default post font to be?

Options:

Arial
Arial Black
Arial Narrow
Book Antiqua
Century Gothic
Comic Sans MS
Courier New
Fixedsys
Franklin Gothic Medium
Garamond
Georgia
Impact
Lucida Console
Microsoft Sans Serif
Palatino Linotype
System
Tahoma
Times New Roman
Tribuchet MS
Verdana

Set Default: Yes, but no first blank option

Display Order: Doesnt Matter

Field Requiried: Yes, at registration and profile updating

Field Editable by User: Yes

Private Field: No

Field Searchable on Members List: No

Show on Members List: No

Now go to the user profile field manager, and jot down the two field numbers of the new fields listed on the right side of the two fields. Along with that, write down what number goes with what field. Please note this is not the display number, its the number next to it that says fieldX

Template Edits:

Go to your styles postbit/postbit legacy (whatever you use)

Find:
Code:

<!-- message -->
After Add:
Code:

<font COLOR="$post[fieldX]" face="$post[fieldX]">

Replace: The first red X with your default text color field number
The second red X with your default font field number.



Find:
Code:

<!-- / message -->
Add Above:
Code:

</font>

You are done, hope you like it!

TCE Killa 03-02-2008 12:57 PM

What's the difference between your one and this one?

Theoldwiz 03-02-2008 03:18 PM

Mine uses dropdown boxes, that one could most likely mess up your forum using boxes like that.

That one also uses color codes, thats too hard for members

Magnumutz 03-03-2008 11:31 AM

Theoldwiz, wouldn't it be better if it would be:
Code:

<font COLOR="$post[fieldX]" face="$post[fieldX]">
and at the end
</font>

Only one tag would decrease the code length by... 13 characters :p

Theoldwiz 03-03-2008 12:50 PM

Thank you Mag, very helpful :)

TCE Killa 03-03-2008 01:40 PM

Ah right, this is a lot better. Can this be used for username font and color as well? Thanks.

Theoldwiz 03-03-2008 01:52 PM

No it cant be for usernames. But I can make that if alot of you are interested

TCE Killa 03-03-2008 04:38 PM

Quote:

Originally Posted by Theoldwiz (Post 1455932)
No it cant be for usernames. But I can make that if alot of you are interested

Yeah I am definetely interested in the color and font for usernames. All I have is so they can put the hex code or font into a box for their usernames and like you said, it is alot easier if they can just scroll down and choose from a selection. Marked installed btw, thanks.

Faltzer 03-03-2008 05:12 PM

In my honest opinion, I think that you should just use <span> for this, regardless of them being the "same thing". I also prefer giving users a link to a site that provides HEX color codes. In addition, having in a drop-down the font weight (bold, italic). Basically, giving the user control while not giving him too much. Plus, he/she provides his/her own font.

Also, TCE_Killa, wouldn't colored usernames confuse people? o_o;

TCE Killa 03-03-2008 07:32 PM

Quote:

Originally Posted by Faltzer (Post 1456095)
In my honest opinion, I think that you should just use <span> for this, regardless of them being the "same thing". I also prefer giving users a link to a site that provides HEX color codes. In addition, having in a drop-down the font weight (bold, italic). Basically, giving the user control while not giving him too much. Plus, he/she provides his/her own font.

Also, TCE_Killa, wouldn't colored usernames confuse people? o_o;

Nope, I already have colored usernames on my forum and the users love it, they can also bold and glow their usernames and choose a font. It would be good for a drop down list though of a selected list of fonts and colors that I decide.

yoksito 03-03-2008 07:35 PM

example for color of usernames:

go to: usergroups -> usergroups manager -> choce a title -> Username HTML Markup, in text box1: <span style='color:red' font:'bold'> and text box2 </span>

and done

TCE Killa 03-03-2008 09:44 PM

Quote:

Originally Posted by yoksito (Post 1456198)
example for color of usernames:

go to: usergroups -> usergroups manager -> choce a title -> Username HTML Markup, in text box1: <span style='color:red' font:'bold'> and text box2 </span>

and done

All that does is gives usergroups a colour. Doesn't let them choose their own color.

This is how you let them choose their own username color and font:

PHP Code:

 <class="bigusername" href="member.php?$session[sessionurl]u=$post[userid]">
    <if 
condition="$post['field14'] != '' ">
<
font style="font-family:$post[field28]; color:$post[field14];">$post[username]</font>
    <else />
<if 
condition="$post['field27']"><span style="font-weight: bold; $post[field27]">$post[username]</span><else />
$post[musername]
</if></if></
a

What I would like to know is, if it is possible like on the default selective font & color on posts, to have that for the username font and color. Instead of just a box, use a drop down list of fonts and colors.

Chachacha 03-04-2008 01:42 AM

Is there any way you can make this work in quotes?

leannet 03-04-2008 10:03 AM

Can I add a default size aswell, because all the posts are now showing up tiny.

leannet 03-04-2008 10:09 AM

Please dis-regard my last post I made my own code and it worked.

Chachacha 03-12-2008 05:04 AM

Quote:

Originally Posted by Chachacha (Post 1456408)
Is there any way you can make this work in quotes?

Judging by the lack of a reply, I'm guessing that the answer is NO.

Shaheen 03-12-2008 08:37 PM

thanks .. works Great waiting for font size update ;)

Baldilocks 03-14-2008 03:15 AM

Would be nice if you could choose the default color too...especially if you havea lot of skins.

mystic10 03-16-2008 07:29 PM

this is what i put in my postbit and postlegacy but still not working dont know why..can someone tell me what i am doing wrong
<!-- message -->
<font COLOR="$post[field16]" face="$post[field17]">

<div id="post_message_$post[postid]">$post[message]</div>

</font>

<!-- / message -->

jellybaby 03-20-2008 08:00 AM

Edit: I have this working now.

mystic10 03-20-2008 05:35 PM

how did u make it work please share..as my not working at all...what am i doing wrong

mblb 03-22-2008 07:39 AM

it's not working for me either!

anachron 03-22-2008 03:12 PM

not working

mblb 03-23-2008 03:57 AM

Hmm, At least it's not just me! Not working here either!

mystic10 03-23-2008 07:12 PM

Theoldwiz ur hack is supported...please kindly help us so many want to use ur hack but lot of us are having problems as its not working at alll...kindly help us out...or atleast acknowledge that u have read our post and coming up with some sort of solution...i thank u again for u share it is very kind of u...sorry for the inconience that i might have caused...and waiting anxiously for ur answer

gibigbig 03-24-2008 11:05 PM

yes, as said before the font tag wasnt closed. the net effect would be a multitude of unclosed fonts per page, small code, big effect. please fix this mod

Also, il add that HTML colors could be used as well and color strings in the font tag

top dogs 360 05-30-2011 06:26 PM

can anyone get this to work for 4x? or point me to a similar mod? Thank you.


All times are GMT. The time now is 04:59 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.01330 seconds
  • Memory Usage 1,784KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (5)bbcode_code_printable
  • (1)bbcode_php_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (27)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.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/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.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
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete