html - How can I read a specific line of TXT file in my computer using Javascript? -


i have database.txt in c:\ containing data line line.

how can specific nth line of txt embed texts between lines data?

example of database.txt :

real madrid barcelona bayern munich manchester united 

what want write :

haha 1 real madrid hoho haha 2 barcelona hoho haha 3 bayern munich hoho haha 4 manchester united hoho 

can specific line embedding given text specific pattern??

thanks.

you cannot javascript browser since not allow read files disk. can making xmlhttprequest aspx or ashx returns file string. split string on newline \n , take line want index.


Comments

Popular posts from this blog

How to logout from a login page in asp.net -

Stack level too deep error after upgrade to rails 3.2 and ruby 1.9.3 -