Flash Games
 FAQ   Search   Memberlist   Usergroups   Register  Profile   Log in to check your private messages   Log in 


Pass params to popup



 

Post new topic   Reply to topic  
   DEVPPL Forum Index -> JavaScript Forum
View previous topic :: View next topic  
Author Message
dbirley



Joined: 05 Mar 2008
Posts: 3
Location: Rock Hill, SC

PostPosted: Fri Mar 14, 2008 9:37 pm    Post subject: Pass params to popup Reply with quote

Okay -- I'm back with my parm passing obsession. What I want to do is create a popup that will be the "receiving container". It will display with these components:

Header 1
Header 2
Text 1
Text 2
Image

Additionally the top and left positions need to be changeable.

If I were programming in Visual FoxPro (25 yrs experience) I would expect to build the content of each of these components into individual variables, and then pass them to a function:

var newWindow = null;
var head1 = "Hello"
var head2 = "World"
var text1 = "This is the first paragraph"
var text2 = "This is the second paragraph"
var myImage = "yadda.jpg"
var myLeft = 200
var myTop = 300

...and then call the popup thus:

function popItUp(win,head1,head2,text1,text2,myImage,myLeft,myTop) {
var windowFile = win + ".htm"
newWindow = open(windowFile, win, head1 ... etc. "scrollbars,resizable,width=500,height=400");
}

So -- quite simply how do I do it? (Function popItUp was adapted from Java Script for Dummies, p. 147).
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    DEVPPL Forum Index -> JavaScript Forum All times are GMT + 1 Hour
Page 1 of 1

 
 
Welcome to DEVPPL.com
You are not logged in, which means that you can't post in the forums.
Click here to Register

If you are a current member here on DEVPPL, please login below:

User: Pass:
Log me on automatically each visit:

 


Powered by phpBB © 2001, 2005 phpBB Group - Modified by DEVPPL

Flash Games - Sitemap