Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Positioning a popup window

Posted on 2014-03-21
5
Medium Priority
?
296 Views
Last Modified: 2014-04-12
I'm working on an online reservation system at www.mauitradewinds.com/Test/availability.html    There is a form on that page, "Check Availability by Date", where dates can be entered by clicking a calendar icon.  The calendar should appear near the center of the page, but instead, it appears high up, possibly beyond the top of the screen.  How can I center that popup on the page?
0
Comment
Question by:ddantes
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
5 Comments
 
LVL 15

Expert Comment

by:Insoftservice
ID: 39944854
Please provide screen shot as on my laptop its displayed just above the text field
0
 
LVL 82

Accepted Solution

by:
leakim971 earned 1000 total points
ID: 39945474
In calendar.css replace :
.calendar {
  position: relative;
  display: none;
  border-top: 2px solid #fff;
  border-right: 2px solid #000;
  border-bottom: 2px solid #000;
  border-left: 2px solid #fff;
  font-size: 11px;
  color: #000;
  cursor: default;
  background: #c8d4d0;
  font-family: tahoma,verdana,sans-serif;
}

Open in new window


by (position from relative to absolute, adding left, top to 50% and margin(half dimension size for left and top) :
.calendar {
position: absolute;
left: 50%;
top: 50%;
margin: -115px 0 0 -100px;
  display: none;
  border-top: 2px solid #fff;
  border-right: 2px solid #000;
  border-bottom: 2px solid #000;
  border-left: 2px solid #fff;
  font-size: 11px;
  color: #000;
  cursor: default;
  background: #c8d4d0;
  font-family: tahoma,verdana,sans-serif;
}

Open in new window

0
 

Author Comment

by:ddantes
ID: 39945915
Thank you.  I made those changes, but the issue persists.  I think it is related to styling and code changes I have made to the page which generates the calendar popup (av0001.html).  Here are screen shots of the popup location before and after I made those changes.  I used your modified calendar1.css in both cases.

Before changesAfter changes
0
 

Author Comment

by:ddantes
ID: 39946008
Please disregard my previous post.  My browser cache was still loading the previous calendar style sheet.  The css changes have resolved the issue -- thanks!
0
 

Author Comment

by:ddantes
ID: 39948238
There seems to be some issue with the position:absolute being rendered correctly by Internet Explorer.  Please see the new question:
http://www.experts-exchange.com/Web_Development/Web_Languages-Standards/CSS/Q_28411327.html
0

Featured Post

Important Lessons on Recovering from Petya

In their most recent webinar, Skyport Systems explores ways to isolate and protect critical databases to keep the core of your company safe from harm.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Finding original email is quite difficult due to their duplicates. From this article, you will come to know why multiple duplicates of same emails appear and how to delete duplicate emails from Outlook securely and instantly while vital emails remai…
In this blog, we’ll look at how improvements to Percona XtraDB Cluster improved IST performance.
In this tutorial viewers will learn how to style a decorative dropcap for the first letter in a paragraph using CSS. In CSS, create a new paragraph class by typing "p.fancy": Then, to style only the first letter of the first sentence, include the ps…
The viewer will learn the basics of jQuery including how to code hide show and toggles. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery…

610 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question