Lince,
I have been watching your posts on this same topic for a bit now and it seems that you are more interested in obtaining an answer rather then attempting the work yourself. However, I will attempt to guide you towards your end goal...
Your wondering how to put together something that will make an URL-encoded string (that in essence would most likely be used after the ? in an URL going towards a CGI script). This can be done very simply, especially if you know the exact values that you are going to be placing together.
Example Psuedo-Code:
Code:
void BuildQueryString(char *dest_querystr, char *name, char *address, char *phonenum)
{
1. take all three and make one long string in the required format
2. change all spaces in string to '+'s
3. change any required special characters to their appropriate hex values
4. ensure that fully encoded string goes in to dest_querystring (or whatever you want to name it)
}
Of course the format of the function definition could be changed as per your own required specifications of your software so far. By following those steps, you should in no time, have a function of your very own that will URL-encode and build any query string that you require.
I would also suggest that if you are unable to build a program up like this (psuedo-code method) then perhaps something is missing. Like if you don't understand how URL-encoding/query strings work... do research on it. Figure out how it's done (many specifications out there for many different things) and then build psuedo-code for it. Follow the psuedo-code as your build your project and then eventually you wont have to do this extra step once experienced enough.
If after making an attempt at the above psuedo-code or one of your own making, post some code back and I'll be happy to take a look it and see where we can go from there.
Regards