Jump to content

Mootools 1.1 question


dennismonsewicz

Recommended Posts

I am having to develop an AJAX request application in Mootools 1.1 because of our legacy systems and am having some problems with my code

 

<script type="text/javascript" src="/media/system/js/mootools.js"></script>

<script type="text/javascript">
window.addEvent('domready', function() {
	$('click').addEvent('click', function(e) {
		e = new Event(e).stop();

		var input = $('test').value;
		var url = "http://www.myurl.com/test.php?mdn="+input;

		var ajax = new Ajax(url, {
			method: 'get',
			update: $('log')
		}).request();
	});
});
</script>

<input type="text" name="test" id="test" />

<p>
<a href="#" id="click">Click Me!</a>
</p>

<p id="log"></p>

 

When I run this code and click the link nothing happens... no error message, nothing... any ideas why?

 

I tried searching for some mootools 1.1 demos/docs and found demos111.mootools.com, and followed their tutorial line for line but cannot get my code to run...

Link to comment
https://forums.phpfreaks.com/topic/193348-mootools-11-question/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.