I'm trying to write a plugin that will read whole .txt files and all its contents and convert the .txt file content into .html or .htm for the web but my problem is read_file and write_file obligates you to specify a const text.
How do I set it so that it reads and write the whole line not just a specific position on the line?
Heres a general concept of what im trying to do:
Reads each line in a text file
filename.txt
Code:
Content line 1
Content line 2
Content line 3
Content line 4
...and so on down the lines
The takes what it got from the filename.txt and rewrites it into a web based (htm or html) file filename.htm
HTML Code:
</head>
<body bgcolor="#000000">
<p><font color="#d50000">Content line 1</font></p>
<p><font color="#d50000">Content line 2</font></p>
<p><font color="#d50000">Content line 3</font></p>
<p><font color="#d50000">Content line 4</font></p>
<p><font color="#d50000">...and so on down the lines</font></p></body></html>
The direct purpose behind this is to have an alternative to web base content from amx mod x with out the need to set up sql databases. Most game server providers offer a fast redirect service for fast DL straight from your local game server files and I want to use it to its full potential and have maybe web based ranking systems with out mysql databases of any sort. I already have added an .htm file is viewable in my browser and all I need is my amxx plugin to read stored content by other plugins and copy each line to a browsable .htm
__________________