Internet Explorer: HTML entities in URL

I have got the following PHP code: echo "<input type='image' src='myImage.png' onClick='javascript:location.href = \"index.php?p=1&copy=true\"' />"; If I klick on the image, Chrome redirects to index.php?p=1&copy=true. But if I klick...
more »

2017-03-19 23:03 (2) Answers

Best way to filter data on site

I write a small application which shows restaurants and pubs. I want to add a function to filter data by category. I get data in my script from external *.json file. There are only two categories - "bar" and "restaurant". I would be very greatful if...
more »

2017-03-19 23:03 (2) Answers

JS swapping an image smoothly

I already have a function to swap the images, but they swap without any animation. Now I want a function witch swaps the images with a fading. Here is my written code for the swap function: var header = new Array(); header[0] = "images/lan/IMG_2799....
more »

2017-03-19 22:03 (1) Answers

Achieve Angular 1.5.9 template injection

I am testing a web application and I have found a stored cross site scripting vulnerability through Angular template injection however I am having a problem exploiting it. Here is what the application does: Everything is htmlspecialchar() \ is esc...
more »

2017-03-19 21:03 (0) Answers

How to setup a proper javascript path using path

I was wondering if anyone can help me correct this code. I am trying to setup 3 different button menus using var path = window.location.href; for main URL, Russian site and Spanish site. I seem to have 2 out of 3 working. I am also sorry if I'm no...
more »

2017-03-19 19:03 (1) Answers

Iteration inside an object in react.js

i'm new to react and javascript and i have some difficulties coping with a task. Let's get started. I have and array like this: clients = ["Alex", "Jimmy"] and then i create another array with the following way: for (var i = 0; i < clients.length...
more »

2017-03-19 19:03 (1) Answers

How to fix a NaN from a forloop in JS (ES6)?

Hi I am building my own Mathematics in javascript. I declare the default accuracy to 8. When I pass through it to the function changes the outcome in the forloop to Nan. class Mathematics { constructor(angleType, accuracy) { this.P...
more »

2017-03-19 17:03 (1) Answers

Why extend a function with an empty object?

I was looking at the Rebound javascript code and saw that the SpringSystem function is being extended with an empty object. var SpringSystem = rebound.SpringSystem = function SpringSystem() { this._springRegistry = {}; this._activeSprings =...
more »

2017-03-19 15:03 (1) Answers

How to call script.jsx to make react.js work

I am trying to learn react.js. I am trying to setup a little test environment but do not understand why my script.jsx is not working? Is there anything special you must do to the file? If I have everything on the same page is works properly like this...
more »

2017-03-19 15:03 (1) Answers

Validated field on page load with Javascript

I have a form with few text fields and drop downs for add manually, city, phone, name, etc. however, depending on the city where you are, the form show the city automatically ( on page load ) but is not validated on submission. I asked someone and t...
more »

2017-03-19 14:03 (0) Answers

Scope inheritance not working - Javascript

function updateStrandDataOnPage(strands, cableID){ console.log(strands); var tubesOnPage = document.getElementsByClassName("tube"); console.log(tubesOnPage); if(strands.length != 0){ for(var i=0; i<tubesOnPage.length; i++)...
more »

2017-03-19 02:03 (0) Answers

Javascript - View all pages in one

So I have this: www.example.com/test.html?id=0&page=1 and I want with javascript to get the contents of all pages.. I tried this: www.example.com/test.html?id=0&page=1&page=2 but it just displays the first page How can I make it d...
more »

2017-03-19 01:03 (1) Answers

Modal not showing proper video in react

Hi I'm implementing a sample app with react,I'm also using youtube api search and react bootstrap. The idea is the following, I enter a search term, for example "PS4" this will call youtube api search and will bring back 5 matching results in a json...
more »

2017-03-18 21:03 (1) Answers

routing data to my param page in react.js

I'm currently trying to pass my data when you click on a link on the list component, it will go to the article component where it displays all the data from the backend. My list component is working it is showing the data that I want but it is not pa...
more »

2017-03-18 21:03 (1) Answers

Appending mutiple image on a div

I am trying to add the same image on a div five times but when I open my web page in Chrome or any browser it only shows one smiley.png image when it supposed to show five smiley.png on different coordinates on a the leftSide div. I am not sure what ...
more »

2017-03-18 20:03 (4) Answers