codetoad.com
  ASP Shopping CartForum & BBS
  - all for $20 from CodeToad Plus!
  
  Home || ASP | ASP.Net | C++/C# | DHTML | HTML | Java | Javascript | Perl | VB | XML || CodeToad Plus! || Forums || RAM 
Search Site:
Search Forums:
  drag and drop online test  twinky at 16:42 on Sunday, September 28, 2003
 

hi..

i'm very new in using java script. i just want to know how to code for my problem. i want to drag a picture to a box given and mark will be calculated if the user drag to the correct box.

what should i do. please help me


  Re: drag and drop online test  Troy Wolf at 16:16 on Monday, September 29, 2003
 

Since you are starting at the very beginning of this learning journey, try to find a website that does this. I suggest you search for HTML Drag & Drop on Google. I did this and found several website including these two.

Here is one site that is designed to help you accomplish your goal:
http://javascript.internet.com/page-details/drag-n-drop.html

Here is one website that offers image drag & drop. You could steal (um, leverage) the javascript from here.
http://www.bunnysneezes.net/page16.html
Don't ask me what this website is above! I'm not endorsing it. I'm just saying it has script that you can probably copy, tweak, & use.

Enjoy!
Troy Wolf: site expert
Shiny Solutions


  describe...  twinky at 15:52 on Tuesday, September 30, 2003
 

hi.

i'm sorry if i made a confussion for u..

let i give u a clear define of my project

i just want to make a prototype for drag and drop online test. i'm going to prepare a test bank for the test. the online test is for the student. it will be a drag and drop test. the test need the student to drag a picture to a right box given.. for example, there are 4 pic on the top of the screen. and on the bottom of it, there are 4 box which are boxes with the name of the picture. student need to drag the pic to the right box according to the name. the student will fill the all 4 boxes with dragging the 4 pic given and then they move to the next drag and drop question.at the end of the test, the mark will be given to the students when the student click the submit button. the mark will be calculated for the right pic drag on the right box.

so, i have a difficulty to code the mark for it..that's my problem..did u get it? i'm very happy if u can help me as soon as possible.

bye


  Re: drag and drop online test  Troy Wolf at 16:10 on Tuesday, September 30, 2003
 

I think I understand clearly what you want, and I think the links I provided should give you enough code to figure out the hard parts.

Use the first link I gave you. That code knows which id you are dragging, and it knows the position of where you are dropping it. So if you know the position of your correct box, and you give each of your pictures an ID....you can know when an ID (picture) is dragged to the correct box.

The hardest part is how to accomplish the drag & drop -- not knowing which item is dropped where. So that first link gives you code to look at and figure out how to do what you want.

I don't currently have time to code your solution for you. I'd rather teach you to fish than give you a fish anyway. Let us know how it goes.
Troy Wolf: site expert
Shiny Solutions


  i`ll try first...  twinky at 07:12 on Wednesday, October 01, 2003
 

actually i hve a very limited time to complete this project..and i'm affraid that i can't finish it because i have many more project to do...but i will try first..but this project do really impact my pointer in my result...
thakns a lot..
-me-

  marking problem...  twinky at 05:30 on Tuesday, October 07, 2003
 

hi guys..
i'm success in dragging the pic but i have a difficulty in marking the quizzes. how can i set the mark. when the student drag a pic to a correct box, the mark will be calculated for it...can u plez help me to code it...
-me-








CodeToad Experts

Can't find the answer?
Our Site experts are answering questions for free in the CodeToad forums








Recent Forum Threads
•  XML- Passing parameters are Latitude and Longitude.
•  Re: Format Date time issue....
•  Re: How to freeze the web page when displaying progress bar?
•  Re: Help! IFrames!
•  Re: Help: Trouble with z-Index and SELECT lists
•  Re: HOW CREATE LINE CHARTS IN ASP.NET
•  How to store and retrieve document into database
•  Re: text field multiple
•  Re: after updation of a table open another program .. need help


Recent Articles
Communicating with the Database (Using ADO)
MagicGrid
Simple Thumbnail Browsing Solution
Type Anywhere
A Better Moustrap: FmtDate to replace FormatDateTime
ASP.NET Forum Source Code
Internal Search Engine
Javascript Growing Window
Simple date validation
Search engine friendly URLs using ASP.NET (C#.NET)


Site Survey
Help us serve you better. Take a five minute survey. Click here!

© Copyright codetoad.com 2001-2005