Added helper library for URL manipulation functions
This commit is contained in:
12
url_manipulation.h
Normal file
12
url_manipulation.h
Normal file
@@ -0,0 +1,12 @@
|
||||
#include <string.h>
|
||||
|
||||
/* url_to_proto - This takes in a URL, and returns the protocol.
|
||||
Example - 'https://example.org' would return 'https'. */
|
||||
|
||||
char* url_to_proto(char* url);
|
||||
|
||||
/* url_to_hostname - This takes in a URL, and returns the hostname.
|
||||
Example - 'https://example.org' would return 'example.org'. */
|
||||
|
||||
char* url_to_hostname(char* url);
|
||||
|
||||
Reference in New Issue
Block a user