MyBB Community Forums

Full Version: NEW - WYSIWYG Rich Text Editor (Build-in BBCode Editor) for MyBB 1.2.3
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
so what and where do i turn the quick edit off?
spikescot2005 Wrote:so what and where do i turn the quick edit off?

You need to edit template Post Bit Templates/postbit_edit - Read file Hoteditor_Mod_MyBB.txt for more information

Quote:#
#-----[ Edit Original Template 4/6 ]------------------------------------------
# --> Post Bit Templates/postbit_edit
#
# Find and click [Post Bit Templates] link
# Next screen find and click the link [postbit_edit]
# Copy and paste the HTML code below to textbox Template (replace the current HTML code you see inside textbox), then click Add Template button.
# Explain: Use Ajax to edit message inline (Quick Edit) is great but it won't work with WYSIWYG - we need to remove this feature
# When user click Edit button, he will see HotEditor on the next screen (work like Full Edit feature)
#

<a href="editpost.php?pid={$post['pid']}" id="edit_post_{$post['pid']}"><img src="{$theme['imglangdir']}/postbit_edit.gif" alt="{$lang->postbit_edit}" title="{$lang->postbit_edit}" /></a>
Hello guys!

Below is the instruction to show you how to make Hoteditor work with Quick Edit feature.

NOTE: This instruction is for those who already installed WYSIWYG MOD.

- Use Text editor to open file xmlhttp.php (locate at main folder)
- Find around line number 317 block code below

if($mybb->input['do'] == "get_post")
{
	// Send our headers.
	header("Content-type: text/html; charset={$charset}");
		
	$post['message'] = htmlspecialchars_uni($post['message']);
		
	// Send the contents of the post.
	eval("\$inline_editor = \"".$templates->get("xmlhttp_inline_post_editor")."\";");
	echo "<?xml version=\"1.0\" encoding=\"{$charset}\"?".">";
	echo "<form>".$inline_editor."</form>";
	exit;
}

- REPLACE WITH

if($mybb->input['do'] == "get_post")
{
	// Send our headers.
	header("Content-type: text/html; charset={$charset}");
	
	//EDITOR
	$post['message']=str_replace("[&amp;lt;]","&amp;amp;lt;",$post['message']);
	$post['message']=str_replace("[&amp;gt;]","&amp;amp;gt;",$post['message']);

	$post['message'] = htmlspecialchars_uni($post['message']);
	
	// Send the contents of the post.
	eval("\$inline_editor = \"".$templates->get("xmlhttp_inline_post_editor")."\";");
	echo "<?xml version=\"1.0\" encoding=\"{$charset}\"?".">";
	echo "<form>".$inline_editor."</form>";
	exit;
}

- Login to your admin area - click link Templates / Modify - Delete - Find your Default Templates then click Expand button

- Next screen, scroll down and click link Post Bit Templates - Find the link postbit_edit and click button Revert to Original

- Next, still on page Template Manager, scroll down to bottom and click link xmlhttp_inline_post_editor. Copy and paste the HTML code below to textbox Template (replace the current HTML code you see inside textbox), then click Add Template button.

<br />
<div style="clear: both;">
<iframe frameborder=0 width=100% height=510px src="hoteditor_quickedit.php?id={$post['pid']}" scrolling=no target="_top"></iframe>
<div>
<textarea style="visibility:hidden;" id="quickedit_{$post['pid']}" />{$post['message']}</textarea>
</div>			
</div>

- Upload file hoteditor_quickedit.php to main Mybb folder.

That's all you need to do.

Download all update files here http://www.ecardmax.com/index.php?step=Hoteditor2MyBB - You have to update file richedit/editor.js as well.

To see DEMO how Quick Edit works with Hoteditor visit our demo MyBB forum here http://www.ecardmax.com/hoteditor_forums/mybb_123 login with ID: demo - PASS 123456 - post your message then at page showthread click Edit button ([Image: postbit_edit.gif]) and select Quick Edit.

Good luck with your site
I did everything it said basically in the Mod instructions. Except I just replaced my member.php file, and the other .php file with the one that came with. Then I edited the templates as told. But when I tried to edit, everything went fine, but the page never updated. I'll keep it uninstalled for now, but this is a must have feature for me. =P
Great job. I am glad someone is working on this and maybe it will stay off the mybb core.

For my Opera your demo appears to work just fine.
Quote:Find the link postbit_edit and click button Revert to Original

I dont have that button
How can I integrate the Mycodes that I have editted by myself? For example the codes of "you tube".
Ok now i cant edit posts. Just comes up with editor when i click quick edit.

Reverted it back to haw it was now
adigec Wrote:How can I integrate the Mycodes that I have editted by myself? For example the codes of "you tube".

I think you should edit the editor.js file, but we waiting the right answere from eCardMAX.com
to be sure about the right way to do it
spikescot2005 Wrote:
Quote:Find the link postbit_edit and click button Revert to Original

I dont have that button
You don't see Revert to Original button that means you are using the original postbit_edit. In this case you need to update template xmlhttp_inline_post_editor and upload file hoteditor_quickedit.php to your mybb folder and go test Quick Edit
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24