Jump to content



Latest News: (loading..)

- - - - -

[Addon] Generic Box


  • Please log in to reply
203 replies to this topic

#41   kymation

kymation

    Believers

  • Community Sponsor
  • 6,697 posts
  • Real Name:Jim Keebaugh
  • Gender:Male
  • Location:Aberdeen WA USA

Posted 01 March 2011 - 09:44 PM

You might be able to fix it by uninstalling the module and reinstalling. If that doesn't work, you'll have to edit the database directly. Search your Configuration table for MODULE_BOXES_GENERIC_CONTENT_ENGLISH and delete that row. You should then be able to uninstall.

Regards
Jim
My Addons

Banners Box 2.3.x  Support
Categories Accordion Box 2.3.x  Support
Categories Images Box 2.2x  2.3.x  Support
Closest Shipper 2.2x  Support
Document Manager 2.2x  Support
Generic Box 2.3.x  Support
Get 1 Free 2.2x  Support
jQuery Banner Rotator 2.2x  2.3.x  Support
Modular Front Page 2.3.x  Support
Modular SEO Header Tags 2.3.x  Support
MVS 2.2x  Support
PDF Datasheet 2.3.x  Support
Price Updater 2.2x
Products Specifications 2.2x  2.3.x  Development Version  Support  Bugs/Suggestions
Request a Review 2.2x - 2.3.x  Support
Similar Products Box 2.2x
Specials Image Overlay 2.3x Support
Theme Switcher 2.3.x  Support

#42   warrenerjm

warrenerjm
  • Members
  • 1,144 posts
  • Real Name:Julie
  • Gender:Female
  • Location:UK

Posted 01 March 2011 - 09:53 PM

OK I have un-installed & changed all ' to \' then re-installed & added new code. It shows on the admin side but not on the catalog side.

As it worked on the catalog side & shows on the admin side I'm guessing I'll have to make the colour & size adjustments but leave the ' as original. The error message doesn't seem to stop it from working, unless you have another work around java script?

All it means is that I cannot edit the code. I have to un-install & re-install. Will this make any difference?
I'm hoping un-installing & re-installing many times won't have an adverse affect?

#43   kymation

kymation

    Believers

  • Community Sponsor
  • 6,697 posts
  • Real Name:Jim Keebaugh
  • Gender:Male
  • Location:Aberdeen WA USA

Posted 01 March 2011 - 10:08 PM

Yes, I forgot something. You need to make a change to includes/modules/boxes/bm_generic.php. find Line 77:

		$module_contents .= $content . PHP_EOL;
and change it to:

		$module_contents .= stripslashes($content) . PHP_EOL;
The box should now work correctly in both the Admin and Catalog.

Regards
Jim
My Addons

Banners Box 2.3.x  Support
Categories Accordion Box 2.3.x  Support
Categories Images Box 2.2x  2.3.x  Support
Closest Shipper 2.2x  Support
Document Manager 2.2x  Support
Generic Box 2.3.x  Support
Get 1 Free 2.2x  Support
jQuery Banner Rotator 2.2x  2.3.x  Support
Modular Front Page 2.3.x  Support
Modular SEO Header Tags 2.3.x  Support
MVS 2.2x  Support
PDF Datasheet 2.3.x  Support
Price Updater 2.2x
Products Specifications 2.2x  2.3.x  Development Version  Support  Bugs/Suggestions
Request a Review 2.2x - 2.3.x  Support
Similar Products Box 2.2x
Specials Image Overlay 2.3x Support
Theme Switcher 2.3.x  Support

#44   warrenerjm

warrenerjm
  • Members
  • 1,144 posts
  • Real Name:Julie
  • Gender:Female
  • Location:UK

Posted 01 March 2011 - 10:17 PM

I have changed all the ' for a " & it shows both admin & catalog without an error message.

Not sure if this is a default with the generic box, but you only seem to be able to add code to the contents once?
After that you do not get the option of the code in the white input box?

I'll leave it at that for the moment, until you say any different.

Thanks once again.

#45   warrenerjm

warrenerjm
  • Members
  • 1,144 posts
  • Real Name:Julie
  • Gender:Female
  • Location:UK

Posted 01 March 2011 - 10:19 PM

View Postkymation, on 01 March 2011 - 10:08 PM, said:

Yes, I forgot something. You need to make a change to includes/modules/boxes/bm_generic.php. find Line 77:

		$module_contents .= $content . PHP_EOL;
and change it to:

		$module_contents .= stripslashes($content) . PHP_EOL;
The box should now work correctly in both the Admin and Catalog.

Regards
Jim
Cross posts. Do I still need to do this as I have changed all ' to " & it works both admin & catalog side?

#46   kymation

kymation

    Believers

  • Community Sponsor
  • 6,697 posts
  • Real Name:Jim Keebaugh
  • Gender:Male
  • Location:Aberdeen WA USA

Posted 01 March 2011 - 10:27 PM

No, that was only to account for the escaped single quotes.

I think you've found a bug. I have no idea what is doing that, but I'll find out and fix it. Thanks for letting me know.

Regards
Jim
My Addons

Banners Box 2.3.x  Support
Categories Accordion Box 2.3.x  Support
Categories Images Box 2.2x  2.3.x  Support
Closest Shipper 2.2x  Support
Document Manager 2.2x  Support
Generic Box 2.3.x  Support
Get 1 Free 2.2x  Support
jQuery Banner Rotator 2.2x  2.3.x  Support
Modular Front Page 2.3.x  Support
Modular SEO Header Tags 2.3.x  Support
MVS 2.2x  Support
PDF Datasheet 2.3.x  Support
Price Updater 2.2x
Products Specifications 2.2x  2.3.x  Development Version  Support  Bugs/Suggestions
Request a Review 2.2x - 2.3.x  Support
Similar Products Box 2.2x
Specials Image Overlay 2.3x Support
Theme Switcher 2.3.x  Support

#47   warrenerjm

warrenerjm
  • Members
  • 1,144 posts
  • Real Name:Julie
  • Gender:Female
  • Location:UK

Posted 01 March 2011 - 10:28 PM

View Postkymation, on 01 March 2011 - 10:27 PM, said:

No, that was only to account for the escaped single quotes.

I think you've found a bug. I have no idea what is doing that, but I'll find out and fix it. Thanks for letting me know.

Regards
Jim
ohhhh my first bug :) sorry

#48   Mastermind2008

Mastermind2008
  • Members
  • 9 posts
  • Real Name:Enoch Wright

Posted 02 March 2011 - 02:25 PM

This box works, thanks!

But can you tell me how to make it not appear on product pages, like the best sellers box... display on every page but product pages.

Thanks,
Mastermind2008

#49   kymation

kymation

    Believers

  • Community Sponsor
  • 6,697 posts
  • Real Name:Jim Keebaugh
  • Gender:Male
  • Location:Aberdeen WA USA

Posted 02 March 2011 - 06:54 PM

The Best Sellers box appears on subcategory pages, manufacturer pages, and review pages. Is this what you want?

Regrds
Jim

Edited by kymation, 02 March 2011 - 06:54 PM.

My Addons

Banners Box 2.3.x  Support
Categories Accordion Box 2.3.x  Support
Categories Images Box 2.2x  2.3.x  Support
Closest Shipper 2.2x  Support
Document Manager 2.2x  Support
Generic Box 2.3.x  Support
Get 1 Free 2.2x  Support
jQuery Banner Rotator 2.2x  2.3.x  Support
Modular Front Page 2.3.x  Support
Modular SEO Header Tags 2.3.x  Support
MVS 2.2x  Support
PDF Datasheet 2.3.x  Support
Price Updater 2.2x
Products Specifications 2.2x  2.3.x  Development Version  Support  Bugs/Suggestions
Request a Review 2.2x - 2.3.x  Support
Similar Products Box 2.2x
Specials Image Overlay 2.3x Support
Theme Switcher 2.3.x  Support

#50   Mastermind2008

Mastermind2008
  • Members
  • 9 posts
  • Real Name:Enoch Wright

Posted 02 March 2011 - 06:59 PM

Yea, except not on review pages. The only pages (i can think of) that I don't want it on is product page and review page. Is there a place to define this or something?

Thanks.

#51   kymation

kymation

    Believers

  • Community Sponsor
  • 6,697 posts
  • Real Name:Jim Keebaugh
  • Gender:Male
  • Location:Aberdeen WA USA

Posted 02 March 2011 - 07:22 PM

You need to modify the code to restrict the box. In includes/modules/boxes/bm_generic.php, find this code:

	  if (tep_not_null($content)) {
and replace it with:

	  if (tep_not_null($content) && !isset($HTTP_GET_VARS['products_id'])) {
That should keep it from showing on any product or review page.

Regards
Jim
My Addons

Banners Box 2.3.x  Support
Categories Accordion Box 2.3.x  Support
Categories Images Box 2.2x  2.3.x  Support
Closest Shipper 2.2x  Support
Document Manager 2.2x  Support
Generic Box 2.3.x  Support
Get 1 Free 2.2x  Support
jQuery Banner Rotator 2.2x  2.3.x  Support
Modular Front Page 2.3.x  Support
Modular SEO Header Tags 2.3.x  Support
MVS 2.2x  Support
PDF Datasheet 2.3.x  Support
Price Updater 2.2x
Products Specifications 2.2x  2.3.x  Development Version  Support  Bugs/Suggestions
Request a Review 2.2x - 2.3.x  Support
Similar Products Box 2.2x
Specials Image Overlay 2.3x Support
Theme Switcher 2.3.x  Support

#52   Mastermind2008

Mastermind2008
  • Members
  • 9 posts
  • Real Name:Enoch Wright

Posted 02 March 2011 - 07:27 PM

That doesn't work. And only on the first categories page does my top sellers work, how can i make it show on other category pages?

Thanks so much!

Edited by Mastermind2008, 02 March 2011 - 07:30 PM.


#53   kymation

kymation

    Believers

  • Community Sponsor
  • 6,697 posts
  • Real Name:Jim Keebaugh
  • Gender:Male
  • Location:Aberdeen WA USA

Posted 02 March 2011 - 07:43 PM

Try replacing $HTTP_GET_VARS with $_GET in that line.

Regards
Jim
My Addons

Banners Box 2.3.x  Support
Categories Accordion Box 2.3.x  Support
Categories Images Box 2.2x  2.3.x  Support
Closest Shipper 2.2x  Support
Document Manager 2.2x  Support
Generic Box 2.3.x  Support
Get 1 Free 2.2x  Support
jQuery Banner Rotator 2.2x  2.3.x  Support
Modular Front Page 2.3.x  Support
Modular SEO Header Tags 2.3.x  Support
MVS 2.2x  Support
PDF Datasheet 2.3.x  Support
Price Updater 2.2x
Products Specifications 2.2x  2.3.x  Development Version  Support  Bugs/Suggestions
Request a Review 2.2x - 2.3.x  Support
Similar Products Box 2.2x
Specials Image Overlay 2.3x Support
Theme Switcher 2.3.x  Support

#54   Mastermind2008

Mastermind2008
  • Members
  • 9 posts
  • Real Name:Enoch Wright

Posted 02 March 2011 - 07:49 PM

View Postkymation, on 02 March 2011 - 07:43 PM, said:

Try replacing $HTTP_GET_VARS with $_GET in that line.

Regards
Jim
That works! Thanks so much. Now can you tell me how to make best sellers show on all category pages and not just the first one? OR Just make it work on all pages.


Thanks!

Edited by Mastermind2008, 02 March 2011 - 07:59 PM.


#55   thered

thered
  • Members
  • 18 posts
  • Real Name:russ

Posted 06 March 2011 - 12:18 PM

To follow up on my previous postings.

Worked ok on development server, now running live, installed without issue.

Great addon. Thanks Jim.


Russ

#56   DWPOSC

DWPOSC
  • Members
  • 8 posts
  • Real Name:Dave Plasket

Posted 10 March 2011 - 05:37 PM

I have a simple question, Not knowing what I am doing
How do I code for a image in the
English Contents
Enter the contents that you want in your box in English.

Also
I tried a couple of things one that resulted in php errors ect
If this happens just uninstall and reinstall in the admin panel
Thanks for the help
Dave

#57   kymation

kymation

    Believers

  • Community Sponsor
  • 6,697 posts
  • Real Name:Jim Keebaugh
  • Gender:Male
  • Location:Aberdeen WA USA

Posted 10 March 2011 - 05:51 PM

Use HTML.

Regards
Jim
My Addons

Banners Box 2.3.x  Support
Categories Accordion Box 2.3.x  Support
Categories Images Box 2.2x  2.3.x  Support
Closest Shipper 2.2x  Support
Document Manager 2.2x  Support
Generic Box 2.3.x  Support
Get 1 Free 2.2x  Support
jQuery Banner Rotator 2.2x  2.3.x  Support
Modular Front Page 2.3.x  Support
Modular SEO Header Tags 2.3.x  Support
MVS 2.2x  Support
PDF Datasheet 2.3.x  Support
Price Updater 2.2x
Products Specifications 2.2x  2.3.x  Development Version  Support  Bugs/Suggestions
Request a Review 2.2x - 2.3.x  Support
Similar Products Box 2.2x
Specials Image Overlay 2.3x Support
Theme Switcher 2.3.x  Support

#58   warrenerjm

warrenerjm
  • Members
  • 1,144 posts
  • Real Name:Julie
  • Gender:Female
  • Location:UK

Posted 10 March 2011 - 08:12 PM

View Postkymation, on 02 March 2011 - 07:22 PM, said:

You need to modify the code to restrict the box. In includes/modules/boxes/bm_generic.php, find this code:

	  if (tep_not_null($content)) {
and replace it with:

	  if (tep_not_null($content) && !isset($HTTP_GET_VARS['products_id'])) {
That should keep it from showing on any product or review page.

Regards
Jim

Hi Jim

Slightly off topic, but will this code change work to stop the New Products box from appearing on the product_info page too please?

:D

#59   kymation

kymation

    Believers

  • Community Sponsor
  • 6,697 posts
  • Real Name:Jim Keebaugh
  • Gender:Male
  • Location:Aberdeen WA USA

Posted 10 March 2011 - 09:26 PM

That code will block the module from appearing anyplace that the Product ID is present: Product Info and Reviews pages.

Regards
Jim
My Addons

Banners Box 2.3.x  Support
Categories Accordion Box 2.3.x  Support
Categories Images Box 2.2x  2.3.x  Support
Closest Shipper 2.2x  Support
Document Manager 2.2x  Support
Generic Box 2.3.x  Support
Get 1 Free 2.2x  Support
jQuery Banner Rotator 2.2x  2.3.x  Support
Modular Front Page 2.3.x  Support
Modular SEO Header Tags 2.3.x  Support
MVS 2.2x  Support
PDF Datasheet 2.3.x  Support
Price Updater 2.2x
Products Specifications 2.2x  2.3.x  Development Version  Support  Bugs/Suggestions
Request a Review 2.2x - 2.3.x  Support
Similar Products Box 2.2x
Specials Image Overlay 2.3x Support
Theme Switcher 2.3.x  Support

#60   warrenerjm

warrenerjm
  • Members
  • 1,144 posts
  • Real Name:Julie
  • Gender:Female
  • Location:UK

Posted 10 March 2011 - 09:59 PM

View Postkymation, on 10 March 2011 - 09:26 PM, said:

That code will block the module from appearing anyplace that the Product ID is present: Product Info and Reviews pages.

Regards
Jim
Thanks that is interesting to know, but just realised there isn't a bm_products_new.php  :rolleyes:

Edited by warrenerjm, 10 March 2011 - 10:02 PM.