How to get text between dynamic created lines
So i try to get the text between dynamic created lines.
Example string,
KOR/4
1/FI222/24NOV/DOK
PLO
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
134-57627905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/STACKI
SSR/TROPPER5
FINAL
So i tried with .match() and exec().
I couldn't figure out a way to get the textual between the numbers in array
REQUIRED OUTPUT
// OUTPUT EXAMPLE
[0][
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
],
[2][
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
],
[3][
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
]
etc..
javascript jquery
add a comment |
So i try to get the text between dynamic created lines.
Example string,
KOR/4
1/FI222/24NOV/DOK
PLO
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
134-57627905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/STACKI
SSR/TROPPER5
FINAL
So i tried with .match() and exec().
I couldn't figure out a way to get the textual between the numbers in array
REQUIRED OUTPUT
// OUTPUT EXAMPLE
[0][
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
],
[2][
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
],
[3][
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
]
etc..
javascript jquery
2
What did you try? Please edit your question and post your code as a Minimal, Complete, and Verifiable example. What happens when you run it? What did you expect to happen instead? Any errors or warnings?
– Robert
Nov 24 '18 at 21:49
add a comment |
So i try to get the text between dynamic created lines.
Example string,
KOR/4
1/FI222/24NOV/DOK
PLO
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
134-57627905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/STACKI
SSR/TROPPER5
FINAL
So i tried with .match() and exec().
I couldn't figure out a way to get the textual between the numbers in array
REQUIRED OUTPUT
// OUTPUT EXAMPLE
[0][
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
],
[2][
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
],
[3][
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
]
etc..
javascript jquery
So i try to get the text between dynamic created lines.
Example string,
KOR/4
1/FI222/24NOV/DOK
PLO
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
134-57627905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/STACKI
SSR/TROPPER5
FINAL
So i tried with .match() and exec().
I couldn't figure out a way to get the textual between the numbers in array
REQUIRED OUTPUT
// OUTPUT EXAMPLE
[0][
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
],
[2][
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
],
[3][
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
]
etc..
javascript jquery
javascript jquery
edited Nov 25 '18 at 7:08
Hakan Kose
1,271412
1,271412
asked Nov 24 '18 at 21:03
John SmithsJohn Smiths
597
597
2
What did you try? Please edit your question and post your code as a Minimal, Complete, and Verifiable example. What happens when you run it? What did you expect to happen instead? Any errors or warnings?
– Robert
Nov 24 '18 at 21:49
add a comment |
2
What did you try? Please edit your question and post your code as a Minimal, Complete, and Verifiable example. What happens when you run it? What did you expect to happen instead? Any errors or warnings?
– Robert
Nov 24 '18 at 21:49
2
2
What did you try? Please edit your question and post your code as a Minimal, Complete, and Verifiable example. What happens when you run it? What did you expect to happen instead? Any errors or warnings?
– Robert
Nov 24 '18 at 21:49
What did you try? Please edit your question and post your code as a Minimal, Complete, and Verifiable example. What happens when you run it? What did you expect to happen instead? Any errors or warnings?
– Robert
Nov 24 '18 at 21:49
add a comment |
1 Answer
1
active
oldest
votes
You can use regex to get target part of string.
var match = str.match(/d{3}-.*?(?=d{3}-|FINAL)/sg);
The regex select any part of string that start with digit with length 3 and end with digit with length 3
var str = document.getElementById("str").innerHTML;
var match = str.match(/d{3}-.*?(?=d{3}-|FINAL)/sg);
console.log(match.join('nn'));
<div id="str" style="display:none">KOR/4
1/FI222/24NOV/DOK
PLO
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
134-57627905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/STACKI
SSR/TROPPER5
FINAL</div>
This works perfect but stupid of me i copy paste the lines. The ending line is not always SSR/TROPPER5. That one is also dynamically created. So it must start on d{3} than end on d{3}.
– John Smiths
Nov 25 '18 at 7:04
@JohnSmiths You should show any type of string in question. However answer updated
– Mohammad
Nov 25 '18 at 7:51
@Mohammed, i can't see them return as separated array as in the output example of my question. I need them to split to get the as match[0], match[1] etc..
– John Smiths
Nov 25 '18 at 18:14
@JohnSmiths Thematch
variable contain array but i converted it to string usingjoin()
to better showing in snippet. You can see array in jsfiddle.net/esmjk7u5
– Mohammad
Nov 25 '18 at 19:44
@Mohammed, one last thing. Now if there is between captured area another d{3} that strips that one also example DIM/K0/CMT444-30-30/5 how to do this
– John Smiths
Nov 26 '18 at 12:09
|
show 1 more comment
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53462342%2fhow-to-get-text-between-dynamic-created-lines%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
You can use regex to get target part of string.
var match = str.match(/d{3}-.*?(?=d{3}-|FINAL)/sg);
The regex select any part of string that start with digit with length 3 and end with digit with length 3
var str = document.getElementById("str").innerHTML;
var match = str.match(/d{3}-.*?(?=d{3}-|FINAL)/sg);
console.log(match.join('nn'));
<div id="str" style="display:none">KOR/4
1/FI222/24NOV/DOK
PLO
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
134-57627905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/STACKI
SSR/TROPPER5
FINAL</div>
This works perfect but stupid of me i copy paste the lines. The ending line is not always SSR/TROPPER5. That one is also dynamically created. So it must start on d{3} than end on d{3}.
– John Smiths
Nov 25 '18 at 7:04
@JohnSmiths You should show any type of string in question. However answer updated
– Mohammad
Nov 25 '18 at 7:51
@Mohammed, i can't see them return as separated array as in the output example of my question. I need them to split to get the as match[0], match[1] etc..
– John Smiths
Nov 25 '18 at 18:14
@JohnSmiths Thematch
variable contain array but i converted it to string usingjoin()
to better showing in snippet. You can see array in jsfiddle.net/esmjk7u5
– Mohammad
Nov 25 '18 at 19:44
@Mohammed, one last thing. Now if there is between captured area another d{3} that strips that one also example DIM/K0/CMT444-30-30/5 how to do this
– John Smiths
Nov 26 '18 at 12:09
|
show 1 more comment
You can use regex to get target part of string.
var match = str.match(/d{3}-.*?(?=d{3}-|FINAL)/sg);
The regex select any part of string that start with digit with length 3 and end with digit with length 3
var str = document.getElementById("str").innerHTML;
var match = str.match(/d{3}-.*?(?=d{3}-|FINAL)/sg);
console.log(match.join('nn'));
<div id="str" style="display:none">KOR/4
1/FI222/24NOV/DOK
PLO
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
134-57627905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/STACKI
SSR/TROPPER5
FINAL</div>
This works perfect but stupid of me i copy paste the lines. The ending line is not always SSR/TROPPER5. That one is also dynamically created. So it must start on d{3} than end on d{3}.
– John Smiths
Nov 25 '18 at 7:04
@JohnSmiths You should show any type of string in question. However answer updated
– Mohammad
Nov 25 '18 at 7:51
@Mohammed, i can't see them return as separated array as in the output example of my question. I need them to split to get the as match[0], match[1] etc..
– John Smiths
Nov 25 '18 at 18:14
@JohnSmiths Thematch
variable contain array but i converted it to string usingjoin()
to better showing in snippet. You can see array in jsfiddle.net/esmjk7u5
– Mohammad
Nov 25 '18 at 19:44
@Mohammed, one last thing. Now if there is between captured area another d{3} that strips that one also example DIM/K0/CMT444-30-30/5 how to do this
– John Smiths
Nov 26 '18 at 12:09
|
show 1 more comment
You can use regex to get target part of string.
var match = str.match(/d{3}-.*?(?=d{3}-|FINAL)/sg);
The regex select any part of string that start with digit with length 3 and end with digit with length 3
var str = document.getElementById("str").innerHTML;
var match = str.match(/d{3}-.*?(?=d{3}-|FINAL)/sg);
console.log(match.join('nn'));
<div id="str" style="display:none">KOR/4
1/FI222/24NOV/DOK
PLO
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
134-57627905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/STACKI
SSR/TROPPER5
FINAL</div>
You can use regex to get target part of string.
var match = str.match(/d{3}-.*?(?=d{3}-|FINAL)/sg);
The regex select any part of string that start with digit with length 3 and end with digit with length 3
var str = document.getElementById("str").innerHTML;
var match = str.match(/d{3}-.*?(?=d{3}-|FINAL)/sg);
console.log(match.join('nn'));
<div id="str" style="display:none">KOR/4
1/FI222/24NOV/DOK
PLO
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
134-57627905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/STACKI
SSR/TROPPER5
FINAL</div>
var str = document.getElementById("str").innerHTML;
var match = str.match(/d{3}-.*?(?=d{3}-|FINAL)/sg);
console.log(match.join('nn'));
<div id="str" style="display:none">KOR/4
1/FI222/24NOV/DOK
PLO
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
134-57627905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/STACKI
SSR/TROPPER5
FINAL</div>
var str = document.getElementById("str").innerHTML;
var match = str.match(/d{3}-.*?(?=d{3}-|FINAL)/sg);
console.log(match.join('nn'));
<div id="str" style="display:none">KOR/4
1/FI222/24NOV/DOK
PLO
134-57623905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
/STACKI
89a7/SOMET
134-12389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/BLA
2736/2832
134-34389783WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/DYN
asdjadhjahd
134-57627905WINLOSE/WINNER/ROBO
/TRY
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
DIM/K0/CMT44-30-30/5
/STACKI
SSR/TROPPER5
FINAL</div>
edited Nov 25 '18 at 7:50
answered Nov 25 '18 at 5:22
MohammadMohammad
15.8k123664
15.8k123664
This works perfect but stupid of me i copy paste the lines. The ending line is not always SSR/TROPPER5. That one is also dynamically created. So it must start on d{3} than end on d{3}.
– John Smiths
Nov 25 '18 at 7:04
@JohnSmiths You should show any type of string in question. However answer updated
– Mohammad
Nov 25 '18 at 7:51
@Mohammed, i can't see them return as separated array as in the output example of my question. I need them to split to get the as match[0], match[1] etc..
– John Smiths
Nov 25 '18 at 18:14
@JohnSmiths Thematch
variable contain array but i converted it to string usingjoin()
to better showing in snippet. You can see array in jsfiddle.net/esmjk7u5
– Mohammad
Nov 25 '18 at 19:44
@Mohammed, one last thing. Now if there is between captured area another d{3} that strips that one also example DIM/K0/CMT444-30-30/5 how to do this
– John Smiths
Nov 26 '18 at 12:09
|
show 1 more comment
This works perfect but stupid of me i copy paste the lines. The ending line is not always SSR/TROPPER5. That one is also dynamically created. So it must start on d{3} than end on d{3}.
– John Smiths
Nov 25 '18 at 7:04
@JohnSmiths You should show any type of string in question. However answer updated
– Mohammad
Nov 25 '18 at 7:51
@Mohammed, i can't see them return as separated array as in the output example of my question. I need them to split to get the as match[0], match[1] etc..
– John Smiths
Nov 25 '18 at 18:14
@JohnSmiths Thematch
variable contain array but i converted it to string usingjoin()
to better showing in snippet. You can see array in jsfiddle.net/esmjk7u5
– Mohammad
Nov 25 '18 at 19:44
@Mohammed, one last thing. Now if there is between captured area another d{3} that strips that one also example DIM/K0/CMT444-30-30/5 how to do this
– John Smiths
Nov 26 '18 at 12:09
This works perfect but stupid of me i copy paste the lines. The ending line is not always SSR/TROPPER5. That one is also dynamically created. So it must start on d{3} than end on d{3}.
– John Smiths
Nov 25 '18 at 7:04
This works perfect but stupid of me i copy paste the lines. The ending line is not always SSR/TROPPER5. That one is also dynamically created. So it must start on d{3} than end on d{3}.
– John Smiths
Nov 25 '18 at 7:04
@JohnSmiths You should show any type of string in question. However answer updated
– Mohammad
Nov 25 '18 at 7:51
@JohnSmiths You should show any type of string in question. However answer updated
– Mohammad
Nov 25 '18 at 7:51
@Mohammed, i can't see them return as separated array as in the output example of my question. I need them to split to get the as match[0], match[1] etc..
– John Smiths
Nov 25 '18 at 18:14
@Mohammed, i can't see them return as separated array as in the output example of my question. I need them to split to get the as match[0], match[1] etc..
– John Smiths
Nov 25 '18 at 18:14
@JohnSmiths The
match
variable contain array but i converted it to string using join()
to better showing in snippet. You can see array in jsfiddle.net/esmjk7u5– Mohammad
Nov 25 '18 at 19:44
@JohnSmiths The
match
variable contain array but i converted it to string using join()
to better showing in snippet. You can see array in jsfiddle.net/esmjk7u5– Mohammad
Nov 25 '18 at 19:44
@Mohammed, one last thing. Now if there is between captured area another d{3} that strips that one also example DIM/K0/CMT444-30-30/5 how to do this
– John Smiths
Nov 26 '18 at 12:09
@Mohammed, one last thing. Now if there is between captured area another d{3} that strips that one also example DIM/K0/CMT444-30-30/5 how to do this
– John Smiths
Nov 26 '18 at 12:09
|
show 1 more comment
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53462342%2fhow-to-get-text-between-dynamic-created-lines%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
2
What did you try? Please edit your question and post your code as a Minimal, Complete, and Verifiable example. What happens when you run it? What did you expect to happen instead? Any errors or warnings?
– Robert
Nov 24 '18 at 21:49