LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Prompt the user for a file to open, extract the XML and write to another text file. (https://www.linuxquestions.org/questions/linux-newbie-8/prompt-the-user-for-a-file-to-open-extract-the-xml-and-write-to-another-text-file-839760/)

richiep 10-22-2010 08:05 AM

Prompt the user for a file to open, extract the XML and write to another text file.
 
Hello,


I have a huge text file generated from our system and i need a script that asks the user to specify which file to open, Once the file is open, the script should extract ALL of the XML in that file ONLY and then write it to another file.



The XML needs to be extracted in to the new file, currently it is not arranged very well, so will need some line breaks once i have completed the latter.

I am pretty new to linux, iv been on a few courses but that is it. Any help would be much appreciated!

So, to sum up...

take the attached as input
invoke a script
get an xml file from the script as output

Apologies for not including code, i tired using the tags but was having problems posting.

Many Thanks

richiep 10-22-2010 09:02 AM

can any one help?

druuna 10-22-2010 10:02 AM

Hi,

Please do not cross-post, it is against the LQ rules. And bumping after just an hour is considered rude.....

If you think you created your other post in the wrong forum, ask a moderator to move it.

richiep 10-22-2010 10:10 AM

What are you doing then? You are cross posting the same message, looking for brownie points?

druuna 10-22-2010 10:21 AM

No need to get snotty!

You're the one that is breaking the rules with 3 thread about the same subject and asking unfair extra attention from all the others on this board. To remedy that I took 2 of the 3 threads from the zero reply list (which keeps pushing "old" zero reply threads to the top).

If you don't like the way you are treated by me you can:

1) Obey by the LQ rules and don't get bothered ever again by me, or
2) Complain to one of the mods or Jeremy about me.

Have a good day.

BTW: Reported.

ordinary 10-22-2010 10:22 AM

Quote:

Originally Posted by richiep (Post 4135955)
What are you doing then? You are cross posting the same message, looking for brownie points?

Excellent! Abuse. If there's anything LQ members respond to better than breaking rules, it's abuse.

richiep 10-22-2010 10:31 AM

That is not abuse just something i noticed. He has littered the system as much as me! I apologised for doing it in another thread yet he found it necessary to comment on all my others. I am new to this and realised i posted something in the wrong area. Not getting snotty at all, not being abusive either. I was just looking for some help, not some ponsey remark in each of my threads! sorry if iv offended!

Tinkster 10-22-2010 03:34 PM

And now that this is settled (yes, you, Richie, were breaking the
rules; pointing that out repeatedly is OK from a mods perspective)
can we leave that discussion be and return to the subject? This is,
after all, the original of the series. The dupes are reported for
closure, and that's enough.



Cheers,
Tink


All times are GMT -5. The time now is 05:18 PM.