Where Is The "javascipt Console" In 9.00?
Jul 27, 2006I am new to Opera and tried to use its "javascipt console" and only saw
"Java console" and "Error console" under tools|advance....
I am new to Opera and tried to use its "javascipt console" and only saw
"Java console" and "Error console" under tools|advance....
So, what I am trying do to is to manage some classes with javascript.
It's working, but there are some things that I don't understand...
Next is my sample code, and I have indicated the questions in comment
Thanks for the help (I am working with IE 6)
I'm currently experiencing a problem using ANY (!) JavaScript in Mozilla - nothing seems to be working. For example (from p2 of JavaScript 101 - Part 1):
javascriptpenWindow('/examples/js101/seefirst.html',400,200);
Causes the following error: openWindow is not defined.
I've also tried various other JavaScript examples and everything returns an error.
I'm tried two different PCs running Win2K and tried Mozilla 1.4 and 1.5. I've already checked that JavaScript is enabled for Navigator.
How can I inform a Javascipt, that must submit my Applet's data, that this same Applet has produced the data in question? Or in other words, is there any way to call a JavaScript junction within the Applet? Is it the best way? What do you suggest?
View 1 Replies View RelatedIs there a currency javascipt function that will automatically put the $ in and 2 decimals? Example:
7.99 becomes $7.99
8 becomes $8.00
2 * 8 becomes $16.00
I have developed a very nice javascript-based navigation structure. My
customer wants to have a flash film on his very first site which
already has to have this navigation.
And now the effect: Whenever the flash film is running, the navigation
submenus are not displayed ABOVE this flash film, but BEHIND it.
As far as I have tried, there is no way to influence this behaviour
with the "z-index" and different values.
Is there any other way to make the navigation submenu seen or - in
other words - is there a way to put the flash film "a layer back"?
I have firebug installed in my firefox browser, but I can't get console.log, console.debug or console.trace to work. My console window remains empty despite all my efforts. For example I have some code which throws up an alert box ( alert ('here is an alert') so I know 100% that it is being executed. If I now place the line
console.log("please log this to the console");next to it, nothing gets written to the console. I also have firephp installed and this is logging to the console for my php code absolutely fine
I have a loop in Javascript, I want to run console.log() in a specific iteration, and then terminate. What is the best method to go about doing this? I'm wanting something like Perl's
die Dumper @foo;
How to use javascript's console log and what is the purpose of it ?
View 1 Replies View RelatedI'm just getting started with nodejs. For now my purpose with this tech is to finish a book (The Definitive Guide to HTML5) where it's covering ajax and is using node.js to send the code back. I do want to learn the basics while I'm at it.
What I have so far: I understand that node.js lets me write my own web server. I understand that nodejs is actually 'C' and it just allows for us to write JS to make a web server and do other back-end tasks.
I've installed node.js on my windows 7 64 bit machine. I have found out that I can run a script on a node by right clicking it and selecting open with "Evented I/O for V8 Javascript".
What I want to know is how do I run node from the command line? What are the boundaries of the JS file that I write? From what I can tell, I can goo all over the place with my js file traversing my filesystem as I please. If this is true, how is it safe? It seems like it would be easy to hijack some simple js file and go all over the servers file system at will for a hacker....If someone could fill in these holes.
Is it possible to read the output of console.log with jQuery?
I need to check for some error, and handle them.
What can I do to find out what the errors in the error console mean?
View 7 Replies View RelatedI'm trying to output things to the Console to track errors but everytime I try:
console.log(values);
it says "Console is not Defined"
I'm using firefox javascript console to find errors within my webpages.
I've found the following errors:
"Expected colour but found '#'. Error in parsing value from property 'color'. Decleration dropped. Line 0"
" Error in parsing value from property 'display'. Decleration dropped. Line 0"
How can i go about finding which lines of code are creating these errors? as it tells me its on line0, this gives me no clue as to where to look.
everytime i test my websites in ie (which should be done seperately
from ff) the console shows me the error and the line number.
problem: it shows me the line number of the file of the error's origin,
but it shows me the main html file as file name.
i am developing a bigger project with many js files and often i have to
go through all js files cause i don't know really which file is meant.
I find myself having to dynamically create HTML code, and have found
that the usual way you see to do this is an unreadable mess, like this:
blah('<span id="' + id + '"><a href="' + link + '">' + linkText +
'</a></span>');
So instead, I would like to do something more like the variable
interpolation in Perl and other languages:
blah(XXX('<span id="@id"><a href="@link">@linkText</a></span>'));
The XXX function here would interpolate the values of any variables
named with a @ prefix into the string. Why @? Why not?
So using my favorite JavaScript console (FireBug), I typed the following
and ran it:
x = "hello world";
y = 42;
z = "--@x/@y--"
z = z.replace(/@(w+)/g, function (dummy, v) {
return eval(v);
});
alert(z);
And it works. The alert box shows "--hello world/42--" as expected.
Okay, so now let's turn it into a function:
x = "hello world";
y = 42;
function XXX(s) {
return s.replace(/@(w+)/g, function (dummy, v) {
return eval(v);
});
}
alert(XXX("!!!@x~~~@y!!!"));
And again, it works. The alert box shows "!!!hello world~~~42!!!" as
expected. I should be able now to just drop this *same* code into a
<scriptsection of a web page, right?
Wrong. If I take the *same* code as my second example and plop it in a
web page, the alert does not show the same thing as when in FireBug's
console. It shows the same string passed to XXX, unchanged.
Other experimentation tells me that when placed in a web page, the
anonymous function to do the eval call is never invoked, which suggests
that the regular expression didn't match.
I've only tried this in FireFox 2 and IE 7, but if it doesn't work
properly in either of those, I really don't care about the other browsers.
My guess is there is a difference in the execution environment of
FireBug's console (or likely, any JavaScript console) and the execution
environment of a web page. The questions are what is that difference,
and how do I make my XXX function work properly?
I'm trying to append sth. like this:
<script>
$('#text').load('test.html h1'); // loads h1 content out of test.html - works fine
$('#text h1').append('test'); // should append 'test' to h1 - does nothing!
[code]....
Is this a bug or a feature? In this code:
Code:
for (var ur=longestRow; ur>1; ur-- ) // adjust rows above it
{ console.log("going to call spaceRowAbove("+ur+")");
spaceRowAbove(ur);
}
If Firebug is enabled the message is logged and the function is executed.If Firebug is NOT enabled, the function is not executed.If the log statement is commented out, the function IS executed.Wouldn't it be more reasonable for the interpreter to ignore just the console call, rather than the whole loop?Or is it just me and my Firefox 3.5.5?
Firefox has a Javascript Console that has 3 panels besides "All" and "Clear": "Errors", "Warnings", "Message".
Does anyone know a way to log a message in the Message panel with JavaScript? That would really help debugging. I know there's a way involving XPCOM, but that only works with "trusted" scripts, and scripts loaded thru html aren't trusted.
I've come across a strange issue with the console.log function in WebKit.Here is the code I have that is causing the issue:
Code:
var myArray = ['Brian', 'Kayla', 'Mom', 'Dad'];
myArray.shift();
console.log(myArray);[code].....
I am getting $document.ready(function() not defined in the firebug console. I have seen that in most cases this is caused when the jQuery core is missing or the path is invalid. I do not believe this is the problem in my case becuase firebug shows the code as being loaded successfully and it is readable.
I have the following scripts in my head;
<script type="text/javascript" src="jquery-1.4.2.min.js"></script>
<script type="text/javascript" src="jquery.validate.js"></script>
<script type="text/javascript">
jQuery.validator.addMethod(
"selectNone",
function(value, element) {
if (element.value == "none") {
return false;
}}, .....
Any of you know how can I stop an exit console when the visitors lefts my site trough a form button?
The below code is the function that opens the console or popup.
**********************************
<script language="JavaScript">
function exit(){ window.open('XXXXXXX');}
</script>
**********************************
Then on the body tag
************************
<body onUnload="exit()">
************************
I'm having a weird problem using ajax. I use ajax to create a input field inside a form.
like this:
Before Ajax script
Code:
After Ajax script
Code:
The Ajax script works perfectly. the problem occurs when I try to send the form with the new field. The form doesn't send the field data to test.php. And more weird is that it works on IE, only on FF the problem occurs. Nothing shows in the Errors Console, and I have the last Firefox version.
I am working on a form inside my administration console to upload images with PHP. In my form I have the following:
[Code]...
The onchange submits the form to a seperate PHP file (sent in the action of the form) dedicated to handling the uploading of the images, while the submit button(not shown in code) will submit the rest of the form through ajax. In order to use 1 file field, Ive read that to get an ajax looking effect I need to use an iframe, so I added the IFrame into the HTML and got the effect working right (without actually uploading the files.)
Now I want to limit the ammount of images to 8. Which is where the hidden field came in. So i've got to figure out a way to count the successful uploads, or add them as we go. At which time that number turns to 8, the script will disable the file field from anymore uploads. Problem is I have no clue where I need to go within my php file to make this happen. Here is my php file with javascript added in:
Code:
<?php
// lets go ahead and get this image uploaded
?>
<script language="JavaScript" type="text/javascript">
var parDoc = window.parent.document;
var upldcnt = parDoc.getElementByID('upload_cnt').value;
[Code]....
I have been trying to get the feed from this url: [url]
But it keeps returning "data.responseData is null in the firebug console"
I am working on a simple javascript craps game program. I need some advice since it won't display who the winner is, keep tally of who wins/loses, and the number of total games played. After using the error console there's an error with document.forms [0].thrower.value not being defined.
<html>
<head>
<title> JavaScript Craps Game</title>[code]....