473,372 Members | 1,027 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,372 software developers and data experts.

Debugging simple script under Aptana

Hi,

First, is this an appropriate NG for talking about debugging
JavaScript in Aptana?

Assuming it is, I'm trying to get a script to read an external text
file and display the text somehow. The script just dies in the file-
read operation, with no symptom. I tried unsuccessfully to get the
Debugger to run the HTML file.

I put up the following on my personal website:

1. The HTML file: http://home.comcast.net/~CaptQueeg/DemoFileIO.html
2. Some Aptana settings: http://home.comcast.net/~CaptQueeg/A...ugSettings.jpg

Did any obvious mistakes jump out at you? Do my Aptana settings
suggest a reason why I can get anything happening under the debugger?

Thanks in Advance,
Richard

Key software: WinXP-Pro/SP2, FireFox 2.0.0.6, Firebug IE 7.0, Apatana
0.2.9.16696, Java JVM 1.5.0_11-b03

Other S/S: Ruby 1.8.2-15, Rails 1.1.6, Gem 0.9, MySQL 5.0.27-nt,
SciTE 1.72, SeaMonkey 1.1.4, OE 6.0, IE7,Apache Tomcat/5.5.12,
MS Office 2003 SP2, MSDevEnv 2002 v. 7.0.9466. .NET Frwk 1.0,
AVG-Free 7.5.476, Prevx1 2.0.2.23, Startup Cop Pro 2.03

Sep 15 '07 #1
4 3142
RichardOnRails said the following on 9/14/2007 8:36 PM:
Hi,

First, is this an appropriate NG for talking about debugging
JavaScript in Aptana?
Probably not and if my curiosity hadn't got the best of me wanting to
know what Aptana was I wouldn't even have replied.
Assuming it is, I'm trying to get a script to read an external text
file and display the text somehow. The script just dies in the file-
read operation, with no symptom. I tried unsuccessfully to get the
Debugger to run the HTML file.
The problem is your call to the undefined fopen function. fopen is,
typically, a PHP function that opens a file. If you want to read/write
to the local file system then you might try the group FAQ which has an
entry dedicated to this very question:

<URL: http://jibbering.com/faq/index.html#FAQ4_3>
I put up the following on my personal website:

1. The HTML file: http://home.comcast.net/~CaptQueeg/DemoFileIO.html
2. Some Aptana settings: http://home.comcast.net/~CaptQueeg/A...ugSettings.jpg

Did any obvious mistakes jump out at you?
The error message was very intuitive as it pointed straight at the fopen
call.
Do my Aptana settings suggest a reason why I can get anything happening under the debugger?
No idea unless Aptana has a callable fopen function.

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Sep 15 '07 #2
On Sep 14, 10:04 pm, Randy Webb <HikksNotAtH...@aol.comwrote:
First, is this an appropriate NG for talking about debugging
JavaScript in Aptana?

Probably not and if my curiosity hadn't got the best of me
I've heard it killed a cat. This time it snared a knowledgeable
answer. I glad for that.
The problem is your call to the undefined fopen function. fopen is,
typically, a PHP function that opens a file.
I'm new to JavaScript and Aptana. I found an example on the Web
offering this code, but I didn't see any mention of PHP. But thanks
for alerting me to the problem.
<URL:http://jibbering.com/faq/index.html#FAQ4_3>
Nice site; thanks.

I've just found some AJAX routines that may serve my purpose despite
FAQ 43; I'll see.
The error message was very intuitive as it pointed straight at the fopen
call.
You're so right. I never noticed that red warning in the Status Bar.
I know from the alerts the the "fopen" line was problematic, but I
didn't know exactly what the problem was. Thanks for pointing that
out, Randy.

Best wishes,
Richard
Sep 15 '07 #3
RichardOnRails said the following on 9/14/2007 10:35 PM:
On Sep 14, 10:04 pm, Randy Webb <HikksNotAtH...@aol.comwrote:
><URL:http://jibbering.com/faq/index.html#FAQ4_3>
Nice site; thanks.

I've just found some AJAX routines that may serve my purpose despite
FAQ 43; I'll see.
If you are trying to open a local file on the client machine then AJAX
isn't the solution. It will "work" when testing locally but it won't
work when testing from a server. Or, are you trying to open a file on
the server?

--
Randy
Chance Favors The Prepared Mind
comp.lang.javascript FAQ - http://jibbering.com/faq/index.html
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Sep 15 '07 #4
On Sep 15, 12:07 am, Randy Webb <HikksNotAtH...@aol.comwrote:

Hi Randy,

Thanks for your follow-up.
If you are trying to open a local file on the client machine then AJAX
isn't the solution. It will "work" when testing locally but it won't
work when testing from a server. Or, are you trying to open a file on
the server?
Initially, I'm working on my client machine, where the text file is
in the same directory as the HTML file, or a sub-directory.

When I put it up on a web server, the same relationship will obtain.

I haven't worked on that today, because I got distracted by another
question: how to have multiple <script type="text/javascript"
src= ...entries. I just solved that, so my day ends nicely.

Regards,
Richard

Sep 16 '07 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Dale | last post by:
Windows XP, Apache 2.0.54, PHP 5.0.4, MySQL 4.1 running on my local machine I want to migrate to more sophisticated debugging: setting breakpoints, watching variables, step into/over, etc. I...
25
by: Jeff | last post by:
Use the MS Script Editor included free with MS Office 2002 and above, for debugging Internet Explorer (IE). This subject is of great interest to many JS developers, as there is no obvious, low...
0
by: ZMan | last post by:
Scenario: This is about debugging server side scripts that make calls to middle-tier business DLLs. The server side scripts are legacy ASP 3.0 pages, and the DLLs are managed DLLs...
23
by: keyser_Soze | last post by:
I have MS Visual Studio 2003 on Windows XP Pro. I have IIS running on this machine and I am trying to debug some existing code which has both ASP and ASP.NET components. When I try and launch...
1
by: Jim Land | last post by:
Anyone using Aptana? Opinions about it? It's a web development IDE for JS, HTML, and CSS. Cross-platform, free & open source. http://www.aptana.com/index.php
4
by: Greg | last post by:
I have a very simple Visual Basic .NET 2003 class library project ClassLibrary1 configured to run an external program (in this case C:\WINDOWS\system32\wscript.exe), in the Debugging Configuration...
3
by: levilista | last post by:
I just downloaded firebug and watched a video, how to debug javascript, but it doesn't work for me. If I set a breakpoint, it won't stop there, even if I reload the page.
1
by: JCD | last post by:
Hello. I 'm trying to use Aptana as a plugin of Eclipse. I have the free version and it works fine but I can't get the message when there is an exception when I run the javascript code. Can...
6
by: Morgan Packard | last post by:
Hello, Wondering what everyone's experience with breakpoint debugging is here. I've been using firebug for a few years and, while I'm delighted to have _some_ debugging ability, I've found it to...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.