Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

New theme contibution


Guest

Recommended Posts

Hi,

Bugs so far

1. Change folder in /includes/theme/black_orange to...orange_black

to match admin settings.

 

2. Error warning: (In orange_black theme)

Warning: Missing argument 2 for contentboxheading() in c:program files....theme2002catalogincludesthemeorange_blacktheme_boxes.php on line 176

 

3. Also error in original selected theme

Warning: Missing argument 2 for contentboxheading() in c:program files.....theme2002catalogincludesthemeoriginaltheme_boxes.php on line 146

 

Apart from that seems to work fine

Link to comment
Share on other sites

kiwimagic

Thanks for pointing that out, not sure if a repost to solve black_orange--to orange_black is worth it yet.

 

The errors below

 

2. Error warning: (In orange_black theme)

Warning: Missing argument 2 for contentboxheading() in c:program files....theme2002catalogincludesthemeorange_blacktheme_boxes.php on line 176

 

3. Also error in original selected theme

Warning: Missing argument 2 for contentboxheading() in c:program files.....theme2002catalogincludesthemeoriginaltheme_boxes.php on line 146

 

I think are caused through missing out the following found in the read me around line 229

 

Now search for the following line

  new contentBoxHeading($info_box_contents);

and relace with:

  new contentBoxHeading($info_box_contents, $newtheme);

This is found in the following files found in includes/modules--

 

also_purchased_products.php

new_products.php

 

Lango

Link to comment
Share on other sites

Hi,

Also some images are failing to display in the box corners in /default.php,

seems to be a coding error in pointing to the images as when I checked the dreaded "red x" left in place of the image....it is pointing to

catalog/includes/theme//infobox/corner_right_left.gif (Note the Double // after theme)......

That's it so far.

Thank you for the fix....I will give that a go!

Link to comment
Share on other sites

kiwimagic

 

Is it only happening in the blue theme?

 

If so open the theme_boxes.php in the blue theme folder and change the following:

 

class contentBoxHeading extends tableBox {

   function contentBoxHeading($contents) {

     $this->table_width = '100%';

     $this->table_cellpadding = '0';



     $info_box_contents = array();

     $info_box_contents[] = array(array('params' => 'height="14" class="infoBoxHeading"', 'text' => tep_image(DIR_WS_IMAGES . 'infobox/corner_left.gif')),

                                  array('params' => 'height="14" class="infoBoxHeading" width="100%"', 'text' => $contents[0]['text']),

                                  array('params' => 'height="14" class="infoBoxHeading"', 'text' => tep_image(DIR_WS_IMAGES . 'infobox/corner_right_left.gif')));

     $this->tableBox($info_box_contents, true);

   }

 }

 

 

with this

 

class contentBoxHeading extends tableBox {

   function contentBoxHeading($contents, $newtheme) {

     $this->table_width = '100%';

     $this->table_class = 'upcomingProducts-odd';

     $this->table_cellpadding = '0';

     $this->heading_class = $newtheme;



     $info_box_contents = array();

     $info_box_contents[] = array(array('params' => 'height="20" class="infoBoxHeading1" ', 'text' => tep_image(DIR_WS_INCLUDES . 'theme/' . $this->heading_class . '/infobox/corner_right_left.gif')),

                                  array('params' => 'background="includes/theme/' . $this->heading_class . '/infobox/background.gif" height="20" class="infoBoxHeading" width="100%"', 'text' => $contents[0]['text']),

                                  array('params' => 'height="20"  class="infoBoxHeading1"', 'text' => tep_image(DIR_WS_INCLUDES . 'theme/' . $this->heading_class . '/infobox/corner_right.gif')));

     $this->tableBox($info_box_contents, true);

   }

 }

 

Your testing and feedback is much appreciated

Link to comment
Share on other sites

Hi,

It is happening in the orange_black theme. On the default page, on the main image table in the center of the page (New Products for December), both the right_left and left corners are not displaying. Right clicking the missing corners indicate for the left image ......theme//infobox/corner_right_left.gif.....it has a double"//" after theme, so I think that is the problem. The right corner of the box also is looking for the image file with a "//" after theme.

Regards

Link to comment
Share on other sites

Line 182-186 in ../includes/theme/orange_black/themeboxes.php....changed the following by inserting "orange_black" before /infobox/corner etc etc in the segment...with the changes now like this:

 

$info_box_contents = array();

$info_box_contents[] = array(array('params' => 'height="20" class="infoBoxHeading1" ', 'text' => tep_image(DIR_WS_INCLUDES . 'theme/' . $this->heading_class . 'orange_black/infobox/corner_right_left.gif')),

array('params' => 'background="includes/theme/' . $this->heading_class . 'orange_black/infobox/background.gif" height="20" class="infoBoxHeading" width="100%"', 'text' => $contents[0]['text']),

array('params' => 'height="20" class="infoBoxHeading1"', 'text' => tep_image(DIR_WS_INCLUDES . 'theme/' . $this->heading_class . 'orange_black/infobox/corner_right.gif')));

$this->tableBox($info_box_contents, true);

 

 

This seems to fix the missing images I mentioned earlier.

Regards

Link to comment
Share on other sites

The only way for that to work is if the variable $newtheme is not getting passed to the

 

function contentBoxHeading($contents, $newtheme)

 

from the following

 

$info_box_contents = array();

 $info_box_contents[] = array('align' => 'left', 'text' => sprintf(TABLE_HEADING_NEW_PRODUCTS, strftime('%B')));

 new contentBoxHeading($info_box_contents, $newtheme);

found in the includes/module/newproducts.php

 

can you either post here or email me with both the theme_boxes file and the modules/new_product.php file?

 

I need to sort this out

 

Cheers

 

Paul

Link to comment
Share on other sites

lango...

 

I'm getting the following error when I attempt to open /catalog/default.php...

1046 - No Database Selected

 

select configuration_key as cfgKey, configuration_value as cfgValue from configuration

 

[TEP STOP]

When I go to my OSC administration and select EDIT from the "Site Thema Options" choice, I get the following error message...

Parse error: parse error, expecting `')'' in /home/virtual/site2/fst/var/www/html/catalog/admin/configuration.php(119) : eval()'d code on line 1

 

Any ideas?

Link to comment
Share on other sites

Also some images are failing to display in the box corners in /default.php,

seems to be a coding error in pointing to the images as when I checked the dreaded "red x" left in place of the image....it is pointing to

catalog/includes/theme//infobox/corner_right_left.gif (Note the Double // after theme)......

That's it so far.

Thank you for the fix....I will give that a go!

 

Problem is about missing modification on column_right.php..

Now clear column_right.php (catalog/includes/column_right.php)

and past these codes

<?php

/*

 $Id: column_right.php,v 1.15 2002/03/13 13:52:20 hpdl Exp $



 osCommerce, Open Source E-Commerce Solutions

 http://www.oscommerce.com



 Copyright (c) 2002 osCommerce



 Released under the GNU General Public License

*/



 require(DIR_WS_THEMES .  $newtheme . '/theme_boxes/shopping_cart.php');



 if ($HTTP_GET_VARS['products_id'])  include(DIR_WS_THEMES .  $newtheme . '/theme_boxes/manufacturer_info.php');



 if (tep_session_is_registered('customer_id')) include(DIR_WS_THEMES .  $newtheme . '/theme_boxes/order_history.php');



 if ($HTTP_GET_VARS['products_id']) {

   if (session_is_registered('customer_id')) {

     $check_query = tep_db_query("select count(*) as count from " . TABLE_CUSTOMERS_INFO . " where customers_info_id = '" . $customer_id . "' and global_product_notifications = '1'");

     $check = tep_db_fetch_array($check_query);

     if ($check['count'] > 0) {

       include(DIR_WS_THEMES .  $newtheme . '/theme_boxes/best_sellers.php');

     } else {

       include(DIR_WS_THEMES .  $newtheme . '/theme_boxes/product_notifications.php');

     }

   } else {

     include(DIR_WS_THEMES .  $newtheme . '/theme_boxes/product_notifications.php');

   }

 } else {

   include(DIR_WS_THEMES .  $newtheme . '/theme_boxes/best_sellers.php');

 }



 if ($HTTP_GET_VARS['products_id']) {

   if (basename($PHP_SELF) != FILENAME_TELL_A_FRIEND) include(DIR_WS_THEMES .  $newtheme . '/theme_boxes/tell_a_friend.php');

 } else {

   include(DIR_WS_THEMES .  $newtheme . '/theme_boxes/specials.php');

 }



 require(DIR_WS_THEMES .  $newtheme . '/theme_boxes/reviews.php');



 if (substr(basename($PHP_SELF), 0, 8) != 'checkout') {

   include(DIR_WS_THEMES .  $newtheme . '/theme_boxes/languages.php');

   include(DIR_WS_THEMES .  $newtheme . '/theme_boxes/currencies.php');

 }

?>

 

Thats all.

Link to comment
Share on other sites

lango...

 

I'm getting the following error when I attempt to open /catalog/default.php...

1046 - No Database Selected

 

select configuration_key as cfgKey' date=' configuration_value as cfgValue from configuration

 

[TEP STOP']

Did you execute this line to your shop database

INSERT INTO configuration VALUES("122", "Site Theme Options", "STORE_THEME", "DW_Virtual_Black", "You can change site thema form here.", "1", "19", "2002-12-21 23:24:00", "0000-00-00 00:00:00", "tep_get_theme_name", "tep_cfg_select_option(array('WhatsNew', 'original', 'blue', ' black_orange'),");

Link to comment
Share on other sites

MultiServis.Net wrote:

 

Problem is about missing modification on column_right.php..

Now clear column_right.php (catalog/includes/column_right.php)

and past these codes

 

The problem kiwimagic was experiencing was as I said He had not updated the contentBoxheading in new_products.php and also_purchased_products.php. after he had see reply below.

 

Hi,

I made the changes as you suggested and it is now correct. The images are now being displayed properly. The blue theme and the whatsnew themes were not included with the package. Was that intended or did you not submit those themes on purpose.

This is a really good contribution.

Best Regards

David

 

And reply was

The reason for posting the other theme seperatly is you can only upload a file up to 300k in one go, hence the two files.

 

I think this might become an issue if anybody else trys it.

 

I'm sure if the readme is followed correctly there should be no problem.

 

Have you tried it MultiServis.Net if so what do you think?

 

Lango

Link to comment
Share on other sites

Lango...

 

Yes, I did input the values into the database. Would you mind showing me how the very last value is supposed to appear in the set_function field. I'm not sure if I'm getting it in there correctly.

 

This is the statement I'm not sure of...

"tep_cfg_select_option(array('WhatsNew', 'original', 'blue', ' orange_black'),");

 

In the statement bove, when I use the backslashes within the "array" as directed, I get an error message in Admin that says...

Warning: Unexpected character in input: '' (ASCII=92) state=1 in /home/virtual/site2/fst/var/www/html/catalog/admin/configuration.php(119) : eval()'d code on line 1

 

Parse error: parse error, expecting `')'' in /home/virtual/site2/fst/var/www/html/catalog/admin/configuration.php(119) : eval()'d code on line 1

 

Thanks in advance

Link to comment
Share on other sites

ugottasalsa

 

It seems I dropped a !*"?"!

 

I use mysqlfront to manage my local database and the export dosnt work for some :oops:

 

Please try the code below

 

 

INSERT INTO configuration VALUES (122, 'Site Theme Options', 'STORE_THEME', 'original', 'You can change site thema form here.', 1, 19, '2002-12-22 05:34:14', '0000-00-00 00:00:00', 'tep_get_theme_name', 'tep_cfg_select_option(array('WhatsNew', 'original', 'blue', ' orange_black'),');

 

Lango

Link to comment
Share on other sites

may i make a suggestion here

 

i mean lots of people like after a week or so will get in the forums and ask the same things again.

 

make a new recompilation of your archive with all the feedback you got here so there wont be such problems,cause from what it seems it looks like an excellent contribution

Link to comment
Share on other sites

IT WORKS!!!

 

Originally, I had manually added the MySQL configuration info you outlined through phpMyAdmin. That's why I was wondering about the syntax. I removed the row I had created in the database and this time, I did it from the MySQL command line using the code you gave me. It worked like a charm!

 

Thank you so much for your assistance! You da man!

 

-R

Link to comment
Share on other sites

MultiServis.Net wrote:

 

I'm sure if the readme is followed correctly there should be no problem.

 

Have you tried it MultiServis.Net if so what do you think?

 

Lango

I am sory that I just follow the readME.txt and it isn't say me that I need to modify column_right.php except

eg if you are to add Linda McGrath's loginbox.php add it to your theme/theme_boxes folder

and you would add the following line to your includes/column_left/column_right file.

Then I take some errors about missing

catalog/includes/theme//infobox/corner_right_left.gif error...

So I understood that something missing :!:

And I looked the theme contribution files and I saw includes/column_right.php .Then I copy this file to my old column_right.php.

then it started to work.Problems is Paul Langford didn't say you need to modifiy includes/column_right.php .

Thank you.

Link to comment
Share on other sites

And a small fix about

INSERT INTO configuration VALUES("122", "Site Theme Options", "STORE_THEME", "DW_Virtual_Black", "You can change site thema form here.", "1", "19", "2002-12-21 23:24:00", "0000-00-00 00:00:00", "tep_get_theme_name", "tep_cfg_select_option(array('WhatsNew', 'original', 'blue', ' orange_black'),");

 

You need to change orange_black

 

INSERT INTO configuration VALUES("122", "Site Theme Options", "STORE_THEME", "DW_Virtual_Black", "You can change site thema form here.", "1", "19", "2002-12-21 23:24:00", "0000-00-00 00:00:00", "tep_get_theme_name", "tep_cfg_select_option(array('WhatsNew', 'original', 'blue', ' '),");

Link to comment
Share on other sites

I've never met anyone on this forum and most I would never want to.

So many negative people :!:

 

This will be my first and last contribution to this forum.

 

People just don't want to help themselves they need and expect everything done for them :x :x

 

Yes there are a few mistakes in the instructions but mostly errors occure through either not following the readMe or just typing mistakes.

 

For all interested for a short time a full set of instructions (and yes I have tested them four times on clean snapshots) and they work!!!!

 

Files to download are also there..

 

www.dcpcwebdevelopment.co.uk/instructions/

AND no advertising here just in case thats what you think

 

:cry: Signing off :cry:

Link to comment
Share on other sites

lango,

 

First of all I can say that I am sad to hear you say that you never want to meet anyone on this forum. There are MANY, MANY members, and many are willing to help themselves. I am sorry to see that you have fallen into a group of "negative" people. We are not all that way.

 

Second, I just wanted to say thanks for taking the time to write out the code to make this work, and then contribute it to us all so that we may use it. IT IS APPRECIATED!

 

-Chris

Chris Sullivan

Link to comment
Share on other sites

I am also sorry to hear of this.

 

There are good people out there. Sometimes its a few bad apples that screw it up for the rest. Within a "community", there will always be a few.

 

I know I'm new to this community, as well as to development in general (I'm a Network Engineer), but I'm eager and learning as I go. I hope I haven't fueled your decision in any way.

 

You have been VERY helpful and insightful with getting me to where I am. Your contribution is great and has created an easy way for me to handle changes to my site's Thema with a simple click.

 

For this, I thank you. Have a Safe and Peaceful Holiday!

 

-R

Link to comment
Share on other sites

if you are referring to my post as a negative one.... i was just making a suggestion to you so you would save lots of time

 

1) from your personal. you wont get spammed with thousands of emails by people asking why this and who that

 

2) minimize the possibilities of people reposting in the forum.

 

 

the only reason i made the post cause i was thinking on how good is the contribution and because it will definetely be used by many people

 

thats my 2 cents

 

it wasnt meant to be offensive :(

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...