Hi All,
Can some one please explain what exactly is the below line in bold means , - var i = ctl.id;
-
var j =g_form.getValue(i);
-
-
var port = j;
-
if (/^\d+$/.test(port)){ ----- Please explain what is this
-
var k =parseInt(g_form.getValue(i));
-
if (k<1 || k>65000){
-
alert('Invalid Port Number: Value must be <= 65000');
-
g_form.clearValue(i);
-
}
-
}
-
-
else{
-
var ports = port.split("-");
-
if ((/^\d+$/.test(ports[0])) && (/^\d+$/.test(ports[1])) && (ports[0] < ports[1]) && ports[0] <=65000 && ports[1] <=65000 ){}
-
else{
-
alert("Invalid Port Range: Please enter numeric value") ;
-
g_form.clearValue(i);
-
}
-
}
My Requirement is , port column in catalog table is just accepting numbers and numbers with - .
Now we need to have the below , please let me know how to get this done.
- An open-ended range of ports with Less Than or Greater than: >1023
- A combination of the above formats separated by commas: 21, 80-81, >1023
- Negate a single number: !80
11 1547
there is no line in bold ...
Hi ,
Please see the lines below , what I was referring to .
if (/^\d+$/.test(port))
and
if ((/^\d+$/.test(ports[0])) && (/^\d+$/.test(ports[1])) && (ports[0] < ports[1]) && ports[0] <=65000 && ports[1] <=65000 ){}
else{
alert("Invalid Port Range: Please enter numeric value") ;
g_form.clearValue(i);
}
}
Please let me know what can I do to include 3 ranges I mentioned above.
/^\d+$/ simply means: only digits.
Ok , Please let me know what I need to do for including below .
- An open-ended range of ports with Less Than or Greater than: >1023
- A combination of the above formats separated by commas: 21, 80-81, >1023
- Negate a single number: !80
An open-ended range of ports with Less Than or Greater than: >1023
Negate a single number: !80
make a separate test for that
A combination of the above formats separated by commas: 21, 80-81, >1023
explode by , , trim, and do validation for each item.
Sorry ,
I did not understand what you are trying to say .
An open-ended range of ports with Less Than or Greater than: >1023
Negate a single number: !80
make a separate test for that - How to test this.
A combination of the above formats separated by commas: 21, 80-81, >1023
explode by ,, trim, and do validation for each item. - Please explain how to do this.
Hi,
Please let me know how to achieve this
An open-ended range of ports with Less Than or Greater than: >1023.
Also , I am new to java script , can you please help
that requirement is the same as "not 1023".
Actually we need to have > and < sysmbols included. ANy idea.
it makes no sense to include > and < when it's not necessary.
Sign in to post your reply or Sign up for a free account.
Similar topics
by: Charles Hixson |
last post by:
I'm getting a list that I build which when printed is displaying, well,
e.g.:
d = << , 'Do', 'not', 'remove', 'thi', '.', ] >>
Clearly I have a problem with the truncation of the final this, but...
|
by: QQ |
last post by:
for example
~CcMessage() {}
Thanks a lot!
I am a beginner for C++, so please forgive my stupid questions
|
by: wintaki |
last post by:
Given
int x;
What does
x evaluate to?
If x is 0, it equals 0x31, the ascii value of '1'. So for some
reason, x evaluates to *(y+x) where x is a non pointer/array type.
|
by: alex14 |
last post by:
Hi
could someone please tell me what the double colons :: in perl scripts mean and what do they do?
kind regards
alex
|
by: SMichal |
last post by:
Hi, I'm starting from my application simple bat data...test.bat.
This file (test.bat) should start another aplication app.exe.
I'm starting the test.bat from my application with Start() method of...
|
by: plusk1008 |
last post by:
I have finals next week and I am stuck on one question on my review sheet for excel. So once again I beg: Please, please, please, please, please, please, please, please, please, please someone help...
|
by: mantrid |
last post by:
in some php script ive seen
$something==@$somethingelse
whereas
something==$somethingelse
works the same
what does the use of the @ do?
Sorry if this is a stupid question
|
by: hini |
last post by:
Hello,
I see the N' in many asp , sql scripts at the beginning of a string usually and I don't know what's its meaning,
I could not find anything about it when seraching google because of the...
|
by: Daniel Brower |
last post by:
I found documentation that uses the ^ notation after a type name. What does
that notation mean?
Daniel
|
by: Monica Pnade |
last post by:
what does /^/ mean in perl?
|
by: aa123db |
last post by:
Variable and constants
Use var or let for variables and const fror constants.
Var foo ='bar';
Let foo ='bar';const baz ='bar';
Functions
function $name$ ($parameters$) {
}
...
|
by: ryjfgjl |
last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
|
by: ryjfgjl |
last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: BarryA |
last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
|
by: nemocccc |
last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
| |