15,116 Topics

Member Avatar for
Member Avatar for mario90

Hello i'm using javascript code to redirect visitor to random link like the example below but sometimes i get error 404 response :( var pageArr = ["http://google.com", "http://yahoo.com", "http://bing.com", "http://youtube.com", "http://facebook.com"]; document.location.href = pageArr[Math.ceil(Math.random()*5)]; ps:the code does exist in external js file what the problem here ? i'm not coder …

Member Avatar for mario90
0
250
Member Avatar for cobalt555

I was wondering if anyone could show me how to take a string that is entered and then find that string and use it as my unit of measure . I also have to find a number that is part of a string. for example: How many feet in an …

Member Avatar for DavidB
0
116
Member Avatar for NoUserNameHere

How do you pass a value of an input field from angular to node? For HTML and PHP you would do something like $username = $_POST['field_name'];, is there something similar with angular and node?

0
66
Member Avatar for anuran

iam trying to create a smotth transition between 3 images inside a div using jquery. i have managed to get the needed opacity transition on moving mouse to any side of the div.Now i want to have some change in position also like this [Click Here](http://www.adhamdannaway.com/) But iam changing the …

Member Avatar for anuran
0
425
Member Avatar for nadiam

var tabLinks = new Array(); var contentDivs = new Array(); function init() { // Grab the tab links and content divs from the page var tabListItems = document.getElementById('tabs').childNodes; for ( var i = 0; i < tabListItems.length; i++ ) { if ( tabListItems[i].nodeName == "LI" ) { var tabLink = …

Member Avatar for noelthefish
0
3K
Member Avatar for DTSCode

im writing a firefox addon to append signatures to posts in cplusplus.com, but im having a little trouble, as it has been a long time since i wrote in javascript. right now i just want it to verify that i am in fact on the c++ forums and if it …

Member Avatar for DTSCode
0
314
Member Avatar for Drugsxxx

I looking for some tutorial that will show me how to send data to .json file and save it one after another like: data1,data2,data3 data1,data2,data3 ...and so on Also i would like to know do i need jQuery and is it hard to use??

Member Avatar for Drugsxxx
0
190
Member Avatar for AARTI SHRIVAS

when i click on add to cart button page is not reload cart shows empty and when i refresh page throught f5 it show data in cart and give error TypeError: jQuery(...).fancybox is not a function "transitionOut" : "elastic" in admin side i disable fancybox jquery so i got this …

Member Avatar for AARTI SHRIVAS
0
203
Member Avatar for ogok2010

Hi, so I'm creating a hangman game with only basic skills in java&html. I'm having a great trouble as to how to make it work. What I'm trying to do is very simple: When I type a word, a box will pop up and say, "----" (if it's 4 words) …

Member Avatar for Airshow
0
146
Member Avatar for mushahidh

I am using this script for exporting data from HTML table to Excel. <script> var tableToExcel = (function() { var uri = 'data:application/vnd.ms-excel;base64,' , template = '<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns="http://www.w3.org/TR/REC-html40"><head><!--[if gte mso 9]><xml><x:ExcelWorkbook><x:ExcelWorksheets><x:ExcelWorksheet><x:Name>{worksheet}</x:Name><x:WorksheetOptions><x:DisplayGridlines/></x:WorksheetOptions></x:ExcelWorksheet></x:ExcelWorksheets></x:ExcelWorkbook></xml><![endif]--></head><body><table>{table}</table></body></html>' , base64 = function(s) { return window.btoa(unescape(encodeURIComponent(s))) } , format = function(s, c) { return s.replace(/{(\w+)}/g, function(m, …

Member Avatar for pixelsoul
0
4K
Member Avatar for sugumarclick

Basically I'm having three text input. First is autocomplete (book name). Second is book price and third is book author. Please help me in changing the 2nd and third input text box values according to the selection of autocomplete input box. Fiddle setup is at http://jsfiddle.net/premgowda/UC74L/6/ Json code below from …

Member Avatar for noelthefish
0
560
Member Avatar for Tcll

so basically, what I've got is a handful of BBC text like such: [tree]title0 [node]title1 title2 [node]title3 title4 title5[/node][/node] title6 title7[/tree] using JS, how could I parse this to get this into this?? [ title0, [ title1, title2, [ title3, title4, title5 ] ], title6, title7 ] what I intend …

Member Avatar for Tcll
0
140
Member Avatar for chozokennedy

Hello, how does the getElementbyTagname and the length of that works ? Suppose my codes is : <!DOCTYPE html> <html> <body> <p id="demo">This is demo</p> <div id="original">This is original</div> <button onclick="myFunction()">Try it</button> <script> function myFunction() { var elements = document.getElementsByTagName("*"); alert(elements.length); }; </script> </body> </html> Output is 7. Why ? …

Member Avatar for AARTI SHRIVAS
0
120
Member Avatar for Indians

here i am trying to do calculation for javascript dynamic rows. i have done auto multiplication in few rows using this function . but i want to calculate the tax percentage. how can i do that? help.. <script src="http://code.jquery.com/jquery-1.6.4.min.js"></script> <script> var $k = jQuery.noConflict(); $k.fn.sum = function() { var sum …

Member Avatar for Indians
0
1K
Member Avatar for Master Mascus
Member Avatar for stbuchok
0
239
Member Avatar for hlamster

I have a function that returns a value that I would like to set as the value in and <input> statement. So essentially I have a javascript function deCols() that returns a value and I would like to do something like <input type='hidden' id='devCols' name='devCols' value=devCols() /> which of course …

Member Avatar for hlamster
0
301
Member Avatar for SaroGFX

Hi guys, The code works perfect on fiddle (check link below) but doesnt work properly when i [upload the same code online](http://saroverhees.be/testing/flickering2.html). What have I done wrong? http://jsfiddle.net/LRvVm/5/

Member Avatar for SaroGFX
0
171
Member Avatar for Violet_82

Hi guys, I was wondering if you can help me at all. I've just built a small html page which is meant to keep track of overtime. The data is entered through input fields. Then with jquery I extract the data from the input fields, create and populate a table. …

Member Avatar for diafol
0
209
Member Avatar for adishardis

I need to create an dynamic array which will be sent via `$("#ratings").load("ratingscalculator.php?Myarray="+myarray)` and then used in a select query $result = $database->connection->prepare("SELECT *, (SELECT COUNT(*)+1 FROM TABLE WHERE kampanj > t.kampanj and (kampanjnamn = 'Kampanjnamn_1' or kampanjnamn = 'Kampanjnamn_7' or kampanjnamn = 'Kampanjnamn_3' or kampanjnamn = 'Kampanjnamn_4' )) as …

Member Avatar for adishardis
0
160
Member Avatar for llgms

Hi guys I am trying to buld an rss reader for random rss feeds in javascript. I need to catch the data in an event as I am going to pass around that event. I tried realtime.co or firebase and feedthefire but, there is no result so far. If someone …

Member Avatar for llgms
0
354
Member Avatar for Indians

![d7f49899d09d4dd84f5105080c780de5](/attachments/small/4/d7f49899d09d4dd84f5105080c780de5.PNG "align-left") here i attached one image. look at this.if i selected the Guest Currency then automatically Guest Currency Value should shown in the next text box. how to do that? is there any javascript, jquery plugin? Guest Currency : <select name="gcurrency" tabindex="21"> <option value=""></option> <option> INR India Rupees </option> …

Member Avatar for diafol
0
3K
Member Avatar for Amoryethel

I'm trying to put together a webpage that will leave a dropdown menu (near merch1) disabled until the checkbox is selected, but the dropdown menu insists on staying disabled. I don't know if it has to do with my checkBox function, or if that's even a necessity. Here is a …

Member Avatar for Amoryethel
0
123
Member Avatar for mukulnimker7751

Hi All, M trying to design a web portal which shows all my trackers and allows me to open it . the trackers are in ms Excel format. Please suggest me d best possible way to achieve the goal. Thanks Mukul

Member Avatar for JorgeM
0
141
Member Avatar for simplypixie

I am using tinymce on a cms and I want to be able to have a dropdown menu of all pages on the site (stored in a db) to choose from when adding a link but all I am getting is an emtpy set of values. I am using the …

Member Avatar for simplypixie
0
894
Member Avatar for klemme

Hi all, I have a problem with my code below. It works in chrome, but acts different in IE, and sometimes FF. Im aiming to load in divs whenever the user scrolls to 220px from the bottom. Basically, I tjeck to see if the distance from the bottom < specified …

0
96
Member Avatar for mbarandao

Hello: I need some assistance with a jquery/javascript code. I have a form with chain-linked list box of product, and prices. Each product is inside a <tr> which are added as needed. So there can be many items added to the form. The total of the items cost (qty*cost) from …

Member Avatar for mbarandao
0
750
Member Avatar for jonsan32

I'm trying to combine the functionality of the 3 codes below to produce a delayed redirect to a random URL while displaying a bar filling up by %. Each one works great, but I need all 3. Any help would be greatly appreciated. Thanks! **The first redirects after a delay** …

Member Avatar for happygeek
0
2K
Member Avatar for amrita111

I am calling an mvc controller method vaia ajax call..When i put debugger on then that controller method is called sucessfully otherwise my ajax call is failing. What to do?

Member Avatar for LastMitch
0
96
Member Avatar for jonsan32

What would I need to add to the code below to have the random redirect timeout for 5 seconds before triggering? <script type="text/javascript"> (function(n){ var pages = ['http://www.thestormybrain.com/2013/11/malcolm-gladwell-choice-happiness-and.html', 'http://www.thestormybrain.com/2013/11/steve-jobs-how-to-live-before-you-die.html', 'http://www.thestormybrain.com/2013/11/david-blaine-how-i-held-my-breath-for.html']; n = n < 3? 0 : n < 8? 1 : 2; window.location.replace(pages[n]); })(Math.floor(Math.random() * 10)); </script> I know …

Member Avatar for jonsan32
-1
553
Member Avatar for nyuszi

hi i get an error while i trying to do a plumber game here is the javascript code: error message: Uncaught TypeError: Cannot call method 'getAttribute' of undefined (line 34) the problem: function check () { kepek = document.getElementsByTagName("img"); cellak = document.getElementsByTagName("td"); db = 0; for (i=1; i<cellak.length; i++) { …

Member Avatar for ryantroop
0
1K

The End.