Click to See Complete Forum and Search --> : How do I filter off HTML tags?
TaNz
Sep 22nd, 2002, 10:17 PM
Hi ppl!
I'm really new to this program and I need your assistance for this project of mine.
As mention above, how do I filter off html tags from a text file which is taken down from a website?
hellswraith
Sep 22nd, 2002, 10:21 PM
Can you explain just a little more. Do you want the text from the page? Do you want to find certain elements of the page?
TaNz
Sep 22nd, 2002, 10:31 PM
Oh sorry, as I'm very newbie in here.
I have written a program just to extract the Source code of any website and written it down and a txt file. As it is written is Java, I need to filter off those tags in order for me to retrive information inside this text file.. I'm not sure whether I have explained well enuff but please do ask about your doubts to my question.
Thanks a million.. :)
hellswraith
Sep 22nd, 2002, 11:39 PM
You can open the file in notepad.
If you need to strip of all tags then you are going to want to read up on the string class and it's methods. Specifically look at the IndexOf method and the SubString method.
TaNz
Sep 23rd, 2002, 12:02 AM
Thank you for your guidance..
TaNz
Sep 23rd, 2002, 12:48 AM
i have read up those topics but still can't undertsnad due to my stupidlity.. :rolleyes: Is there any more other simpler ways to filter it off?
TaNz
Sep 23rd, 2002, 01:16 AM
Maybe you experts can teach me how do I search from a text file like search from " < " to " > " and I can delete that entire whole thing.. Maybe like that will helps me to filter it off the html tags?
PT Exorcist
Sep 23rd, 2002, 06:09 AM
like it's been refered before..use the indexof() and substring() functions..search over msdn to look for that if u dont know how to use them...or CTRL + F1 in IDE to know about that...and we are not experts..we just use the brain :o
TaNz
Sep 23rd, 2002, 08:13 PM
Thank youonce again..:(
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.