if you load the file #include <fstream>
read in the file using std::ifstream("folder\\file.txt"
now two options load into a single string or line by line.
Single std::string
will be easiest
there are google articles on how to do this
The next thing is
std::string data;
//load data
//this is like an int showing current loc in string
std::string::size_type pos(0);
std::string::size_type cur_pos = data.find('<', pos);
if(cur_pos != std::string::npos)
{
//found the start of tag
//advance to first letter
+cur_pos
//now find end
pos = data.find('>', cur_pos);
std::string tag = data.substr(cur_pos, pos - cur_pos);
//check is closing tag
if(tag.size() > 0 && tag[0] = '/')
{
tag = tag.substr(1);
//are we inside or not
}
else
{
//new tag
}
what else you have to do is add
a tag to an open std::vector<std::string>
and if it closes it should be the last tag on the list
you have to store the strings between tags as parameters
now I have left a fair bit for you to do yourself here.
But if you assume no errors in xml and no self closing tags the
above methods should suffive
can anyone give me some hints on this im having issues
thanks