Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Edit color and text font for Drop down menu???


johnnyosc

Recommended Posts

Posted

Where do you go to adjust the font and color for the text in the drop down menu found in Manufacturer and Show?? I like to give it a 14 font and a grey color.

Posted

Can you do that? That would be with CSS then.

 

Do you mean the manufacturers box?

The code is in includes/boxes/manufacturers.php. The HTML output will be (I think) in includes/functions/html_output.php

Christian Lescuyer

Posted

select {

  font-family: "Courier New", Courier, mono;

  font-size: 14px; 

  color: #666666;

}

 

Will break in older Netscapes.

Posted

Yes, of course!

Now this will apply to all selects. If you want to restrict that to some of them: (I'm stealing your code, Burt :shock:)

 

select.manufacturer { 

  font-family: "Courier New", Courier, mono; 

  font-size: 14px; 

  color: #666666; 

}

 

And in the HTML, use:

<select class="manufacturer"...>

Christian Lescuyer

Posted

:dontgetit: Christian,

 

I've been looking at this... but where exactly should I put the code in manuacturers.php?

 

Thanks for letting me know!

 

Mario

Posted

Replace:

'text'  => tep_draw_pull_down_menu('manufacturers_id', $manufacturers_array, $HTTP_GET_VARS['manufacturers_id'], 'onChange="this.form.submit();" size="' . MAX_MANUFACTURERS_LIST . '" style="width: 100%"') . tep_hide_session_id());

with this:

'text'  => tep_draw_pull_down_menu('manufacturers_id', $manufacturers_array, $HTTP_GET_VARS['manufacturers_id'], 'onChange="this.form.submit();" size="' . MAX_MANUFACTURERS_LIST . '" style="width: 100%" class="manufacturer"') . tep_hide_session_id());

 

Don't forget to add the style in the css file.

Not tested.

Christian Lescuyer

Posted

Works fine now!

 

I isn't really what I was looking for though. I would have liked to change the style of the drop down list, input fields and radio buttons. I guess these are form items of which the settings are inherited from the OS, browser and display settings. (E.g. the arrow down at the right side looks more blue-grey on XP than it does on Win98...)

 

Unless there is a way of controlling these attributes as well!?

 

Thanks anyway for your trouble!

 

Mario

Posted

A lot of things can be controlled with CSS. You also have to markup the HTML with class=whatever of course.

 

As you've seen, it's not difficult, just time consumming. A lot of featured shops have beautiful designs.

Christian Lescuyer

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...