Client Side Things
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Codewalkers ForumsOther TechnologiesClient Side Things

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Codewalkers Forums Sponsor:
AT&T devCentral & BlackBerry(r) Webcast Series: BlackBerry and GPS -Build Location Awareness into your BlackBerry Applications, July 10th-1:00PM EST. Register Today!
  #1  
Old March 25th, 2004, 10:45 AM
Anonymous Anonymous is offline
Registered User
Codewalkers God 35th Plane (22000 - 22499 posts)
 
Join Date: Apr 2007
Posts: 22,309 Anonymous User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 24
OnClick

i had a JS func to open a new window . The problem is that i hav another javascript func that takes 2 search parameters and only using that the new window must show the results. how can it be possible .i willsend my first JS
##################################################
<script language="JavaScript">
function query(tstampFrom,tstampTo)
{
document.frm2.tstampFrom.value=tstampFrom;
document.frm2.tstampTo.value=tstampTo;
document.frm2.submit();
}
</script>
##################################################

the second one
###############################################
<script language="JavaScript">
var newWin = null;
function popUp(strURL, strType, strHeight, strWidth) {
if (newWin != null && !newWin.closed)
newWin.close();
var strOptions="";
if (strType=="console")
strOptions="resizable,height="+
strHeight+",width="+strWidth;
if (strType=="fixed")
strOptions="status,height="+
strHeight+",width="+strWidth;
if (strType=="elastic")
strOptions="toolbar,menubar,scrollbars,"+
"resizable,location,height="+
strHeight+",width="+strWidth;
newWin = window.open(strURL, 'newWin', strOptions);
newWin.focus();
}
</script>
################################################
The ahref call

<td width="40%" valign="middle" align="center" class="txtOne"><a href="#" onClick="query('<?=$tstampFrom?>','<?=$tstampTo?>')" "popUp(this.href,'console',400,600);return false;" target="_blank"><b>Print
This Page</b></a></td>

This is not working

Pls help me
Thanx in Advance

Reply With Quote
  #2  
Old March 25th, 2004, 11:17 AM
Anonymous Anonymous is offline
Registered User
Codewalkers God 35th Plane (22000 - 22499 posts)
 
Join Date: Apr 2007
Posts: 22,309 Anonymous User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 24
RE: OnClick

i hav found an answer to that
################################################## ####just call the query() and from thier u call the
popup() and return to the called func simple
i will give the complete code changes
################################################## #
<script language="JavaScript">
function query(tstampFrom,tstampTo)
{
document.frm2.tstampFrom.value=tstampFrom;
document.frm2.tstampTo.value=tstampTo;
popUp('print.php?tstampFrom='+tstampFrom+'&tstampTo='+tstampTo,'console',500,700);
}
</script>
################################################## ##
<script language="JavaScript">
var newWin = null;
function popUp(strURL, strType, strHeight, strWidth) {
if (newWin != null && !newWin.closed)
newWin.close();
var strOptions="";
if (strType=="console")
strOptions="resizable,height="+
strHeight+",width="+strWidth;
if (strType=="fixed")
strOptions="status,height="+
strHeight+",width="+strWidth;
if (strType=="elastic")
strOptions="toolbar,menubar,scrollbars,"+
"resizable,location,height="+
strHeight+",width="+strWidth;

newWin = window.open(strURL, 'newWin', strOptions);
newWin.focus();
return;---------------------> The Only Change
}
</script>
##############################################

<td <a href="#" onClick="query('<?=$tstampFrom?>',
'<?=$tstampTo?>')"><b>Print</a>

################################################

Reply With Quote
Reply

Viewing: Codewalkers ForumsOther TechnologiesClient Side Things > OnClick


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway