1. #1
    Sencha User StevenInc's Avatar
    Join Date
    Jul 2009
    Location
    NYC
    Posts
    72
    Vote Rating
    0
    StevenInc is on a distinguished road

      0  

    Default [SOLVED]Can I center an image in a panel?

    [SOLVED]Can I center an image in a panel?


    This is a very simple panel that is stacked in a vbox with other panels.
    This is the only panel I would like to center the content in.

    Thanks
    Code:
            var topPanoramicImage = {
             xtype: 'panel', 
                 height: 70, 
                 bodyStyle:{"background-color":"#D1DFF0"},  
                 html: '<img src="assets/images/ihome/panoramic_MiamiFl2.png" alt="panoramic image" width="770" height="70" border="0">'
            };
    Steven Benjamin
    Senior Coldfusion Developer


    www.stevenbenjamin.com

  2. #2
    Sencha User chesstrix's Avatar
    Join Date
    Apr 2008
    Posts
    117
    Vote Rating
    1
    chesstrix is on a distinguished road

      0  

    Default


    It depends exactly how you want the center to work but simply wrapping the img tag in a <center> tag will do it.

    HTML Code:
    html: '<center><img src="assets/images/ihome/panoramic_MiamiFl2.png" alt="panoramic image" width="770" height="70" border="0"></center>'
    If you have more than just this image to center then this might help
    HTML Code:
    bodyStyle:{"background-color":"#D1DFF0"; text-align: center;}
    I'm surprised that you need a whole panel to hold just an image though

  3. #3
    Sencha User StevenInc's Avatar
    Join Date
    Jul 2009
    Location
    NYC
    Posts
    72
    Vote Rating
    0
    StevenInc is on a distinguished road

      0  

    Default


    Thank you - That solved it.
    Steven Benjamin
    Senior Coldfusion Developer


    www.stevenbenjamin.com

Thread Participants: 1

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar