i am new to regex. I am trying to parse all contents inside curly brackets in a string. I looked up this post as a reference and did exactly as one of the answers suggest, however the result is unexpected.  Here is what i did  var abc = "test/abc...
This is driving me nuts. I can't work it out stepping through with Firebug either. Can someone please explain what is going on here?  Basically I have an incoming text file where each line contains a pipe-delimited record. I'm splitting these...
I want to convert the string "15,678" into a value 15678. Methods parseInt() and parseFloat() are both returning 15 for "15,678." Is there an easy way to do this?...
There are a lot of SO questions that seem to address variations of this question. But they tend to be complex regex answers and I am hoping I can find something simpler.   Given location.host values of  foo.mysite.com app.foo.mysite.com mysite.com...
I have a javascript chat bot where a person can type into an input box any question they like and hope to get an accurate answer. I can do this but I know I'm going about this all wrong because I don't know what position the number will appea...
How do I split selected value, seperate the number from text in jQuery?  Example:  myselect contains c4  Just get only the number 4.  $('select#myselect').selectToUISlider({       sliderOptions: {         stop: function(e,ui) {           var...
I am trying to create javasscript date object in the following way  var object = {"name":"Bay Area Global Health Film Festival","start_time":"2013-07-08T19:00:00","end_time":"2013-07-08T23:45:00","t...
I have a string like this: matrix(10, 0, 1, 0, -198, 23)  Then I need to match the arguments from that function and put in array:  var regexp = /.../gi var match = regexp.exe('matrix(10, 0, 1, 0, -198, 23)');  console.debug(match) // must ret...
According to Is JavaScript a pass-by-reference or pass-by-value language? JavaScript passes string objects by value. Because of that, calling the indexOf method will trigger copying the content.  In my case, I am parsing a big string to look for data...
I have this javasccript expression code as a string in my C# code, I need to evaluate it (execute it) using Microsoft.JScript.Eval.JScriptEvaluate (c#) and get result back.  string code = @"var roles=[]; roles.push('LOC_IND'); roles.push(...

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.