Data Specific Pop-Up Window Content

  • Thread starter frontpagecustoms.com
  • Start date
F

frontpagecustoms.com

I'm using the following code to control a pop-up window with
data-specific content.

<Script Language="JavaScript">
function openwindowlink02() {
newwin =
window.open("camperquickfinance.asp?ParentEmail=<%=FP_FieldURL(fp_rs,"ParentEmail")%>&CamperFirstName=<%=FP_FieldURL(fp_rs,"CamperFirstName")%>","windowname","height=295,width=500,scrollbars=yes,resizable=yes")
}
</Script></font><a href="JavaScript: openwindowlink02()"><font
color="#726654">$$$</font></a>

It works great with one exception. Each record opens the last record
listed. For Instance If I had the following items in a list, the user
could click the $$$ sign after it to pull up detailed information about
that item.

Sally $$$
John $$$
David $$$
Henry $$$

I want sally to be able to click her $$$ and show her detailed
information; however with the script above all $$$ pop up the details
for the last record, in this example it would be Henry.

NOTE: ParentEmail and CamperName are designed to filter out the
information to be unique for each record.

Is there a different way you would recommend doing this?
 
D

David Berry

If you're using a loop to go through the records then EACH record in the
loop would need this line:

<a href="JavaScript: openwindowlink02()"><font
color="#726654">$$$</font></a>

Can you paste the code you're using into a reply?
 
F

frontpagecustoms.com

I'm not sure how much code you need, or what exactly a loop refers to.
I'm making the assumption that a loop is where the database results
region lists every record that meets the specified parameters (ie
ParentEmail), and so yes this code is inside the region that loops.

Inside the Database Results Region you will find the following:

First Name & Last Name - Linked to a registration page with parentemail
and firstname
$$$ - Javascript - Linked to a quickfinance page with parentemail and
firstname
Church Info - Javascript - LInked to churchinfo page with parentemail
and firstname
Camp Info - Javascript - linked to campinfo page with parentemail and
firstname
Edit Camper - Linked to edit page with camperID

Maybe it would be easier if you saw the page: Here's a link to a
sample:

https://ssl.perfora.net/sdsummercamp.com/[email protected]

Not wanting to take too much time, but could you give me some tips on
how to make this content more secure?

Here's the code - I'll delete the previous comments to save space.

<p>
<a
href="registered_campers.asp?ParentEmail=<%=FP_FieldURL(fp_rs,"ParentEmail")%>&CamperFirstName=<%=FP_FieldURL(fp_rs,"CamperFirstName")%>">
<!--webbot bot="DatabaseResultColumn"
s-columnnames="ParentEmail,CamperID,CamperFirstName,CamperLastName,CamperAdditlFamily,CamperEmail,CamperFallGrade,CamperBirthDate,ChurchName,RoommateRequest1,RoommateRequest2,RegisteringFor,Count,HealthNotes,Medications,MedInstructions,Shirt,ShirtSize,Photo,DVD,Craft,CarePackage,ClimbingWall,ZipLine,AgreeWithPolicy,Payment1,Check1,Payment2,Check2,Payment3,Check3,RegiteredOnline,Allergies,Cardiac,Kidney,Seizures,Lungs_Asthma,Diabetic,DietaryConcerns,DietyaryConcDesc,InfectiousDis,Chkd4Lice,DrugReactions,DrucReactionsDesc,AllerghPen,RestrictedAct,RestrictedActDesc,TetanusBoster,CurrentImm,ImmunzExplained,Doctor,DocsPHone,Remote_computer_name,User_name,Browser_type,Timestamp,PreRegFee,Tuition,ChuchName,Adjustments,AdjustmentReason"
s-column="CamperFirstName" b-tableformat="FALSE" b-hashtml="FALSE"
b-makelink="FALSE" clientside b-MenuFormat preview="&lt;font
size=&quot;-1&quot;&gt;&amp;lt;&amp;lt;&lt;/font&gt;CamperFirstName&lt;font
size=&quot;-1&quot;&gt;&amp;gt;&amp;gt;&lt;/font&gt;" startspan
--><%=FP_FieldVal(fp_rs,"CamperFirstName")%><!--webbot
bot="DatabaseResultColumn" endspan i-checksum="39648" --><font
color="#E5DABB">-</font><!--webbot bot="DatabaseResultColumn"
s-columnnames="ParentEmail,CamperID,CamperFirstName,CamperLastName,CamperAdditlFamily,CamperEmail,CamperFallGrade,CamperBirthDate,ChurchName,RoommateRequest1,RoommateRequest2,RegisteringFor,Count,HealthNotes,Medications,MedInstructions,Shirt,ShirtSize,Photo,DVD,Craft,CarePackage,ClimbingWall,ZipLine,AgreeWithPolicy,Payment1,Check1,Payment2,Check2,Payment3,Check3,RegiteredOnline,Allergies,Cardiac,Kidney,Seizures,Lungs_Asthma,Diabetic,DietaryConcerns,DietyaryConcDesc,InfectiousDis,Chkd4Lice,DrugReactions,DrucReactionsDesc,AllerghPen,RestrictedAct,RestrictedActDesc,TetanusBoster,CurrentImm,ImmunzExplained,Doctor,DocsPHone,Remote_computer_name,User_name,Browser_type,Timestamp,PreRegFee,Tuition,ChuchName,Adjustments,AdjustmentReason"
s-column="CamperLastName" b-tableformat="FALSE" b-hashtml="FALSE"
b-makelink="FALSE" clientside b-MenuFormat preview="&lt;font
size=&quot;-1&quot;&gt;&amp;lt;&amp;lt;&lt;/font&gt;CamperLastName&lt;font
size=&quot;-1&quot;&gt;&amp;gt;&amp;gt;&lt;/font&gt;" startspan
--><%=FP_FieldVal(fp_rs,"CamperLastName")%><!--webbot
bot="DatabaseResultColumn" endspan i-checksum="41698" --></a></p>
<p>
<font size="1">&nbsp; <font color="#726654">
&nbsp;
<Script Language="JavaScript">
function openwindowlink02() {
newwin =
window.open("camperquickfinance.asp?ParentEmail=<%=FP_FieldURL(fp_rs,"ParentEmail")%>&CamperFirstName=<%=FP_FieldURL(fp_rs,"CamperFirstName")%>","windowname","height=295,width=500,scrollbars=yes,resizable=yes")
}
</Script></font><a href="JavaScript: openwindowlink02()"><font
color="#726654">$$$</font></a><font color="#726654">




<Script Language="JavaScript">
function openwindowlink() {
newwin =
window.open("churchcampoffice.asp?ParentEmail=<%=FP_FieldURL(fp_rs,"ParentEmail")%>&CamperFirstName=<%=FP_FieldURL(fp_rs,"CamperFirstName")%>","windowname","height=295,width=500,scrollbars=yes,resizable=yes")
}
</Script> - </font> <a href="JavaScript: openwindowlink()">
<font color="#726654">church info </font> </a>
<font color="#726654">- <Script Language="JavaScript">
function openwindowlink01() {
newwin =
window.open("campinformation.asp?ParentEmail=<%=FP_FieldURL(fp_rs,"ParentEmail")%>&CamperFirstName=<%=FP_FieldURL(fp_rs,"CamperFirstName")%>","windowname","height=295,width=500,scrollbars=yes,resizable=yes")
}
</Script></font><a href="JavaScript: openwindowlink01()"><font
color="#726654">camp
info</font></a><font color="#726654"> -
</font>
<a
href="CampReg_interface/CamperRegistrationInfo/editor/edit.asp?CamperID=<%=FP_FieldURL(fp_rs,"CamperID")%>">
<font color="#726654">edit camper</font></a></font></p>
<hr noshade size="1">
<!--webbot bot="DatabaseRegionEnd" b-tableformat="FALSE"
b-menuformat="FALSE" u-dbrgn2="_fpclass/fpdbrgn2.inc" i-groupsize="0"
clientside tag="BODY" preview="&lt;table border=0
width=&quot;100%&quot;&gt;&lt;tr&gt;&lt;td
bgcolor=&quot;#FFFF00&quot;&gt;&lt;font
color=&quot;#000000&quot;&gt;This is the end of a Database Results
region.&lt;/font&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;" startspan
--><!--#include file="_fpclass/fpdbrgn2.inc"-->
<!--webbot bot="DatabaseRegionEnd" endspan i-checksum="62730" --><p>
 
F

frontpagecustoms.com

Fixed My Own Problem:

Here's the code that works

<A HREF="somePage.htm" TARGET="new"
onClick="window.open('somePage.htm','new','width=##,height=##'); return
false;">click click</A>

Just substistute somePage.htm (x2) with your page link and include the
vb script.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top