Jump to content
Sign in to follow this  
MaxiDVD

[SUPPORT] HTML Editor and UltraPics by MaxiDVD

Recommended Posts

Hey Guys,

 

I'm new to OsCommence. I'm trying to get more than one pictures to show up for products.

 

I installed the files on a FRESH install. The SQL file was successful through phpMyadmin.

 

I just don't know how to get more than one file in the products.

 

Thanks

Gary Osterholt

Share this post


Link to post
Share on other sites

Hi,

 

Can someone please supply a link to a website that has this "Ultrapics" contribution working please, as I need to show a client if it would be suitable.

 

Peter

Share this post


Link to post
Share on other sites

Hi,

Can anyone help me with the following error.

 

Parse error: parse error, unexpected $ in /home/matty1/public_html/testshop/admin/categories.php on line 1895

 

This error occurs when I select catalog in the admin area, it has only started happening since trying to install this contrib and Attribute Sets 2.0.1 together.

 

Here is some of the code in the categories.php where I think the problem is as this is where I have tried to merge the two contribs.

 

if (($HTTP_POST_VARS['unlink_image_xl_6'] == 'yes') or ($HTTP_POST_VARS['delete_image_xl_6'] == 'yes')) {

$products_image_xl_6 = '';

$products_image_xl_6_name = '';

} elseif (WYSIWYG_USE_PHP_IMAGE_MANAGER == 'Disable') {

$products_image_xl_6 = new upload('products_image_xl_6');

$products_image_xl_6->set_destination(DIR_FS_CATALOG_IMAGES);

if ($products_image_xl_6->parse() && $products_image_xl_6->save()) {

$products_image_xl_6_name = $products_image_xl_6->filename;

} else {

$products_image_xl_6_name = (isset($HTTP_POST_VARS['products_previous_image_xl_6']) ? $HTTP_POST_VARS['products_previous_image_xl_6'] : '');

}

} else {

if (isset($HTTP_POST_VARS['products_image_xl_6']) && tep_not_null($HTTP_POST_VARS['products_image_xl_6']) && ($HTTP_POST_VARS['products_image_xl_6'] != 'none')) {

$products_image_xl_6_name = $HTTP_POST_VARS['products_image_xl_6'];

} else {

$products_image_xl_6_name = (isset($HTTP_POST_VARS['products_previous_image_xl_6']) ? $HTTP_POST_VARS['products_previous_image_xl_6'] : '');

}

//JJG preview - warning that an Attribute Set is set to '--none--' Begin

$WARNING_MSG = "<b>ATTRIBUTE SET WARNING:</b> At least one Attribute Set is set to '--none--'";

$WARNING_MSG .= " of the ".$HTTP_POST_VARS['AttributeSetCount']. " total set(s) used for this product.";

for($i=0; $i<$HTTP_POST_VARS['AttributeSetCount']; $i++){

if( empty($HTTP_POST_VARS["products_attributes_sets_id_$i"]) ){

$messageStack->add($WARNING_MSG, 'error');

}

}

//JJG preview - warning that an Attribute Set is set to '--none--' Endbreak;

// EOF MaxiDVD: Modified For Ultimate Images Pack!

}

}

 

// check if the catalog image directory exists

 

Here are the last 12 lines of code

 

<!-- body_text_eof //-->

</tr>

</table>

<!-- body_eof //-->

 

<!-- footer //-->

<?php require(DIR_WS_INCLUDES . 'footer.php'); ?>

<!-- footer_eof //-->

<br>

</body>

</html>

<?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>

 

The last line is my line 1895 as shown in the error

 

Many Thanks in advance to anyone who can help me.

 

Phil

Share this post


Link to post
Share on other sites

Peter,

If you have no luck with the links by the time I get my test site working I will supply you the link required

 

Regards

Phil

 

Hi,

 

Can someone please supply a link to a website that has this "Ultrapics" contribution working please, as I need to show a client if it would be suitable.

 

Peter

Share this post


Link to post
Share on other sites

Hi,

 

If you have no luck with the links by the time I get my test site working I will supply you the link required.

 

Okay, thanks, I did get a link, but it was to an 'adult' site, not something that I'd want to look at, or show any client, so yes, if you do remember to post the link later on, great.

 

Re the prase error, sometimes I get one at the last line, because there is an incomplete 'If" construct, or an incomplete "while" loop, so check that there are matching opening and closing brackets everywhere.

 

Or, comment out the last line, and see if the error is on the line before it.

 

Peter

Share this post


Link to post
Share on other sites

Peter,

I comment out the last line and the line number in the error changed from 1895 to 1896. What would this suggest.

 

Phil

 

 

Hi,

Okay, thanks, I did get a link, but it was to an 'adult' site, not something that I'd want to look at, or show any client, so yes, if you do remember to post the link later on, great.

 

Re the prase error, sometimes I get one at the last line, because there is an incomplete 'If" construct, or an incomplete "while" loop, so check that there are matching opening and closing brackets everywhere.

 

Or, comment out the last line, and see if the error is on the line before it.

 

Peter

Share this post


Link to post
Share on other sites

 

should this

//JJG preview - warning that an Attribute Set is set to '--none--' Endbreak;
// EOF MaxiDVD: Modified For Ultimate Images Pack!

not read

//JJG preview - warning that an Attribute Set is set to '--none--' End
break;
// EOF MaxiDVD: Modified For Ultimate Images Pack!


No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P

Is your Osc dated try Phoenix  raising oscommerce from the ashes.

Share this post


Link to post
Share on other sites

Hi Steve,

 

Yes, I would say so, and actually the block of code to be inserted is:

 

//JJG preview - warning that an Attribute Set is set to '--none--' Begin        
       $WARNING_MSG = "<b>ATTRIBUTE SET WARNING:</b> At least one Attribute Set is set to '--none--'";
       $WARNING_MSG .= "  of the  ".$HTTP_POST_VARS['AttributeSetCount']. " total set(s) used for this product.";
       for($i=0; $i<$HTTP_POST_VARS['AttributeSetCount']; $i++){
 if( empty($HTTP_POST_VARS["products_attributes_sets_id_$i"]) ){
	 $messageStack->add($WARNING_MSG, 'error');
 }
       }
//JJG preview - warning that an Attribute Set is set to '--none--' End        
       break;

 

I guess if the 'install.txt' was opened in something like Notepad, then the line break (LF) is often not recognised, best to use something like Crimson Editor.

 

Anyway, with "Beyond Compare" to the rescue, Phil got the problem sorted out, it was _much_ easier inserting the mods from a 'loaded' categories.php file , especially as categories.php already had considerable mods in it.

 

There are still 3 "short tags" like this .........

 

ultra_image.OscImageRoot = '<?= trim(HTTP_SERVER . DIR_WS_CATALOG_IMAGES) ?>';

 

and the number of opening brackets does not equal the number of closing, but Phil says it's all working well, so I have to assume those issues don't matter ??

 

Thanks,

 

Peter

Share this post


Link to post
Share on other sites

Hi,

 

Can someone please advise what advantages this contribution, has over say this one:

 

http://www.oscommerce.com/community/contributions,1347

 

... plus a good thumbnail contribution ? It seems contrib. # 1347 , the WYSIWYG HTML editor can be used on almost any file/s.

 

I should explain what I'm looking for, might be more helpful. :)

 

Client #1

 

* Needs a HTML editor to put out newsletters, however the site is "somewhere" between MS-1 and MS-2, plus very heavily loaded with contributions, so we are somewhat limited in what can be installed.

 

Client#2

 

* Needs to be able to use a HTML editor for main page (index.php), product description, category descriptions, plus _possibly_ use it for other pages, shipping, privacy,etc,etc

 

* Needs a good 'thumbnailer' for the main image shown on product_info, plus the thumbnailer needs to work on other 'boxes' (specials, new products, category pages)

 

* Needs to be able to have multiple images shown on any 'product_info' page, the images are properly thumbnailed (not just scaled down), and enlarged on the 'click here' or double-click.

 

Hope that explains it, thanks,

 

Peter

Share this post


Link to post
Share on other sites

Peter,

You are right the install.txt was opened in notepad.

 

Credit goes to you for sorting the problem out for me.

As you have now seen I'm sure you can agree that everything is working ok even with different number of opening brackets to closing brackets.

 

Thanks for your help

Phil

 

Hi Steve,

 

Yes, I would say so, and actually the block of code to be inserted is:

 

//JJG preview - warning that an Attribute Set is set to '--none--' Begin ? ? ? ?
? ? ? ?$WARNING_MSG = "<b>ATTRIBUTE SET WARNING:</b> At least one Attribute Set is set to '--none--'";
? ? ? ?$WARNING_MSG .= " ?of the ?".$HTTP_POST_VARS['AttributeSetCount']. " total set(s) used for this product.";
? ? ? ?for($i=0; $i<$HTTP_POST_VARS['AttributeSetCount']; $i++){
?if( empty($HTTP_POST_VARS["products_attributes_sets_id_$i"]) ){
?	$messageStack->add($WARNING_MSG, 'error');
?}
? ? ? ?}
//JJG preview - warning that an Attribute Set is set to '--none--' End ? ? ? ?
? ? ? ?break;

 

I guess if the 'install.txt' was opened in something like Notepad, then the line break (LF) is often not recognised, best to use something like Crimson Editor.

 

Anyway, with "Beyond Compare" to the rescue, Phil got the problem sorted out, it was _much_ easier inserting the mods from a 'loaded' categories.php file , especially as categories.php already had considerable mods in it.

 

There are still 3 "short tags" like this .........

 

ultra_image.OscImageRoot = '<?= trim(HTTP_SERVER . DIR_WS_CATALOG_IMAGES) ?>';

 

and the number of opening brackets does not equal the number of closing, but Phil says it's all working well, so I have to assume those issues don't matter ??

 

Thanks,

 

Peter

Share this post


Link to post
Share on other sites

I am trying to add more than six images to this Contribution. I have been able to add the fields and they appear to be working. I am getting an error in the page when I add any lines to the editor.generate section of categories.php. I tried adding

 

editor_generate('products_image_sm_7',additonal_image);

editor_generate('products_image_xl_7',additonal_image);

 

just before </script>. When I add one line, it says there is an error on the page. Is there a predefined amount of images that is set somewhere? I have been working on getting this to work for hours and I ran into this error. I don't want to release the site with an error, even if it is in the admin area.

 

How can I add more lines to the javascript code to generate more editor fields?

 

Thanks for your help.

-Tfadonis

Edited by tfadonis

Share this post


Link to post
Share on other sites
I've installed the UltraPics - MS2 Image Addon Pack! (1642) and I'm getting the following when I open the image manager.

 

picture1.jpg

 

I'm also getting the security warning about nonsecure information when I try to access any page that has the wysiwyg editor enabled.  I'm using a shared SSL through iPowerWeb.

 

The link to the store is http://www.highlandlakestackle.com/catalog

 

The link to the SSL is https://host101.ipowerweb.com/~highland/catalog

 

What am I missing here?

 

I have the same problem, except I am not using a shared SSL...I have my own.

 

Have anyone fixed this or know how to? This is last thing left and it should all be good...

 

Help Please!

Share this post


Link to post
Share on other sites
I have the same problem, except I am not using a shared SSL...I have my own.

 

Have anyone fixed this or know how to? This is last thing left and it should all be good...

 

Help Please!

 

 

Nevermind, I tried one more thing and it worked....

 

For those of you...that also had this problem....

 

Here is the answer, that worked for me....

 

In popups/config.inc.php

 

Make these changes...

// IMAGE_DIR and IMAGE_URL identify the Image directory "root" (MUST end in "/")

// Do NOT include "http://my.hostname.com" in IMAGE_URL; just the path from the

// DocumentRoot of your webserver.

//define("IMAGE_DIR", trim(DIR_FS_CATALOG . DIR_WS_IMAGES));

//define("IMAGE_URL", trim(DIR_WS_CATALOG_IMAGES));

define("IMAGE_DIR", trim("/home/httpd/vhosts/xtremecrawlers.com/httpdocs/catalog/images/"));

define("IMAGE_URL", trim("/catalog/images/"));

 

// NETPBM_DIR identifies the directory where NETPBM is located (MUST end in "/")

// Not used if either CONSTRAIN_HEIGHT or CONSTRAIN_WIDTH (above) is specified as "0".

define("NETPBM_DIR", trim(DIR_FS_CATALOG));

 

// SCRIPT_DIR and SCRIPT_URL identify where these scripts reside (MUST end in "/")

// Do NOT include "http://my.hostname.com" in SCRIPT_URL; just the path from the

// DocumentRoot of your webserver.

//define("SCRIPT_DIR", trim(DIR_FS_ADMIN . "https://secure.xtremecrawlers.com/catalog/admin/htmlarea/popups/"));

//define("SCRIPT_URL", trim(DIR_WS_ADMIN . "htmlarea/popups/"));

define("SCRIPT_DIR", trim(DIR_FS_ADMIN . "/home/httpd/vhosts/xtremecrawlers.com/httpdocs/catalog/admin/htmlarea/popups/"));

define("SCRIPT_URL", trim(DIR_WS_ADMIN . "/htmlarea/popups/"));

 

 

and further towards the bottom...

 

Change:

// return the URL

return ("http://" . $HTTP_SERVER_VARS["HTTP_HOST"] . $url);

}

 

to

 

// return the URL

return ("https://" . $HTTP_SERVER_VARS["HTTP_HOST"] . $url);

}

Share this post


Link to post
Share on other sites
But if i try to rezise images i get a msg

 

"image rezised to X"

 

and 0 k files with the new name are created on the server

 

This is how I solved it:

 

The phrase "image resized to X" is written by the file admin/htmlarea/popups/lister.php. I looked into it and discovered that it constructs a command line, then launches shell to make the conversion. The names of the required programs are listed in admin/htmlarea/popups/config.inc.php:

 

define("NETPBM_BMP", "bmptopnm \"%s\" | pnmscale %s | ppmtobmp >\"%s\"");

define("NETPBM_GIF", "giftopnm \"%s\" | pnmscale %s | ppmtogif >\"%s\"");

define("NETPBM_JPG", "jpegtopnm \"%s\" | pnmscale %s | ppmtojpeg >\"%s\"");

define("NETPBM_PNG", "pngtopnm \"%s\" | pnmscale %s | ppmtopng >\"%s\"");

 

The installed version of NetPBM (9.12) had all these tools except ppmtojpg. But it had pnmtojpeg. A typo? I replaced "ppmtoXXX" with "pnmtoXXX" in the last two lines and the script started to work!

 

By the way, beware of the cached images - if you delete an image using this tool and create it again, with the same name but different dimensions, most browsers will still show the old one - until you make a forced refresh of the page!

 

Hope this helps!

Share this post


Link to post
Share on other sites

Hi,

 

Can someone please advise what advantages UltraPics and HTML Editor + More... , has over say this one:

 

http://www.oscommerce.com/community/contributions,1347

 

... plus a good thumbnail contribution ? It seems contrib. # 1347 , the WYSIWYG HTML editor can be used on almost any file/s.

 

Here are the needs, two different sites.

 

Site #1

 

* Needs a HTML editor to put out newsletters, however the site is "somewhere" between MS-1 and MS-2, plus very heavily loaded with contributions, so we are somewhat limited in what can be installed.

 

Site #2

 

* Needs to be able to use a HTML editor for main page (index.php), product description, category descriptions, plus _possibly_ use it for other pages, shipping, privacy,etc,etc

 

* Needs a good 'thumbnailer' for the main image shown on product_info, plus the thumbnailer needs to work on other 'boxes' (specials, new products, category pages)

 

* Needs to be able to have multiple images shown on any 'product_info' page, the images are properly thumbnailed (not just scaled down), and enlarged on the 'click here' or double-click.

 

Hope that explains it all, thanks,

 

Peter

Share this post


Link to post
Share on other sites

Hi,

 

Doing a small amount of testing with the HTML editor side of this. The interface is nice, I like it, great contribution. :D

 

The html code generated is inserting a lot of "3D"s chars all over the place, which is corrupting the html layout, and also the image does not appear, because the code generated for the image "src" has some garbage in it.

 

I'd like to see one minor improvement for images, have the image 'inline', as an enclosure, rather than a URL reference. This can be done by adding another 'part' to the emails/newsletters, the image file is encoded of course in the email, it has the beginning and ending 'multi-part' parameters, and instead of a URL ref for the image source, you put something like this in the html code:

 

<img src="cid:8258141.1103890011.18796" width="85" height="60" border="0" alt="graphic"/>

 

which is XML compliant also, and then the image 'part' in the email, in addition to having the usual specs for multi-part, just before the encoded image, this is added:

 

Content-ID: <8258141.1103890011.18796>

 

The image source 'id' is obviously 'cid' in the html code. Doing it this way, not using a URL but having the image inline/enclosed also means if the image goes missing on the website, you can still see it, or if not connected (not everyone has broadband), you can still see all the images.

 

Thanks, :)

 

Peter

Share this post


Link to post
Share on other sites
I'd like to see one minor improvement for images, have the image 'inline', as an enclosure, rather than a URL reference. This can be done by adding another 'part' to the emails/newsletters, the image file is encoded of course in the email, it has the beginning and ending 'multi-part' parameters, and instead of a URL ref for the image source, you put something like this in the html code:

 

Peter I've been looking for something to do this for ages, anyone gotm any ideas on how to incorporate this into OScommerce

Share this post


Link to post
Share on other sites

Hi,

 

Peter I've been looking for something to do this for ages, anyone gotm any ideas on how to incorporate this into OScommerce

 

Putting out 'multi-part' is emails is pretty basic stuff, I learnt how to do it by doing test emails, multi-part, then examing the 'structure'.

 

See post #9 here for an example:

 

http://forums.oscommerce.com/index.php?showtopic=126270

 

Peter

Share this post


Link to post
Share on other sites
Hi,

Putting out 'multi-part' is emails is pretty basic stuff, I learnt how to do it by doing test emails, multi-part, then examing the 'structure'.

 

See post #9 here for an example:

 

http://forums.oscommerce.com/index.php?showtopic=126270

 

Peter

 

Hi Peter

 

Sorry I mean the image 'inline'. I have had a look at PHPmailer, and I'm trying to work it out. If someone has some ideas, I am prepared to code and test.

 

Regards

Raj

SimplySpice & Craftmango

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×