Jump to content

Recommended Posts

Posted

I'd like to be able to use the IPS Editor on my own site, where I have several textareas etc. But I've spent a very long time looking and I simply can't find the code for it anywhere in any of the files. The most I've been able to find is including the CKEditor javascript fo it to work, @ applications/core/interface/ckeditor/ckeditor/ckeditor.js. I've checked in templates, PHP files, all sorts. I just can't find it. I know it needs to be customised so I expect in some way I'll need to run a PHP file in order to get the editor working.

Can anyone point me in the right direction as to where I should be looking?

Posted

Thanks for your reply but as I'm integrating my site with IPS, I'm going to need to integrate the exact same editor that IPS uses, i.e. configured in exactly the same way, essentially included from the forums including any processing which it does.

Posted
<?php

require '/path/to/forums/init.php';
\IPS\Dispatcher\External::i();

$form = new \IPS\Helpers\Form;
$form->add( new \IPS\Helpers\Form\Editor( 'name', $defaultValue, $required ) );

if( $values = $form->values() )
{
	var_dump( $values );exit;
}

\IPS\Output::i()->sendOutput( $form );

 

Untested, but you should get the idea from the above.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...