Qsorb
asked on
URGENT: Help with Floatbox used in dynamic query
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2">
<title>Select Slideshow Test</title>
<link type="text/css" rel="stylesheet" href="/floatbox/floatbox.css" />
<script type="text/javascript" src="/floatbox/floatbox.js"></script>
<style type="text/css">
<!--
body {
background-color: #CCCCCC;
}
-->
</style>
</head>
<body>
<cfdirectory
directory="C:\newservers\History\slideshow\#ID#\"
name="ImageDirectory"
filter="*.jpg"
sort="datelastmodified DESC">
<cfoutput query="ImageDirectory">
<div align="left" class="floatbox" data-fb-options="doSlideshow:true navType:overlay slideInterval:3 group:Images caption:`Date: #ImageDirectory.datelastmodified#`">
<a href="/slideshow/#ID#/#ImageDirectory.name#">Slideshow</a>
</div>
</cfoutput>
</body>
</html>
There was no response to my question from the experts so I deleted it in hopes this time I might get some help, which is urgently needed.
I tried the floatboxjs.com forums and the administrator there seems to have big problems with ego and may not want to admit he has no answers, so, this seems to be our only hope.
=============
We're using FLOATBOX in a dynamic page. Everything works fine but when the code is placed inside a CFOUTPUT query, the start image or start text is duplicated (seen more than once). It's a loop I can't seem to figure out. It's just a simple slideshow but I can't quite get how to get the entry into the slideshow from duplicating itself.
The images in the slideshow are named numerically, based on the INT 4 PK number in SQL 2000 database. So the output query is dynamically generated. I need the caption to be dynamically created also, as well as the name of the file so that's why it's included in the cfoutput query.
In this case I'm just using the output of a cfdirectory but I'll also insert the output of a matching database query to match the ID number, so don't worry about that. All I need is to figure out how to NOT display the start image or text (whichever I use for the user to start the slideshow) but not duplicate it as the CFOUTPUT is doing.
Hope this makes sense. Just have to figure out how to place the start of the slideshow so the start text or image is not shown more than once.
We're using cf8 and sql2000 and will not be upgrading.
See my snippet.
ASKER
There are no nested cfoutputs, just the one cfoutput query, which displays each #ID# data type 4 PK, and if the start link is attached to one of them, naturally it will be repeated for each ID. I need to know a way to move the start link out of the loop but still allow the #ImageDirectory.datelastmo dified# to be part of the loop so each ID displays the datelastmodified date, which is important for me to retain.
Does that help?
Does that help?
ASKER
Jester_48: What do you mean, the actual code? I gave the actual code. Here it is again below:
This page is linked to from a FORM on a previous page and the numeric ID is passed. That ID is the PK INT 4 ID for each story/image. The ID number is the folder number for each story.
As an example, if the ID is 256, then we will be looking at the following folder to see if there may be images for a slideshow;
C:\newservers\History\slid eshow\253\ "
If images are found in that directory, then the slideshow should begin when the user clicks on some start text or image. I want the user to have that choice so the slideshow does not auto start.
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2">
<title>Select Slideshow Test</title>
<link type="text/css" rel="stylesheet" href="/floatbox/floatbox.c ss" />
<script type="text/javascript" src="/floatbox/floatbox.js "></script >
<style type="text/css">
<!--
body {
background-color: #CCCCCC;
}
-->
</style>
</head>
<body>
I'll later first check to be sure the directory exists, but for now, let's assume it does.
<cfdirectory
directory="C:\newservers\H istory\sli deshow\#ID #\"
name="ImageDirectory"
filter="*.jpg"
sort="datelastmodified DESC">
<cfoutput query="ImageDirectory">
<div align="left" class="floatbox" data-fb-options="doSlidesh ow:true navType:overlay slideInterval:3 group:Images caption:`Date: #ImageDirectory.datelastmo dified#`">
<a href="/slideshow/#ID#/#Ima geDirector y.name#">S lideshow</ a>
</div>
</cfoutput>
</body>
</html>
This page is linked to from a FORM on a previous page and the numeric ID is passed. That ID is the PK INT 4 ID for each story/image. The ID number is the folder number for each story.
As an example, if the ID is 256, then we will be looking at the following folder to see if there may be images for a slideshow;
C:\newservers\History\slid
If images are found in that directory, then the slideshow should begin when the user clicks on some start text or image. I want the user to have that choice so the slideshow does not auto start.
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-2">
<title>Select Slideshow Test</title>
<link type="text/css" rel="stylesheet" href="/floatbox/floatbox.c
<script type="text/javascript" src="/floatbox/floatbox.js
<style type="text/css">
<!--
body {
background-color: #CCCCCC;
}
-->
</style>
</head>
<body>
I'll later first check to be sure the directory exists, but for now, let's assume it does.
<cfdirectory
directory="C:\newservers\H
name="ImageDirectory"
filter="*.jpg"
sort="datelastmodified DESC">
<cfoutput query="ImageDirectory">
<div align="left" class="floatbox" data-fb-options="doSlidesh
<a href="/slideshow/#ID#/#Ima
</div>
</cfoutput>
</body>
</html>
Hi,
Let's Discuss your issue from scratch, Can you show me some code online, if possible, or if not possible i would love to have files to check and create dummaty images what is goinf wrong!
Let's Discuss your issue from scratch, Can you show me some code online, if possible, or if not possible i would love to have files to check and create dummaty images what is goinf wrong!
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
My own solution. I already gave the reason in my solution.
nothing in what you have shown will cause a duplicate output, nested cfoutputs though might, show us the actual code.