Pages: [1] |
|
|
Author |
Topic: Strips html? (Read 1921 times) |
Brad
Posts: 4
|
First of all, let me just say that I've been looking for something like this for a *long* time. Let me be the first to congratulate you for starting this project. Nice job!
Now for the question. Does this app strip existing html inside the <snippet> tags? I only ask because it appears to be doing just that on one of my pages. For example:
<SNIPPET>
<table width="50%" cellspacing="2" cellpadding="2" border="0">
<tr><!-- Row 1 -->
<td align="center">First cell I'd like a client to be able to edit...</td>
</tr>
<tr><!-- Row 2 -->
<td align="center" bgcolor="#E8F0F0">Second cell I'd like a client to be able to edit...</td>
</tr>
</table>
</SNIPPET>
After updating this page via Snippetmaster, I find that the table tags are removed and the only thing remaining is the text. I suppose I could simply move the snippet tags to surround only the text, but in the example above I have two cells that the client needs to edit. So how do I get around this?
|
|
|
|
admin
Forum Administrator

Posts: 2722
SnippetMaster Author
|
Hi there! Thanks for the compliment!
I'm not sure what is causing the problem you describe.. I've created a test page that seems to be working perfectly with the code you supplied. You can see it by going through the demo on the site and then selecting the "test1.html" file.
The contents of the whole html file is here:
<html>
<head>
<title>SnippetMaster Demo Page</title>
</head>
<body>
<SNIPPET>
<table width="50%" cellspacing="2" cellpadding="2" border="0"> <tr><!-- Row 1 -->
<td align="center">First cell I'd like a client to be able to edit...</td></tr>
<tr><!-- Row 2 --> <td align="center" bgcolor="#E8F0F0">Second cell I'd like a
client to be able to edit...</td></tr> </table>
</SNIPPET>
</body>
</html>
Can you make sure your snippet tags are on their own line?
|
|
|
|
Brad
Posts: 4
|
Thanks for the quick reply! I tried it again at your suggestion and everything is fine now. I also figured out what had caused the problem initially.
I had placed the <snippet> tags *inside* the table, trying to only give the client access to the table's 2nd row, like this:
<table width="50%" cellspacing="2" cellpadding="2" border="0">
<tr><!-- Row 1 -->
<td align="center">I don't want the client to be able to edit this row...</td>
</tr>
<SNIPPET>
<tr><!-- Row 2 -->
<td align="center" bgcolor="#E8F0F0">I'd like the client to be able to edit this one though...</td>
</tr>
</SNIPPET>
</table>
As it turns out, this can't be done with the script. That's what was wiping out the table code altogether. Once I placed the <snippet> tags outside the <table> tags, everything magically worked. This may be something you want to look into, or not. For this particular site, it's not a big deal since I know the client well. It might come in handy sometime if we were able to put the <snippet> tags "intra-table" though. Just a thought. Either way, it's still a great script.
|
|
|
|
admin
Forum Administrator

Posts: 2722
SnippetMaster Author
|
Glad to hear it's working ok now.
I think your suggestion is a good one, unfortunately it will never work because SnippetMaster is designed to work with complete HTML tags. It uses an HTML engine to render the code inside the WYSIWYG editor, so it the HTML is incomplete then it won't work.
One possible "workaround" is to use a server include for your text inside the cell, and then enable the text file with SnippetMaster.
For example, inside your cell you could use an SSI call to include a file called, "text.txt". Then inside your text.txt file you would put the snippet tags around whatever text you wanted to enable.
Hope that helps. Don't forget to rate the script or write a review at hotscripts if you have a chance.
http://www.hotscripts.com/review/?linkid=17534&returnto=http://www.hotscripts.com/Detailed/17534.html
or rank the program: http://www.hotscripts.com/Detailed/17534.html
Thanks!
|
|
|
|
Brad
Posts: 4
|
Oh I see. Well if it works that way then you're right, the snippet tags must enclose a complete HTML "thought" to work properly.
Once again, thanks for the help - I'm hooked now so you'll probably hear from me again sometime.
Oh, and consider it rated. 
|
|
|
|
admin
Forum Administrator

Posts: 2722
SnippetMaster Author
|
Thanks Brad. If you have any other suggestions or come across bugs or whatever.. don't forget to let me know.
Cheers!
|
|
|
|
|
Pages: [1]
|
|
|
|