Without any code, your question is kinda broad so it's hard to answer.
You could try using strrchr.
This way, you can find the first occurance of "</", and then use substr to break it up. It would take a bit of work to to correctly parse a file with that, but I think I've done it before for some bizarre project.
Depending on what you want to do, you could find the location of the first "<", then check to see if that index + 1 is a "/"... and it gets confusing.
Also, you could find the first intance of "<" and then check to see if the next character is a "/", which would tell you if it's a close tag. If it is a close tag and you don't want it, then you could just discard it.
Otherwise, look up DOM functions like BlueKai said.