Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 772783
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T18:51:28+00:00 2026-05-14T18:51:28+00:00

I am trying to open a modal jquery dialog using jquery 1.4 and jquery-ui-1.8rc3.custom.js

  • 0

I am trying to open a modal jquery dialog using jquery 1.4 and jquery-ui-1.8rc3.custom.js

The dialog opens up with no issues, in all browsers, but in IE 7 and 6, after the dialog opens up, the window scrolls itself to the buttom… I tried scrolling the window up back to the modal position but is very inconsistent.
was using the following line of code after opening up the modal

window.scrollTo($('#selector').dialog('option', 'position')[0],$('#selector').dialog('option', 'position')[1]);

One weird thing I am noticing is that after I open the modal, the page becomes huge… as if some extra things adds up on the bottom …. and it eventually scrolls to the bottom.
Any idea why this could be hapenning

in html

<div id="selector">
</div>

in document.ready

$('#selector').dialog({
  bgiframe: true,
  autoOpen: false,
  width: 100,
  height: 100,
  modal: true,
  position: 'top'
});

in js

$('#selector').dialog('open');
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-14T18:51:28+00:00Added an answer on May 14, 2026 at 6:51 pm

    Looks like you are missing the # in your selector:

    window.scrollTo($('#selector').dialog('option', 'position')[0], $('#selector').dialog('option', 'position')[1]);
    

    that might be why the window is scrolling to the left top corner.


    Edit: I was just looking at the documentation and .dialog('option','position') default value is center.

    position Type: String, Array Default: ‘center’

    Specifies where the dialog should be
    displayed. Possible values: 1) a
    single string representing position
    within viewport: ‘center’, ‘left’,
    ‘right’, ‘top’, ‘bottom’. 2) an array
    containing an x,y coordinate pair in
    pixel offset from left, top corner of
    viewport (e.g. [350,100]) 3) an array
    containing x,y position string values
    (e.g. [‘right’,’top’] for top right
    corner).

    So you could get text or numbers returned using the position option and window.scrollTo() requires numbers. So try this instead:

    var d = $(".ui-dialog").position();
    window.scrollTo( d.left , d.top);
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm trying to do a confirm dialog using jquery, but the form doesn't get
Im trying to make a pop-up like window using jquery and its modal box.
I'm trying to open a Jquery UI dialog box after the user clicks on
I'm trying to initiate a jQuery UI modal window, but I think I'm doing
I'm trying to open a jQuery dialog using AJAX. The content of the dialog
I am trying open a new window using url.Action. And the new Window url
I'm trying to display a modal form using jquery ui. I've adapted an example
I am trying to load two modal dialog boxes with Jquery. Both of them
I'm trying to add a jQuery UI modal dialog to show when a function
I am using jQuery UI dialog for modal popups. I have some iframes in

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.