PDA

View Full Version : Ajax notepad: making it work ..help!



jeathrow
11-02-2006, 11:23 AM
Hello everyone, I found this script on the internet, and is pretty damn amazing. What ever you type in, it automatically gets stored in the notepads.

But when I used the code, I get an error box message saying "processXMLDoc : Unknown"

I plan to use it for my college website, but I have no clue as to what to do to fix it.

Following is the code:

First the index.htm



<html>
<head>
<meta name='keywords' content='Web,JavaScript,Scratch,Pad,Note'>
<script language="JavaScript" src="AJAXRequest.js"></script>
<script language="JavaScript" src="ScratchPad.js"></script>
<style type='text/css'>
body {
font-family: Arial, Verdona, Helvetica;
font-size: 11pt;
}
</style>
</head>
<body>
Instructions: Press the <b>Add</b> button to create a new scratch pad. Use <b>Show All</b> to show scratch pads you had previously hidden<br>
using the menu provided. System automatically handles saving entries.<br><br>
<input onclick="javascript: addSP('', event);" value="Add" type="button">&nbsp;&nbsp;&nbsp;
<input type='button' value='Show All' onclick="javascript: unhideSPs();">
</body>
</html>


Next, the AJAXRequest.js
http://www.b3ta.cr3ation.co.uk/data/js/AJAXRequest.js


And the scratchpad.js
http://www.b3ta.cr3ation.co.uk/data/js/ScratchPad.js


I get an error box message saying "processXMLDoc : Unknown"
I presume that might be related to AJAXRequest.js, maybe somewhere in the following code:

* <body onload="req.loadXMLDoc('http://localhost/MonkeySite/workerPage.cfm?theAge=41');">

What should I do to fix the error? HELP!
thanks in advance.. Jeathrow

djr33
11-02-2006, 12:01 PM
Linking to a page with the file on it would really help.

jeathrow
11-02-2006, 03:03 PM
Linking to a page with the file on it would really help.
Here s the page:
http://www.b3ta.cr3ation.co.uk/data/htm/scratchpad.htm

djr33
11-02-2006, 03:07 PM
Interesting.

Is there any other file(s)?
With AJAX, I'd generally expect php or something.

That is likely what is giving a bad response.

jeathrow
11-02-2006, 03:33 PM
* <body onload="req.loadXMLDoc('http://localhost/MonkeySite/workerPage.cfm?theAge=41');">
There does seem to be one, as this code snippet from AJAXRequest.js [http://www.b3ta.cr3ation.co.uk/data/js/AJAXRequest.js] suggests.

But I have no clue as to what type of document, or with what function.

djr33
11-02-2006, 03:36 PM
That would appear to be the issue, then.

localhost means "this server"
So... you should have a folder on the root of your server called "Monkeysite/workerspage.cfm

However, I don't know what it does. Also, you could change that line AND any others referring to the file to be another location/name, which might help.

VatsaL
11-02-2006, 04:58 PM
I found the page
http://dkpinteractive.ath.cx/ScratchPad/ScratchPad.htm
http://www.js-examples.com/forums/viewtopic.php?t=1340

still cant get the .cfm page or make it function!

jeathrow
11-02-2006, 08:38 PM
yes thats wat i was looking for but i dunno the code

how should i get the .cfm page or its functions?

HELPPPP!!!

jeathrow
11-03-2006, 11:36 AM
Does anyone know wat to substitiute for tht function?
what do i do to that .cfm file?? i cant even get hold of it on from the local host link

HELP!!!! really desperate!"
jeath