Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to change the height on a jquery ui progressbar

I have a progress bar in a html table cell. It seems to expand to the width of the table cell but i want to explicitly specify the height of the progress bar.

Is it possible to specify the height of a jQuery progress bar?

    $(this).progressbar({
        value: parseInt($(this).attr("rel"))
    });
like image 702
leora Avatar asked Jun 01 '11 22:06

leora


3 Answers

Of course it is. There's even a resizable progress bar demo.

Too fancy for you? Just use .height():

$('#progressbar').height(400);

Demo: http://jsfiddle.net/mattball/N5AVv/

like image 189
Matt Ball Avatar answered Nov 24 '22 16:11

Matt Ball


you can also use this function which works for all css attribures

$("#progressbar" ).css( "maxWidth", "200%" );
like image 35
MirzaShakir Avatar answered Nov 24 '22 15:11

MirzaShakir


You will need to edit the jQuery UI CSS file. It will look something like

jquery-ui-1.8.17.custom.css

Scroll to the bottom (~line 564) and your will see the following CSS attribute:

.ui-progressbar (...);

change the HEIGHT attribute value to whatever you want, save the file and upload it to your server. Refresh your browser and you have your customized progress bar.

like image 20
Matteo Avatar answered Nov 24 '22 16:11

Matteo