SnippetMaster Support Forums
Return to main website
February 19, 2018, 09:55:05 PM
* Show unread posts since last visit.
* Show new replies to your posts.
Welcome, Guest. Please login or register.
Did you miss your activation email?
February 19, 2018, 09:55:05 PM

Login with username, password and session length
Advanced search
* Home Help Search Login Register
SnippetMaster Support Forums  |  General  |  General Discussion & Support  |  Topic: database support « previous next »
Pages: [1] Print
Author Topic: database support  (Read 4157 times)

Posts: 2

[-] database support
« on: September 12, 2002, 03:24:29 PM »

As the original topic was locked, I restart it here.

I do agree with Martin that this is one of the best text-editing systems available (free). It would be great if the snippets could be placed in a mysql-database, or if some in-between system could be made writing them down as tpl-files, beeing  called upon with an include-statement.

I will be looking into that latest part, but is there a possibility to call on single files, not using the drop-down menu in main.html, so after inserting a basic reference in the database, the tpl-file necessary will be displayed in snippetmaster?
Report to moderator   Logged

Posts: 4

[-] good idea!
« Reply #1 on: September 13, 2002, 04:21:13 AM »

Hey andre,

Sounds like a great idea, the tpl-file! I was thinking about working on the
SSI thing. I did that with the help file, this way as the help file grows or as
I add my own support it is updated automatically and I can load it to my
clients servers with out too much editing.

Hmm, I don't have a lot of time to pull things apart but your idea is going
to keep me up late. Just have to be careful not to let the untrained would
be programmers wreak havock on my pages. Smile

Thanks - keep up to date on progress.

Paul Thomas
Report to moderator   Logged

Posts: 2

[-] database support
« Reply #2 on: September 13, 2002, 07:24:50 AM »

Hoi Paul

I spent most of the day working on it, and there is some succes.

Although everything is in Dutch, the basics are visible on

It's basics for a client presentation tomorrow.

Basic working: menu-items are written i a mysql-database. Using the cms-system -every time a new menu-item is inserted the system also writes a snippet-file (example news.tpl)
This can be easily adjusted with snippetmaster.

In the main website a simple include news.tpl (or in this case the filestring is built by php) will invoke the right text.

I have part of the code below, if you want the full code I can mail it to you


function InsertMenu ($naam, $plaats, $bestandsnaam, $cat)

$bestandstekst="<SNIPPET NAME=\"Tekst ".$naam."\">\n Hier komt de nieuwe tekst voor ".$naam." \n</snippet>";

$logfile = $bestandnaam;

if (file_exists($logfile)) {
echo ("deze bestandsnaam bestaat al, aub andere naam kiezen!");
exit ();

else {
//open file for write
$fp = fopen ("$logfile", "w");
//print "The file does not exist";

// write the params as name value pairs
fputs ($fp, $bestandstekst);

// close the file

Report to moderator   Logged

Posts: 12

[-] database support
« Reply #3 on: September 22, 2002, 03:17:43 PM »

Hi Paul,

I've been working on a mysql interface for it and have it's finished. Only thing is that it works for my site, but I've got to restyle it so that it will work on different sites/ systems as well. Like now it's fully integrated with the cms I'm building


Report to moderator   Logged
Pages: [1] Print 
SnippetMaster Support Forums  |  General  |  General Discussion & Support  |  Topic: database support « previous next »
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!