PDA

View Full Version : Problem running ASP scripts on my Mac!




Littleodie914
Jul 7, 2007, 07:27 PM
Hey guys, I'm trying to learn AJAX, and I'm having a problem running any ASP scripts. I'm pretty sure the code is all accurate, as I finally resorted to just pulling the scripts off the tutorial's server. (Which work great when I'm browsing their site.)

The problem is, my ASP script is very simple, and looks like:

<%
response.expires=-1
response.write(time)
%>

Then I have an HTML page that just sets the value of a text input box to the xmlRequest's responseText. Instead of actually displaying the time though, it just displays "<%" (the first line of the file.)

If I change the ASP script to read:


Hi there
<%
response.expires=-1
response.write(time)
%>

Then the input box is set to "Hi there." Can anyone explain this mystery for me? If necessary, I can post the HTML file too, but it's pretty basic and I don't believe that's the problem. TIA! :)

Edit: I've tried both previewing the files locally in Safari, as well as transferring them to my server and running them over the web.



Thinine
Jul 7, 2007, 08:39 PM
ASP is server side scripting language that's Windows only. You should look into something like PHP if you want it to run on OS X.

Littleodie914
Jul 7, 2007, 09:26 PM
ASP is server side scripting language that's Windows only. You should look into something like PHP if you want it to run on OS X.Ah, that would certainly explain it. :)

Thanks so much!

stadidas
Jul 8, 2007, 04:49 PM
You can use Mono (http://www.mono-project.com/Main_Page) to develop using the .Net Framework on the Mac.