vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB4 Design and Graphics Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=253)
-   -   Editing the style - selection styles (https://vborg.vbsupport.ru/showthread.php?t=245029)

sergioloporto 06-21-2010 11:00 PM

Editing the style - selection styles
 
Hello,

I would like the texts of the posts and threads of the forums [not titles, only texts] to have a different color when selected/highlighted with the mouse.

The same for the text of the articles of the CMS [appearing in the article page itself, and in the general content.php page].

The same for the text of blog posts/comments.

Please tell me if:
  • there is a safe way to add the code so that when a new VB version will be released I don't have to copy and paste manually the new codes.
  • Please tell me how and where I can change the code.

I know that I have to add this to the parapgraphs:

HTML Code:

::-moz-selection{
background:#cc0000;
color:#fff;
}

::selection {
background:#cc0000;
color:#fff;

please help

sergioloporto 06-26-2010 08:38 PM

bump

sergioloporto 07-08-2010 12:03 PM

bump 2

sergioloporto 07-11-2010 08:59 AM

bump 3

Dead Eddie 07-11-2010 12:30 PM

Try adding this to your additional.css template:

Code:

.postcontent::selection{
background:#cc0000;
color:#fff;
}

.blogcontent::selection{
background:#cc0000;
color:#fff;
}

.postcontainer::selection{
background:#cc0000;
color:#fff;
}

.postcontent::-moz-selection{
background:#cc0000;
color:#fff;
}

.blogcontent::-moz-selection{
background:#cc0000;
color:#fff;
}

.postcontainer::-moz-selection{
background:#cc0000;
color:#fff;
}

Should work until vB decides to change those classes.

sergioloporto 07-11-2010 12:46 PM

Hi!! It works fine!! Thank you...

however it works only for normal text... if it is cursive or bold it doesn't work.

If I leave
HTML Code:

.postcontent::selection{
background:#cc0000;
color:#fff;
}

it is applied to normal text only.

if I put:

HTML Code:

.postcontent b i::selection{
background:#cc0000;
color:#fff;
}

it is applied to bold italic text only...

if I put

HTML Code:

.postcontent b::selection{
background:#cc0000;
color:#fff;
}

it is applied to bold only...

what should I put if I want it applied to each styles (bold, italics, normal)?

sergioloporto 07-16-2010 08:28 PM

In the end I decided to apply it to all the text of all VB CMS, and put:

Code:

*::selection{
background:#cc0000;
color:#fff;

*::-moz-selection{
background:#cc0000;
color:#fff;

Why it works only in FireFox?
I would like it to work also in Chrome and Opera. According to CSS3 it should work.


All times are GMT. The time now is 04:48 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.01085 seconds
  • Memory Usage 1,723KB
  • 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_code_printable
  • (4)bbcode_html_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (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
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete