Go Back   vb.org Archive > vBulletin 4 Discussion > vB4 Programming Discussions
  #1  
Old 06-20-2011, 08:19 AM
Twilkey's Avatar
Twilkey Twilkey is offline
 
Join Date: Oct 2006
Posts: 314
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default Problem with the new editor

I am having an issue. Before 4.1.4 I used the old editor on my addon just fine. Now that we upgraded, only the smilies show up. When I refresh the page, a simple box shows up that seems like the textarea without any buttons. I have searched through vbulletins files to see if something changed with the code, but I am actually not seeing any real changes in the code needed to construct the editor. So i am not sure why this is happening. The editor works fine in the core vB system, just not in my addon.

Here is the code I use for the editor.

I have also included a screenshot of what i see on the page.

HTML
HTML Code:
<form class="vbform block" action="{vb:raw formaction}" method="post" name="vbform" onsubmit="return vB_Editor['{vb:raw editor}'].prepare_submit(0, 0)">
<div class="blockbody formcontrols">
    <h3 class="blocksubhead">{vb:raw formhead}</h3>
    <div class="section">
        <div class="blockrow">
            <label for="keyword"><b>Title:</b><br /><i>What would you like the title to be?</i></label>
            <ul class="multifield group">
                <li>
                    <input type="text" class="textbox" name="posttitle" value="{vb:raw posttitle}" tabindex="1" />
                </li>
            </ul>
        </div>
        <div class="blockrow">
            <label for="searchuser"><b>Description:</b></label>
            <ul class="multifield group">
                <li>
                    <div id="userfield" class="popupmenu nomouseover noclick nohovermenu">
                                             {vb:raw messagearea}
                    </div>
                </li>
            </ul>
        </div>
    </div>
    <div class="blockfoot actionbuttons"></div>
    <h3 class="blocksubhead">Additional options </h3>
    <div class="section" id="additionaloptions">
        <div class="blockrow">
        <label for="searchdate"><b>Co-Authors:</b><br /><i>(Seperate with commas)</i></label>
            <ul class="multifield group">
                <li>
                    <input type="text" class="textbox" name="postcoauthors" value="{vb:raw postcoauthors}" />
                </li>
            </ul>
        </div>
    <div class="blockfoot actionbuttons">
            <div class="group">
            <input type="submit" class="button" name="submit" value="Submit Now" tabindex="1" accesskey="s"/>
            <input type="reset" class="button" value="Reset" tabindex="1" accesskey="r" />
            </div>
        </div>
    </div>
</div>

<input type="hidden" name="subcatid" value="{vb:raw subcatid}" />
<input type="hidden" name="id" value="{vb:raw id}" />
<input type="hidden" name="s" value="{vb:raw session.sessionhash}" />
<input type="hidden" name="securitytoken" value="{vb:raw bbuserinfo.securitytoken}" />
</form>
PHP
PHP Code:
    require_once(DIR '/includes/functions_editor.php');
    
$editor construct_edit_toolbar($postdescription0'nonforum'110'fe''''''content''vBForum_Post'0001$postid);  
    
/* function construct_edit_toolbar($text = '', $ishtml = 0, $forumid = 0, $allowsmilie = 1, $parsesmilie = 1, $can_attach = false, $editor_type = 'fe', $force_editorid = '') */ 
PHP Code:
$templater->register('messagearea'$messagearea);
$templater->register('editor'$editor); 
Attached Images
File Type: jpg screen.jpg (14.7 KB, 0 views)
Reply With Quote
  #2  
Old 06-20-2011, 02:05 PM
Lynne's Avatar
Lynne Lynne is offline
 
Join Date: Sep 2004
Location: California/Idaho
Posts: 41,180
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Check out the new template editor_ckeditor and then also do a search in your files for where $ckeditor gets defined.
Reply With Quote
  #3  
Old 06-20-2011, 02:28 PM
Twilkey's Avatar
Twilkey Twilkey is offline
 
Join Date: Oct 2006
Posts: 314
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I dont guess you know off hand what file that would be?
Reply With Quote
  #4  
Old 06-20-2011, 02:30 PM
Lynne's Avatar
Lynne Lynne is offline
 
Join Date: Sep 2004
Location: California/Idaho
Posts: 41,180
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Does your text editor not allow you to search files in a directory? I couldn't do a thing if I didn't have that function.

Look in clientscript/ckeditor/ckeditor_php5.php
Reply With Quote
  #5  
Old 06-21-2011, 02:48 PM
bananalive bananalive is offline
 
Join Date: Oct 2007
Location: UK
Posts: 2,802
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

Have you got it working? I've been trying and failing to implement ckeditor


Have you included this in the <head>?

HTML Code:
<script src="clientscript/vbulletin-editor.js?v=414" type="text/javascript"></script>
Reply With Quote
  #6  
Old 07-27-2011, 03:13 PM
Bowner Bowner is offline
 
Join Date: Jan 2011
Posts: 1
Благодарил(а): 0 раз(а)
Поблагодарили: 0 раз(а) в 0 сообщениях
Default

I had the same sort of problem - all I had to do was change the file permissions for all files.

chown -R user:user /home/user/public_html/forum

* replace user with your username.

hope this helps
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 02:25 PM.


Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2024, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.03911 seconds
  • Memory Usage 2,245KB
  • Queries Executed 14 (?)
More Information
Template Usage:
  • (1)SHOWTHREAD
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)ad_showthread_beforeqr
  • (1)ad_showthread_firstpost
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (2)bbcode_html
  • (2)bbcode_php
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)navbar
  • (3)navbar_link
  • (120)option
  • (6)post_thanks_box
  • (6)post_thanks_button
  • (1)post_thanks_javascript
  • (1)post_thanks_navbar_search
  • (6)post_thanks_postbit_info
  • (6)postbit
  • (1)postbit_attachment
  • (6)postbit_onlinestatus
  • (6)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available:
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files:
  • ./showthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_post_thanks.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • forumjump
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • post_thanks_function_post_thanks_off_start
  • post_thanks_function_post_thanks_off_end
  • post_thanks_function_fetch_thanks_start
  • post_thanks_function_fetch_thanks_end
  • post_thanks_function_thanked_already_start
  • post_thanks_function_thanked_already_end
  • fetch_musername
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_attachment
  • postbit_display_complete
  • post_thanks_function_can_thank_this_post_start
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • showthread_complete