Guest Posted February 9, 2009 Share Posted February 9, 2009 thanks for your reply , sorry to sound so noobish but what does " ps require("fckeditor/fckeditor.php"); mean ?" can you point me in the right direction , also do you have an updated install guide , i am using this guide this version is compatible with the recent version of oscommerce of 13 November 2005 the version called: osCommerce 2.2 Milestone 2 Update 051113 FCKeditor for Product Descriptions created by Nick Marques 6 Feb 2005 this version include: - the firts verion created by Nick Marques on 6 Feb 2005-- Nick Marques muzicman9382@hotmail.com 6 Feb 2.005 -- Version FCKeditor for Product Descriptions - the firts fix: Doku-Fix version , kofl , 2 Oct 2005 - the second fix: Small Update (added "echo" for tep_draw_fckeditor , ckmuc , 30 Oct 2005 - and a fix to the version osCommerce 2.2 Milestone 2 Update 051113 DESCRIPTION ----------- Dir. contribution: http://www.oscommerce.com/community/contributions,2900 This is my simple MOD to osCommerce 2.2 MS2 that adds the wonderful FCKeditor WYSIWYG editor to osCommerce. FCKeditor 2.0 RC2 is the version I am adding, but depending on updates, it should work with future versions. I am not a developer of FCKeditor... I'm just a user of it describing how to add it to osCommerce. FCKeditor is very easy to install and is completely usable sitewide, in place of virtually any textarea or textbox. It can be highly customized for your needs or preferences. This describes how to install it for editing product descriptions Demo FCKeditor: http://www.fckeditor.net/demo/demo02.html INSTALLATION ----------- 1. Download FCKeditor http://www.fckeditor.net/ version at 11/18/2.005: FCKeditor 2.1.1 this include a directory called FCKeditor 2. Installation of FCKeditor 2.1 put it in the admin directory install it at http://www.yoursite.com/admin/FCKeditor/ in catalog/admin/FCKeditor/ in http://www.yoursite.com/admin/FCKeditor/_samples/default.html you can see a demo 2.2 changeds to files: ---------------------- ######## OPEN ######## /admin/categories.php ###################### ######## FIND (LINE 538) ######## <td class="main"><?php echo tep_draw_textarea_field('products_description[' . $languages[$i]['id'] . ']', 'soft', '70', '15', (isset($products_description[$languages[$i]['id']]) ? $products_description[$languages[$i]['id']] : tep_get_products_description($pInfo->products_id, $languages[$i]['id']))); ?></td> ################################# ######## REPLACE WITH ######## ######## You may edit the 600 and the 300 in ######## ######## this line to change the height and ######## ######## width of the editor ######## <td class="main"><?php echo tep_draw_fckeditor('products_description[' . $languages[$i]['id'] . ']','600','300',(isset($products_description[$languages[$i]['id']]) ? stripslashes($products_description[$languages[$i]['id']]) : tep_get_products_description($pInfo->products_id, $languages[$i]['id']))); ?></td> ############################## ######## OPEN ######## /admin/includes/functions/html_output.php ###################### ######## FIND (LINE 13-14) ######## //// // The HTML href link wrapper function ################################### ######## BEFORE ADD ######## require("FCKeditor/fckeditor.php"); ############################ ######## FIND (LINE 235-253) ######## //// // Output a form textarea field function tep_draw_textarea_field($name, $wrap, $width, $height, $text = '', $parameters = '', $reinsert_value = true) { $field = '<textarea name="' . tep_output_string($name) . '" wrap="' . tep_output_string($wrap) . '" cols="' . tep_output_string($width) . '" rows="' . tep_output_string($height) . '"'; if (tep_not_null($parameters)) $field .= ' ' . $parameters; $field .= '>'; if ( (isset($GLOBALS[$name])) && ($reinsert_value == true) ) { $field .= tep_output_string_protected(stripslashes($GLOBALS[$name])); } elseif (tep_not_null($text)) { $field .= tep_output_string_protected($text); } $field .= '</textarea>'; return $field; } #################################### ######## AFTER ADD ######## //// // Output a form textarea field w/ fckeditor function tep_draw_fckeditor($name, $width, $height, $text) { $oFCKeditor = new FCKeditor($name); $oFCKeditor -> Width = $width; $oFCKeditor -> Height = $height; $oFCKeditor -> BasePath = 'FCKeditor/'; $oFCKeditor -> Value = $text; $field = $oFCKeditor->Create($name); return $field; } ########################### 3. Go to Administration >> Catalog >> Categories/Products edit any of the products to see the FCKeditor in the description of a product regards can you please take a look at the code ? i have added the code , can you tell me if this is correct , as i still can not get this to work, as soon as i get this working i can start building my site <?php /* $Id: html_output.php 1739 2007-12-20 00:52:16Z hpdl $ osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Copyright (c) 2007 osCommerce Released under the GNU General Public License */ //// // require("FCKeditor/fckeditor.php");The HTML href link wrapper function function tep_href_link($page = '', $parameters = '', $connection = 'NONSSL') { if ($page == '') { die('</td></tr></table></td></tr></table><br><br><font color="#ff0000"><b>Error!</b></font><br><br><b>Unable to determine the page link!<br><br>Function used:<br><br>tep_href_link(\'' . $page . '\', \'' . $parameters . '\', \'' . $connection . '\')</b>'); regards Quote Link to comment Share on other sites More sharing options...
spooks Posted February 9, 2009 Author Share Posted February 9, 2009 If you follow the contrib link in this thread it will take you top my install, You seem to be useing another!!! ps I was hinting but // require("FCKeditor/fckeditor.php");The HTML href link wrapper function should be require("FCKeditor/fckeditor.php");The HTML href link wrapper function I think perhaps you need to learn code. ;) Quote Sam Remember, What you think I ment may not be what I thought I ment when I said it. Contributions: Auto Backup your Database, Easy way Multi Images with Fancy Pop-ups, Easy way Products in columns with multi buy etc etc Disable any Category or Product, Easy way Secure & Improve your account pages et al. Link to comment Share on other sites More sharing options...
spooks Posted February 9, 2009 Author Share Posted February 9, 2009 Group: Community MemberPosts: 44 Joined: 5-November 06 Member No.: 135,390 When I try to do a search for a product or fragrance in my shop I get this message: 1146 - Table 'zajanat_oscstore.TABLE_PRODUCTS_IMAGES' doesn't exist select count(distinct p.products_id) as total from products p left join manufacturers m using(manufacturers_id) left join specials s on p.products_id = s.products_id left join TABLE_PRODUCTS_IMAGES pi on p.products_id = pi.products_id , products_description pd, categories c, products_to_categories p2c where p.products_status = '1' and p.products_id = pd.products_id and pd.language_id = '1' and p.products_id = p2c.products_id and p2c.categories_id = c.categories_id and pi.product_page = '1' and ((pd.products_name like '%vanilla%' or p.products_model like '%vanilla%' or m.manufacturers_name like '%vanilla%') ) the shop is http://www.zajanatural.com It has been like this for about a week, I have been trying to find a fix. I believe the contrib I installed right before this happened was the FCK html editor, but that works fine (I remember having to tweak it a bit to work for me.) I did try to install more pics but that did not work so I gave up. Can anyone please help me find a solution to this error message? Thanks, not related to this thread, check your install for PRODUCTS_IMAGES, you've messed up there Quote Sam Remember, What you think I ment may not be what I thought I ment when I said it. Contributions: Auto Backup your Database, Easy way Multi Images with Fancy Pop-ups, Easy way Products in columns with multi buy etc etc Disable any Category or Product, Easy way Secure & Improve your account pages et al. Link to comment Share on other sites More sharing options...
Guest Posted February 11, 2009 Share Posted February 11, 2009 Hi all, great contrib, everything works except I get one error on send email to customer, chased my tail all day, hope someone can point me in the right direction error message reads "Warning: Missing argument 4 for tep_draw_fckeditor() in /home/hsphere/local/home/*********/*********/admin/includes/functions/html_output.php on line 294 Many thanks Neil Quote Link to comment Share on other sites More sharing options...
spooks Posted February 11, 2009 Author Share Posted February 11, 2009 Did you use the latest install?? This is a bug that was fixed ages ago!!! in html output you should have added: //// //// // Output a form textarea field w/ fckeditor function tep_draw_fckeditor($name, $width, $height, $text='') { $oFCKeditor = new FCKeditor($name); $oFCKeditor -> Width = $width; $oFCKeditor -> Height = $height; $oFCKeditor -> BasePath = 'fckeditor/'; $oFCKeditor -> Value = $text; $field = $oFCKeditor->Create($name); return $field; } if not exactly that, you used an old install! :blink: Quote Sam Remember, What you think I ment may not be what I thought I ment when I said it. Contributions: Auto Backup your Database, Easy way Multi Images with Fancy Pop-ups, Easy way Products in columns with multi buy etc etc Disable any Category or Product, Easy way Secure & Improve your account pages et al. Link to comment Share on other sites More sharing options...
Guest Posted February 11, 2009 Share Posted February 11, 2009 Thanks Spooks, code's are both the same, the fckeditor actually shows up on the page the error message is just above it ! Neil Quote Link to comment Share on other sites More sharing options...
spooks Posted February 11, 2009 Author Share Posted February 11, 2009 (edited) can you post your code from html_output.php around that line, and mark the offendiong one. also the lines from your calling page Edited February 11, 2009 by spooks Quote Sam Remember, What you think I ment may not be what I thought I ment when I said it. Contributions: Auto Backup your Database, Easy way Multi Images with Fancy Pop-ups, Easy way Products in columns with multi buy etc etc Disable any Category or Product, Easy way Secure & Improve your account pages et al. Link to comment Share on other sites More sharing options...
Guest Posted February 11, 2009 Share Posted February 11, 2009 extract of code just above and below if ( ($reinsert_value == true) && ( (isset($HTTP_GET_VARS[$name]) && is_string($HTTP_GET_VARS[$name])) || (isset($HTTP_POST_VARS[$name]) && is_string($HTTP_POST_VARS[$name])) ) ) { if (isset($HTTP_GET_VARS[$name]) && is_string($HTTP_GET_VARS[$name])) { $field .= tep_output_string_protected(stripslashes($HTTP_GET_VARS[$name])); } elseif (isset($HTTP_POST_VARS[$name]) && is_string($HTTP_POST_VARS[$name])) { $field .= tep_output_string_protected(stripslashes($HTTP_POST_VARS[$name])); } } elseif (tep_not_null($text)) { $field .= tep_output_string_protected($text); } $field .= '</textarea>'; return $field; } //// //// // Output a form textarea field w/ fckeditor function tep_draw_fckeditor($name, $width, $height, $text) { $oFCKeditor = new FCKeditor($name); $oFCKeditor -> Width = $width; $oFCKeditor -> Height = $height; $oFCKeditor -> BasePath = 'fckeditor/'; $oFCKeditor -> Value = $text; $field = $oFCKeditor->Create($name); return $field; } //// // Output a form hidden field function tep_draw_hidden_field($name, $value = '', $parameters = '') { global $HTTP_GET_VARS, $HTTP_POST_VARS; $field = '<input type="hidden" name="' . tep_output_string($name) . '"'; Quote Link to comment Share on other sites More sharing options...
spooks Posted February 11, 2009 Author Share Posted February 11, 2009 You lied!!! you said you had exactly what I gave, but you have'nt!!! function tep_draw_fckeditor($name, $width, $height, $text) { should be function tep_draw_fckeditor($name, $width, $height, $text= '' ) { so you did'nt use the latest install... :rolleyes: :rolleyes: :rolleyes: Quote Sam Remember, What you think I ment may not be what I thought I ment when I said it. Contributions: Auto Backup your Database, Easy way Multi Images with Fancy Pop-ups, Easy way Products in columns with multi buy etc etc Disable any Category or Product, Easy way Secure & Improve your account pages et al. Link to comment Share on other sites More sharing options...
Guest Posted February 11, 2009 Share Posted February 11, 2009 Sam, my apologies I've been looking at this all day you get to the stage that it looks the same because it should be, I can't believe even at 64 that I have been so stupid, Thank you Sam Neil Quote Link to comment Share on other sites More sharing options...
iStan Posted February 21, 2009 Share Posted February 21, 2009 Just a quick note to say thank you very much, spooks. This is a handy little mod that is straightforward to install and works as advertised, somewhat of a rare combination. I did a trial run on a test install of osc (once bitten, twice shy- I would recommend setting up a test install to try out various mods and tinkerings as a very good idea), and was very pleased with the results. I just installed it on my live osc and all is good. Thanks once again. Quote Link to comment Share on other sites More sharing options...
bkherren Posted February 24, 2009 Share Posted February 24, 2009 Thank you, thank you, thank you! This is such a wonderful contribution! B Herren :thumbsup: Quote Link to comment Share on other sites More sharing options...
vyung Posted February 26, 2009 Share Posted February 26, 2009 (edited) In the installation instruction for FCKeditor 2.6.4, it says 'Check your "images" directory permissions are set to 777'. From past experience, however, I am concerned about the folder security and would like to tighten the folder security to 755. My question is, will changing the 'images' folder permission to 755 affect the functioning of the FCK editor? Edited February 26, 2009 by vyung Quote Link to comment Share on other sites More sharing options...
Whiskers Posted February 27, 2009 Share Posted February 27, 2009 Hi all, I have just installed osCommerce and need to put this product description editor in, but haven't got a clue where to put it. Do I just copy and paste something in? I am a complete novice at this, sorry. Quote Link to comment Share on other sites More sharing options...
spooks Posted February 27, 2009 Author Share Posted February 27, 2009 As with all the contribs, simply follow the instructions contained therein! :) Quote Sam Remember, What you think I ment may not be what I thought I ment when I said it. Contributions: Auto Backup your Database, Easy way Multi Images with Fancy Pop-ups, Easy way Products in columns with multi buy etc etc Disable any Category or Product, Easy way Secure & Improve your account pages et al. Link to comment Share on other sites More sharing options...
Whiskers Posted February 27, 2009 Share Posted February 27, 2009 As with all the contribs, simply follow the instructions contained therein! :) Do you mean inside the download file? Sorry for such newbie questions. :( Quote Link to comment Share on other sites More sharing options...
spooks Posted February 27, 2009 Author Share Posted February 27, 2009 Where else!! Is this a wind up?? Quote Sam Remember, What you think I ment may not be what I thought I ment when I said it. Contributions: Auto Backup your Database, Easy way Multi Images with Fancy Pop-ups, Easy way Products in columns with multi buy etc etc Disable any Category or Product, Easy way Secure & Improve your account pages et al. Link to comment Share on other sites More sharing options...
Whiskers Posted February 27, 2009 Share Posted February 27, 2009 Where else!! Is this a wind up?? If I knew where else then I wouldn't be asking would I?! Do you seem to magically know things before you find them out?! NO! So either be helpful or say nothing. Quote Link to comment Share on other sites More sharing options...
spooks Posted February 27, 2009 Author Share Posted February 27, 2009 Fine, keep off my threads. :angry: Quote Sam Remember, What you think I ment may not be what I thought I ment when I said it. Contributions: Auto Backup your Database, Easy way Multi Images with Fancy Pop-ups, Easy way Products in columns with multi buy etc etc Disable any Category or Product, Easy way Secure & Improve your account pages et al. Link to comment Share on other sites More sharing options...
Whiskers Posted February 27, 2009 Share Posted February 27, 2009 Fine, keep off my threads. :angry: I came here for assistance, as I thought that was what a "Community Support Forum" was for. Any sensible people got any advice? Quote Link to comment Share on other sites More sharing options...
Whiskers Posted March 2, 2009 Share Posted March 2, 2009 Right spooks, lets have some help please. A bit of a walk through if you don't mind. I download the contribution onto my PC, then I upload it using FTP to my website, but what file do I put the folder in, in the public_html or www, or where? I tried both and keep getting errors. It says in your instructions that it's best to install it to www.yoursite.com/FCKeditor, but that is where I'm confused. Do I need to create a folder? Please explain it in real basic terms step-by-step. :) Quote Link to comment Share on other sites More sharing options...
Solan Posted March 2, 2009 Share Posted March 2, 2009 (edited) Hi, it doesnt seem to be a support thread for paige editor so i´m hoping for some help here.. i´ve been installing This FCK WYSIWYG HTML editor and it works perfect.. But i would so like it to function with the contrib page editor : http://addons.oscommerce.com/info/2841 can anyone tell me what code and where i must put it, for it to work with page editor? I´ve been tearing my hair off for this and i just dont get it right :blush: Edited March 2, 2009 by Solan Quote Link to comment Share on other sites More sharing options...
spooks Posted March 2, 2009 Author Share Posted March 2, 2009 Did you try following the instructions in this package for extra fields? I don`t know that one, but as per above tep_draw_textarea_field('pages_body[' . $languages[$i]['id'] . ']', 'soft', '60', '15', (isset($pages_body[$languages[$i]['id']]) ? $pages_body[$languages[$i]['id']] : tep_get_pages_body($pInfo->pages_id, $languages[$i]['id']))); becomes: (im guessing at the relavent field) tep_draw_fckeditor('pages_body[' . $languages[$i]['id'] . ']','900','800', (isset($pages_body[$languages[$i]['id']]) ? $pages_body[$languages[$i]['id']] : tep_get_pages_body($pInfo->pages_id, $languages[$i]['id']))); Quote Sam Remember, What you think I ment may not be what I thought I ment when I said it. Contributions: Auto Backup your Database, Easy way Multi Images with Fancy Pop-ups, Easy way Products in columns with multi buy etc etc Disable any Category or Product, Easy way Secure & Improve your account pages et al. Link to comment Share on other sites More sharing options...
Solan Posted March 2, 2009 Share Posted March 2, 2009 (edited) Thanks Sam.. everything works fine at the product desc, but i´d like the FCK editor to be my editor in page editor as well.. the code you gave me... in what file is that? i could have i look in my files for that.. Edited March 2, 2009 by Solan Quote Link to comment Share on other sites More sharing options...
spooks Posted March 2, 2009 Author Share Posted March 2, 2009 admin/pages.php, the file you load to edit page!!! PHP Tuition http://us.php.net/tut.php Quote Sam Remember, What you think I ment may not be what I thought I ment when I said it. Contributions: Auto Backup your Database, Easy way Multi Images with Fancy Pop-ups, Easy way Products in columns with multi buy etc etc Disable any Category or Product, Easy way Secure & Improve your account pages et al. Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.