Ask a Question related to Coldfusion Database Access, Design and Development.
-
DS2 #1
Cant get data from table after clicking url link. Pleaseadvise.
I am setting up an auction listing website. I have an upload page delivering
data to a table called auctions which contains the columns of name, date, time,
address, city, state, zip, etc. I view the data in that table thru web page
called auctiondates.cfm. This page has the columns of name, date, time, etc.
Each row has its pertinent data listed of course for each individual auction.
Its actually similar to the actual db table except for sorting. Upload and
viewing functionality works fine. I need to be able to click on the column name
of a particular auction and get a new page with further details about that
paritcular auction that I clicked on. I am not concerned about the final page
content as it will be populated by different table data. Any ideas would be
appreciated.
DS2 Guest
-
Clicking on link makes page jump to top
Hello, I have a page where a link will dynamically hide and show a table (using javascript to change the table's style display:none and... -
Starting a video in a layer when clicking on a link
Hi I was wondering if there was any dhtml or java script for showing a video clip in a layer when clicking on a link. what im realy aiming for is to... -
Sort a repeat region in a table by clicking on the table headers
Sort a repeat region in a table by clicking on the table headers for ASP some help on this topic pls.. Rgds MeTin -
NEW User: How do I display table on DataGrid without clicking on '+'.
Hi, I have been trying display data from an Access database in my C# form. I have got to the point where I have stored data from the database into... -
How can I send data to a Flash file (swf), by clicking on a html link?
How can I send data to a Flash file (swf), by clicking on a html link? (my english is bad) I have a little Flash movie, inside my html document... -
Dan Bracuk #2
Re: Cant get data from table after clicking url link.Please advise.
add a query string to the href attribute in your anchor tag. Look at the
address bar in your browser right now. The url part end with messageview.cfm
and the query string starts with the question mark. Notice that there is only
one question mark and every other variable value pair is separated by an
ampersand.
Dan Bracuk Guest
-
DS2 #3
Re: Cant get data from table after clicking url link.Please advise.
Thanks for the reply. I understand the concept, however I missing something.
The view page is [url]http://cftest.deskmedia.com/auctiondates.cfm[/url] if you want to
check it. I need to be able to click the name link which pulls up a page called
customers.cfm and then that page be populated with related data from a table
called auctiondates based on the url parameters passed to it. Perhaps my
methodology is incorrect. Maybe there is an easier way.
DS2 Guest
-
Dan Bracuk #4
Re: Cant get data from table after clicking url link.Please advise.
The location link is perfect. The name link, not quite as good, yet.
You want it to eventually resemble this
...customers.cfm&auctionid=2&auctiondate=2006-07-25
which means your code will have to resemble this:
<a
href="customers.cfm?auctionid=#auctionid#&auctiond ate=#dateformat(auctiondate,
'yyyy-mm-dd')#
Dan Bracuk Guest
-
DS2 #5
Re: Cant get data from table after clicking url link.Please advise.
Thank you. I see the auctiondates.cfm page passing the parameter...
[url]http://cftest.deskmedia.com/customers.cfm?auctionid=14;[/url] which is the proper id
of auction link that I clicked on. I just need to figure out how to get the
customers.cfm page to take the id and match it against the id of the proper row
in a table and then output all the data in that row so as to be visible on the
customers.cfm page. If there is a page on the net about doing this I have not
seen it yet.
DS2 Guest
-
DS2 #6
Re: Cant get data from table after clicking url link.Please advise.
I got it. Thanks again Dan. Here is what I used...
<cfquery datasource="cftest" name="urlpass">
SELECT *
FROM auctions
WHERE ID=#url.auctionid#
</cfquery>
<cfoutput query="urlpass">
<p>Location: #address#, #city#, #state# #zip#</A></p>
<p>Date: #month# #auctiondate#, #year#</p>
<p>Time: #auctiontime# #ampm#</p>
DS2 Guest
-
Dan Bracuk #7
Re: Cant get data from table after clicking url link.Please advise.
why don't you write a query in the customers.cfm page that uses the url variable in the where clause?
Dan Bracuk Guest
-
DS2 #8
Re: Cant get data from table after clicking url link.Please advise.
Just started learning CF last week, so there probably are other ways to get the
same result. Unfortunately, this project has a short time frame so I just need
to get it working; even if its ugly :)
The query code above is in the customers.cfm page; unless you are referring to
some other way to code it. I just know that when I click on various auctions
listed on the auctiondates.cfm page, the proper id of the links is passed to
the customers.cfm page. This in turn does display the proper relevant data for
the particular auction of the passed id. Here is the line in auctiondates.cfm
that passes the id...
<A href="http://domain/customers.cfm?auctionid=#id#">#name#</A>
DS2 Guest



Reply With Quote

