JavaScript is the original and common name applied towards most flavors of a scripting language that originated on NetScape Navigator. Use this tag for questions regarding common implementations of ECMAScript, JavaScript, JScript, etc. JS does not typically refer to its ECMA-cousin, ActionScript.

learn more… | top users | synonyms (1)

-3
votes
1answer
47 views

Please help, I'm trying to open a dialog box using ajax inside kendoGrid row double click but I've encountered error [on hold]

Here's the complete javascript: <script type="text/javascript"> var gridReadUrl = '@Url.Action("LoadServices")'; var getServiceUrl = '@Url.Action("GetAService")'; var GridExample = function ...
6
votes
4answers
869 views

Client Side Coding: How to prevent malicious use?

Over the last few years, the trend for client side (browser) apps has really taken off. For my latest project, I have decide to try and move with the times and write a client side app. Part of this ...
0
votes
0answers
11 views

Need help with simple angularjs programming [migrated]

I am trying to do simple programming in angularjs. I have created two buttons. The first button has text "clickHere", and the second has no text. My task is when I click the button that has text, it ...
0
votes
0answers
29 views

JavaScript Compression and Caching of Assets

I'm working on an idea that i can't seem to find a good answer though hours and hours of searching, I'm planning a small Canvas/WebGL Application this application will be using WebSockets to talk to ...
2
votes
0answers
68 views

JavaScript Combination Inheritance Pattern

In the chapter of Professional JavaScript for Web Developers on OOP, Nicholas Zachas describes a JavaScript inheritance pattern which he refers to as combination inheritance. The basic idea is that ...
0
votes
0answers
37 views

Token based autorization for a web game

I am lead developer for a multiplayer game in a small startup company. I would like to present here my solution for token based authentication and hear your opinions about possible weak spots. I am ...
0
votes
0answers
28 views

Populating Google Maps with Markers from C# List [migrated]

I am trying to populate a javascript google map with a c# list of google map markers. I can get data in from public floats but not from the list. The list will be populated by the database but in this ...
8
votes
1answer
476 views

I know JavaScript really well, but i bomb coding interviews [on hold]

So I'm currently on a hunt for a new position as a Front-End Developer. I know JavaScript very well and can wax poetically about Closures, Currying, Prototypal Inheritance, Design Patterns, App ...
1
vote
1answer
113 views

Object Chain through an Interface

Say I have 3+ types of objects: function Sea() { var logs = [Logs]; this.getLog = function(ind){return logs[ind]} } function Log() { var bumps = [Bumps]; this.getBump = ...
0
votes
2answers
187 views

Whats the best way to build a HTML/AJAX site that requires login? [closed]

Let's say that hypothetically you wanted to build a website that delivered content to the visitors entirely using HTML and Javascript (AJAX to fetch server side data). The site would require login for ...
4
votes
4answers
255 views

How to write JavaScript while keeping HTML/CSS out of it

What is / are some recommended ways to write JavaScript as to control behavior of showing HTML on screen, while keeping well-maintainable code? Basically, I started to look for ways to keep HTML/CSS ...
2
votes
2answers
139 views

How to develop cross platform mobile applications with native UI and Javascript backend?

I want to build a cross platform(Android, iOS, Windows) mobile application. I want the UX of the application to be different on the different platforms so that it will be more platform specific and ...
-3
votes
0answers
72 views

Is Microsoft certification needed for a Web Developer? [closed]

I'm a web developer with 2 years of Experience. I want to know if Microsoft Web certification matters for me for a better future & money perspective also. Or should I go with technical knowledge ...
0
votes
0answers
22 views

What's the Content-Security-Policy-friendly way to hand data from the server to the browser on page load?

When developing for the web, I often find myself wanting to pass a few variables from the server scripts to my javascript - data pulled from a database, and set differently on different pages running ...
1
vote
2answers
159 views

Why a hashtable? Why not just a non-hashed associative array?

I've been learning about using a hashtable to efficiently check for items in a list without looping through the whole thing, but there's one thing that I don't get: Why hashed keys? It seems like: ...
0
votes
0answers
17 views

How do I get data from the Bitfinex web API using javascript [migrated]

Here is a link to their API documentation I would like to practice web programming by creating a bitcoin price ticker from scratch. My plan is to serve a script that makes api calls to exchanges to ...
0
votes
0answers
54 views

Malicious Code Mitigation/Discussion [closed]

A couple days ago, while reading the news on various current events from several different news websites, a window popped up and filled my screen. It was one of those malicious websites that ...
0
votes
0answers
17 views

ajax request not being called from javascript function in django [migrated]

This is a full flow which has to be taken care here. I am coding in Django/Python/Web Development. I have an html page which has got a dummy button which is triggering all the functions that I want ...
0
votes
0answers
55 views

Do I need to do something special to run ECMAScript 6 (JS 2.0) in Chrome? [closed]

I noticed someone suggesting a ECMAScript6 solution, utilizing the Set object on Code Review, and I can't figure out how to try that out. Even though the latest version of Chrome supposedly supports ...
2
votes
2answers
127 views

Best practices / reasons for String constants in JavaScript [closed]

In static languages like Java/C#, I commonly make use of constants for strings or numbers, rather than insert them into the code alone. However, I tend to avoid this practice in JavaScript. More ...
0
votes
3answers
176 views

How should I include jQuery in a library?

I'm writing a JavaScript graphing library using canvas which I am licensing under MIT, and I'm using jQuery, as well as a couple of other open sourced libraries, all under MIT. I'm also using bower to ...
0
votes
0answers
13 views

Online Shopping password keylogger risk [migrated]

Suppose I do an online shopping they are asking me to enter my card details like four digit number(whatever related to that) and they are asking me to enter the PIN number too. If I enter all this ...
0
votes
1answer
83 views

Javascript function should call python logic in django web development without additional triiger

I have been trying to solve this problem for sometime now. This is regarding django web development. I have an HTML page which has a Javascript function to upload an image file from the users local ...
3
votes
6answers
648 views

I need a JavaScript runtime environment [closed]

I'm reading books on JavaScript programming, and I need an environment like Python's IDLE to type JavaScript commands into and then see the results like you would in IDLE. Is there an environment ...
0
votes
0answers
28 views

Need help with Javascript/CSS to manipulate html table layout for bowling scorecard [migrated]

I'm trying to create a responsive table for a bowling scorecard. I want the table to split up depending on the width of the screen, preferably into thirds (where the first row would be frames 1, 2 ...
0
votes
4answers
103 views

HTML - Alternative for ID when ID is only unique within a certain scope?

So I feel like this should be a common question but I can't find the answer. Maybe I'm using the wrong terminology. Assumptions: IDs are supposed to be unique across the document. Class attributes ...
0
votes
3answers
218 views

Simple straight-line path algorithm [closed]

I need a simple pathfinding algorithmn to go from point A to point B. A* seems like an overkill because It doesn't matter wheather I hit walls or not and there's no terrain. I was wondering if there ...
0
votes
0answers
37 views

Binding in web frameworks - to frontend data or backend data?

AngularJS and other web frameworks provide data binding abilities (as in WPF). Is the UI bound to JavaScript variables on the frontend (web browser) or is it bound to the data in the server (via AJAX ...
1
vote
1answer
246 views

When does a Monad become a hammer?

I realize my precursory understanding on Monads is severely lacking in detail considering my knowledge comes mostly from Douglas Crockford's Monads and Gonads talk and complicated with my sevear ...
1
vote
2answers
91 views

Should I group all of my .js files into one large bundle?

One of the difficulties I'm running into with my current project is that the previous developer spaghetti'd the javascript code in lots of different files. We have modal dialogs that are reused in ...
0
votes
0answers
25 views

Deleting dynamic elements from a database

I have a select dropdown, with '+' and '-' buttons that add and remove items before submission. I would like to be able to remove the elements with the '-' button after they have been added to the ...
3
votes
2answers
188 views

Minimizability or readability?

I am authoring a lot of plugins for the content management system that I am writing. I believe it to be of utmost importance that script files (especially if they're plugins) should load quickly, ...
0
votes
0answers
375 views

disable print screen key using javascript [migrated]

i try to disable printscreen key in my website. code: <SCRIPT type="text/javascript"> focusInput = function() { document.focus(); }; processKeyEvent = function(eventType, event) { if ...
0
votes
0answers
20 views

Can't post data to php, Can't see why [migrated]

I have some data from a form that is being sent to a php script to send an email, it is from a template but I think it is wrong. I have isolated the part of the code that is to blame. The specific ...
0
votes
1answer
51 views

JavaScript: testing with undefined value

While learning more about IE’s documentMode property, I came across some sniffing code, which, of cause, fails in browsers like Firefox. However, a simplified version of the test would readas such: ...
0
votes
0answers
56 views

Javascript and SQL Lite (multi browser offline SQL/database query)

I'm in the elections division of my county and am trying to simplify a voter lookup method for our poll judges during election time. Currently we are using a clunky heavy application that the judges ...
0
votes
1answer
29 views

Creating a voting platform for submissions during timeperiod

I have a site where stories are submitted at any time by users. The staff would like the ability to create a voting period at any time. For example, they can choose to open up voting from today until ...
1
vote
1answer
47 views

Does ES6 help grow the Ecmascript standard library?

With all the noise about EC6, one thing that I realized I haven't heard about is expanding Javascript's standard library. Javascript has a fairly sparse standard library. You need a 3rd party library ...
0
votes
2answers
131 views

Is it a good idea for JS objects to draw themselves when the page loads?

So normally I would only use JS to modify the dom after the user interacts with something or some event goes off. This seems right for some reason. But I'm developing a widget based app where widgets ...
3
votes
2answers
105 views

What's a good way to make sure that locally serialized data can be deserialized in newer code?

Context: I'm working on an HTML 5 game without persisted state. Every time you refresh the page, you start at the beginning. People are requesting that they can start where they left off if they ...
2
votes
1answer
153 views

Will this “wireless” syntax for my framework make for good code structure / design?

I'm at the point where I'm getting into the freelance development of some complex web apps, and I would like to develop a light weight framework for my personal use, but I'd like to get some advice ...
0
votes
1answer
95 views

what does it mean when a nested function isn't assigned to a var?

I'm referencing this link about closures: http://stackoverflow.com/questions/111102/how-do-javascript-closures-work This is specifically about javascript. In the second answer with 956 votes, The ...
0
votes
0answers
47 views

Building SQL from multiple combinations of query parameters [migrated]

I have a node.js/express.js based REST application. In one GET service I am querying data based on different set of request parameters. I am looking for a better way to implement it. Following is my ...
0
votes
1answer
128 views

Dynamic query in Mysql

I'm doing a J2EE web application with Struts2, Mybatis and a MySQL database, so what I want to allow to the user is to be free to choose different parameters to perform a select to a table in the ...
0
votes
2answers
166 views

Working with Javascript classes the right way

Comparable questions have surely been asked before but I'd like to hear some words about my specific way of implementing Javascript classes. Let me first start with a Javascript example taken from a ...
1
vote
0answers
199 views

Efficient development process for Golang (or any backend) and JavaScript?

I am developing a web application. The frontend is a mix between JavaScript and server-side generated html. The backend is written in Golang. Might not be very important, but if somebody made a ...
1
vote
2answers
274 views

is JS a gradually typed language?

I was researching on statically typed and dynamically typed concepts and found out there is another type system called gradually typed. From wikipedia Gradual typing is a type system in which ...
1
vote
1answer
93 views

Web Application: Combining View Layer Between PHP and Javascript-AJAX

I'm developing web application using PHP with CodeIgniter MVC framework with a huge real time client-side functionality needs. This is my first time to build large scale of client-side app. So I ...
-3
votes
1answer
117 views

Would you get better performances by coding an application in C, then compile to JavaScript? [closed]

I am writing an interpreter for a functional programming language that is going to run in the browser. Needless to say, performance is the one and only concern in this application. Emscripten is an ...
0
votes
1answer
35 views

best practice to inter widget communication in javascript

I have quit a lot of javascript widget and I would like to have a good decoupled way to communicate between them. Something like signals and slots in QT probably? Most of my widgets are written in ...