vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 Programming Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=252)
-   -   Hat Santa in username (https://vborg.vbsupport.ru/showthread.php?t=321033)

MarkFL 12-12-2015 02:43 PM

Quote:

Originally Posted by Manoel J?nior (Post 2560269)
These you have commented was excellent !!

Okay...I uploaded the image to "images/misc" and then in the "additional.css" template, added:

HTML Code:

.username_container .username::before, .member_username::before, .member_blockrow .floatleft .username::before, .postbithead .username::before {
        content: url("images/misc/username_hat.png");
        position: relative;
        top: -3px;
        left: 18px;
        margin-left: -18px;
}

This will put the hat on names in social groups too. Let me know how that works for you. :)

Manoel J?nior 12-12-2015 06:56 PM

Thank you friend, it was really cool !!!

I'll have to get a picture in which the hat do a little curca because the way it is for those who have the name started capitalized overrides the hat the letter of the first name.

Thank you!!!

MarkFL 12-13-2015 01:31 AM

1 Attachment(s)
Quote:

Originally Posted by Manoel J?nior (Post 2560289)
Thank you friend, it was really cool !!!

I'll have to get a picture in which the hat do a little curca because the way it is for those who have the name started capitalized overrides the hat the letter of the first name.

Thank you!!!

On my local dev site, it sits right on top of the uppercase first letter of a username:

https://vborg.vbsupport.ru/attachmen...1&d=1449977247

If you need to move the image up though, adjust the "top" attribute of the CSS selector I posted. For example, to move it 2px further up, change the value from "-3px" to "-5px"...if you want to post a link to your site (to a page where a name is being obscured), then I can determine the value you need by editing the page HTML with Firebug. :)

Stratis 12-18-2015 02:58 PM

1 Attachment(s)
Here a test by me, with an other image that has angle to the left side.
Attachment 153844

I added code according to Marks code:
HTML Code:

/***** Santa's hat *****/
.username_container .username::before, .member_username::before, .member_blockrow .floatleft .username::before, .postbithead .username::before {
        content: url("images/misc/username_hat3.png");
        position: relative;
        top: -3px;
        left: 12px;
        margin-left: -12px;
}

Attachment 153845
:p

shimei 12-18-2015 06:02 PM

Any idea how to get this to work with VB5? Should I start a new thread under VB5 programming? If so, could someone help out?

MarkFL 12-18-2015 07:59 PM

Quote:

Originally Posted by shimei (Post 2560726)
Any idea how to get this to work with VB5? Should I start a new thread under VB5 programming? If so, could someone help out?

All that would really need to be done is to replace the class names with the appropriate vB5 counterparts. If you would like for me to do this at your site, please PM me the following:
  • Link to your site
  • Admin login credentials
  • Path to image file.

I would be able to get to this tonight. :)

shimei 12-18-2015 11:33 PM

Thanks Mark!


All times are GMT. The time now is 04:31 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.01866 seconds
  • Memory Usage 1,728KB
  • 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
  • (2)bbcode_html_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (1)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (7)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
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete