Support Forum

Make WYSIWYG comment form with Andy's code

TR Truden
Truden
Member

Simple:Press Forum is full of wonderfully implemented ideas, and the best thing about it is that some of them you can “steal” and use in many other places.
I did it.
How?

If you have Simple:Press Forum installed in your weblog:

OPEN /simple-forum/sf-tinyinit.php

CHANGE line 11 from

elements : “newtopicpost,editpostcontent,newpmpost”,

to

elements : “comment”,

presuming that your comments textarea uses the default “comment” name and id

CHANGE line 17 from

language : “<?php echo(SFLANG); ?>”,to

language : “en”,

or the initials of your language if it is present in the language pack of TinyMCE.

DELETE line 18.
SAVE the file as sf-tinyinit_comments.php
Upload it in your theme directory.

OPEN header.php from your theme directory.

before

<?php wp_head(); ?>

ADD

<?php
    if (is_single()){   ?>
      <script type=”text/javascript” src=”http://YOUR-SITE.COM/wp-content/plugins/simple-forum/tinymce/tiny_mce.js”></script>
 <?php   include (TEMPLATEPATH . '/sf-tinyinit_comments.php'); }
 ?>
 

Change “YOUR-SITE.COM” from the above code with your domain name.
If the path to tiny_mce.js is different than the above, change the address to match.
 UPLOAD the changed header.php in its theme directory.

 THAT is ALL (I think).

 Navigate to a single page in your weblog and see your new looking comment form.

DEMO

(Please do not post DEMO-comments in the “DEMO” page.)

4 Answers

New Answer

YS Yellow Swordfish
Yellow Swordfish
Member

Hey – having fun eh? Yes – this will work…. And it's a nice tool to use for the comment editor as well.

TR Truden
Truden
Member

Yellow Swordfish said:

Hey – having fun eh?


Absolutely! Laughing

MP Mr Papa
Mr Papa
Member

I like reuse of our stuff as there are other plugins in that do that, but reuse is good… cuts down on overhead… thanks truden

TR Truden
Truden
Member

I should thank you, Mr Papa.

The pleasure was entirely mine.