You need to set your server up to actually process python files. Doing so varies widely depending upon OS, server software and versions. You might want to Google for it or ask around on a forum dedicated to server configuration.
Jamie Holly http://www.intoxination.net http://www.hollyit.net
On 11/13/2012 8:00 PM, Tim Johnson wrote:
- Jamie Holly hovercrafter@earthlink.net [121113 15:42]:
In Drupal 7, jQuery runs in no-conflict mode, so you can't use $ unless it's wrapped. Change $ to jQuery.
:) You nailed it all right! Only problem now is that the cross-domain kicks in. Error message:
"XMLHttpRequest cannot load http://localhost/cgi-bin/cgitest.py. Origin http://localhost:8080 is not allowed by Access-Control-Allow-Origin."
So, I copied cgitest.py to scripts and now the function call is [code] jQuery('#content').load('http://localhost:8080/drupal/scripts/cgitest.py');" [/code] now I get the entire file as content of the DIV : I.E. #!/usr/bin/python print "Content-Type: text/html\n\n" print "HELLO THERE" How do I capture the stdout only?
thanks for the quick reply