Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 4 of 4
  1. #1
    Mega-ultimate member
    Join Date
    Jun 2002
    Location
    Winona, MN - The land of 10,000 lakes
    Posts
    1,855
    Thanks
    1
    Thanked 45 Times in 42 Posts

    jQuery - possible to make div resizable horizontally only?

    I'm using jQuery and I'd like to make divs in my page resizeable horizontally only, such that, when resized, the content in the div will automatically expand / contract to the necessary height.

    Is that possible? I've been searching google but can't seem to find any demos on it.

    Thanks

  • #2
    UE Antagonizer Fumigator's Avatar
    Join Date
    Dec 2005
    Location
    Utah, USA, Northwestern hemisphere, Earth, Solar System, Milky Way Galaxy, Alpha Quadrant
    Posts
    7,691
    Thanks
    42
    Thanked 637 Times in 625 Posts
    Forgive me for asking, but have you tried the CSS attribute "min-height"? Or are you talking about a user using the drag/resize option to manually resize a container?

  • #3
    Mega-ultimate member
    Join Date
    Jun 2002
    Location
    Winona, MN - The land of 10,000 lakes
    Posts
    1,855
    Thanks
    1
    Thanked 45 Times in 42 Posts
    Yeah referring to the resize option on a container. Not a CSS solution.

  • #4
    UE Antagonizer Fumigator's Avatar
    Join Date
    Dec 2005
    Location
    Utah, USA, Northwestern hemisphere, Earth, Solar System, Milky Way Galaxy, Alpha Quadrant
    Posts
    7,691
    Thanks
    42
    Thanked 637 Times in 625 Posts
    Well if you use the UI's "resizable" widget then you can set the minimum and maximum width and height and I imagine if you set min and max to the same value it would lock that axis.

    http://jqueryui.com/demos/resizable/


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •