vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Retrieve STYLE CSS Info (https://vborg.vbsupport.ru/showthread.php?t=247340)

SorentoUltimate 07-26-2010 04:09 PM

Retrieve STYLE CSS Info
 
Hello,

i want to retrieve some info from active style into a php file.

Example : I want to take the :
Normal Links CSS Color
Normal Links CSS Font
Hover Links CSS Color
Hover Links CSS Font

from Popup Menu Option Row (vbmenu_option)

Any way to do that?

Thanks
SorentoUltimate

Michael.A 07-26-2010 04:53 PM

you want to add this in a php file or you want a php file to use it?

key words of the day { firebug }

SorentoUltimate 07-26-2010 05:50 PM

Quote:

Originally Posted by MAD--DOG (Post 2074836)
you want to add this in a php file or you want a php file to use it?

key words of the day { firebug }

i want in a php file to make a variable = Normal Links CSS Color etc.

Example :

$linkcolor = ......;
$linkfont = ......;
$linkhovercolor = ......;
$linkhoverfont = ......;

what i have to put??

Michael.A 07-26-2010 08:03 PM

look man this is what i know you can have your php file connect to style.css file but to have a css code in a php file i never see it before...

use the vbseo for an Example...

SorentoUltimate 07-26-2010 08:45 PM

Quote:

Originally Posted by MAD--DOG (Post 2074918)
look man this is what i know you can have your php file connect to style.css file but to have a css code in a php file i never see it before...

use the vbseo for an Example...

i making a hack with tabbar for vbulletin 3.8.x and i want to use colors etc from style css

Michael.A 07-26-2010 08:48 PM

am going to need to see the code that you playing with to help you man....

SorentoUltimate 07-26-2010 08:54 PM

Quote:

Originally Posted by MAD--DOG (Post 2074940)
am going to need to see the code that you playing with to help you man....

i start with that Addon https://vborg.vbsupport.ru/showthread.php?t=175890

in Global Start Plugin put in some variables (Used in Javascript) colors defined at Settings.

I want to put to that variables values from css (depent on style, because i have 8 styles)

Code:

    $invtedfonsiz    = $vbulletin->options['tabbar_with_dropdown_fonsiz'];
    $invtednohovddlk  = $vbulletin->options['tabbar_with_dropdown_nohovddlk'];
    $invtedhovddlk    = $vbulletin->options['tabbar_with_dropdown_hovddlk'];

    $invtedcssimglft  = $vbulletin->options['tabbar_with_dropdown_cssimglft'];
    $invtedcssimgrht  = $vbulletin->options['tabbar_with_dropdown_cssimgrht'];
    $invtednohovlkcol = $vbulletin->options['tabbar_with_dropdown_nohovlk'];
    $invtedhovlkcol  = $vbulletin->options['tabbar_with_dropdown_hovlk'];
    $invtedjshowme    = $vbulletin->options['tabbar_with_dropdown_jspath'];
    $invtedbkgrd      = $vbulletin->options['tabbar_with_dropdown_bkgrd'];
    $invtedpddg      = $vbulletin->options['tabbar_with_dropdown_pddg'];


Michael.A 07-26-2010 10:49 PM

try adding

Code:

class="alt1"
&
Code:

class="alt2"

SorentoUltimate 07-28-2010 11:37 AM

Hi all,

i found the solution to my problem.

Here the solution :

$vbmenu_option_template = fetch_template('.vbmenu_option', 0, false);
$vbmenu_option_css = unserialize( $vbmenu_option_template );

$dropdown_back_color = $vbmenu_option_css['background'];
$dropdown_font_color = $vbmenu_option_css['color'];
$dropdown_font_size = $vbmenu_option_css['font']['size'];
$dropdown_font_style = $vbmenu_option_css['font']['style'];
$dropdown_font_family = $vbmenu_option_css['font']['family'];
$dropdown_extra = $vbmenu_option_css['EXTRA'];
$dropdown_link_normal = $vbmenu_option_css['LINK_N']['color'];
$dropdown_link_hover = $vbmenu_option_css['LINK_M']['color'];


All times are GMT. The time now is 08:36 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.01001 seconds
  • Memory Usage 1,732KB
  • 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
  • (3)bbcode_code_printable
  • (3)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (9)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