p2p.wrox.com Forums

p2p.wrox.com Forums (http://p2p.wrox.com/index.php)
-   BOOK: ASP.NET 2.0 Instant Results ISBN: 978-0-471-74951-6 (http://p2p.wrox.com/forumdisplay.php?f=252)
-   -   How to add 5 more photos (http://p2p.wrox.com/showthread.php?t=61707)

js32821 September 2nd, 2007 02:13 PM

How to add 5 more photos
 
How could I add 5 more photos to each original photo and see those pictures after click it?

i.e:

      Photo1
      --Photo1.1
      --Photo1.2
      --Photo1.3
      --Photo1.4
      --Photo1.5

      Photo2
      --Photo1.1
      --Photo1.2
      --Photo1.3
      --Photo1.4
      --Photo1.5

Thanks,
js32821


Imar September 2nd, 2007 02:20 PM

Huh?

Can you elaborate? What chapter are you referring to?

Imar

---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004

js32821 September 2nd, 2007 11:57 PM

Chapter 7 - Photo Album

Actually, I want add 5 detail photos to each main photo.

i.e: after click in a Collection(photo), the system will show all photos available for that Collection. Then when I click in one of those photos, I would like to show selected photo and 5 more photos showing different angles of the selected photo.

Thanks,


Imar September 3rd, 2007 11:16 AM

Here's what I would do conceptually.

1. Extend the Photo table with a ParentId

2. When inserting the main picture, leave this ParentId empty.

3. Redirect to a new page and forward the new PhotoId of the picture you just inserted.

4. On this new page, allow the user to insert 5 (or any number) of pictures and save them in the database. Pass the Id of the first image from step 3 in the ParentId picture.

5. When you display the main PhotoPicture you can query its children using something like

SELECT .... WHERE ParentId = Id

where Id is the ID of the main picture.


Does this help?

Imar


---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004

js32821 September 3rd, 2007 12:40 PM

I am gonna try this.
Thank you for your help.

I really appreciated.

js32821


Imar September 3rd, 2007 12:48 PM

You're welcome. Good luck.

Imar


---------------------------------------
Imar Spaanjaars
http://Imar.Spaanjaars.Com
Everyone is unique, except for me.
Author of ASP.NET 2.0 Instant Results and Beginning Dreamweaver MX / MX 2004


All times are GMT -4. The time now is 01:46 AM.

Powered by vBulletin®
Copyright ©2000 - 2019, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.