Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

[Addon} Modular Front Page


kymation

Recommended Posts

in the download ive got there is no includes/functions/modules.

 

there is admin/includes/functions/modules/front_page/featured.php

 

here is what ive got - www.southportwebdesign.org/modular_front_page_1.2.6.tar.gz

Link to comment
Share on other sites

That's correct, that file is used only on the Admin side. If your store is looking for it on the catalog side, you have something wrong with your osCommerce code, probably one or more incorrect entries in your configure.php. Try this guide to figure out what is wrong.

 

Regards

Jim

See my profile for a list of my addons and ways to get support.

Link to comment
Share on other sites

Your installation is clearly looking for the file in the wrong place. You could try putting a copy of the file in the catalog-side directory to get it to shut up. However, if this is really a problem with the configuration, you are going to have a lot more problems than just this.

 

Regards

Jim

See my profile for a list of my addons and ways to get support.

Link to comment
Share on other sites

Resize category images?

 

I have a really frustrating problem. I want to be able to display bigger images in the category images module.

The manual says in Appendix A.2 that I can change this in catalog/ext/modules/categories_images/stylesheet.css. I did this, doubling the imagebox width and height settings on lines 15 and 16.... no impact.... still tiny images.

So I had a look at the actual index.php file and changed the SUBCATEGORY_IMAGE_WIDTH, SUBCATEGORY_IMAGE_HEIGHT to hard coded values (as I couldn't work out where the parameter value are picked up from.... no impact again.

I had a look at the page source after loading it in Firefox and can see the image sizes are width="100" height="80". They're ALWAYS 100x80 no matter what I do to change them in the stylesheet or the html!!

So what am I missing here? Where are these sizes likely to be defined and how do I change them?

 

Thanks in advance

 

Jackie

Link to comment
Share on other sites

Answered my own question... party anyway. The 100x80 comes from the small image width and height setting in the basic osCommerce configuration panel. So now I've got nice big images. But what's the meaning then of the values in catalog/ext/modules/categories_images/stylesheet.css, as they seem to have no effect on the displayed image size?

Link to comment
Share on other sites

The stylesheet controls the size of the category box, of which the image is a part. Setting that box smaller than the image may cause some strange effects.

 

Regards

Jim

See my profile for a list of my addons and ways to get support.

Link to comment
Share on other sites

Okay. Think I've got it now. The stylesheet effectively defines the maximum size of the image as it defines the size of the container. But you also have to set the small image width and height via the config panel, otherwise you just end up with a tiny image in a big box, which I guess is what was happening.

 

Still don't know why hardcoding the values into index.php didn't work. But hey-ho, that's not good practice anyway so I'll let it drop.

 

Jackie

Link to comment
Share on other sites

Hopefully this will just be a quicky!

 

the scroller is a couple pixels to wide to look right when i put a background & border to the ContentContainter

 

what is the easiest way to make these the same width? change the width of the contentContainer somehow or is the scroller able to have its width change, if so where would i find the values controlling the width of the scroller.

 

Open to suggestions if theres a better way to solve this problem, so you can see what i mean the test site is www.hughes-meats.com/2011

Link to comment
Share on other sites

Hey i was editing the "main text" box and after i saved it stopped allowing me to edit the text anymore, it keeps throwing me this error

 

Parse error: syntax error, unexpected T_STRING in /home/hugh3781/public_html/admin/modules.php(232) : eval()'d code on line 4

 

the only things i did differently whilst editing the text before was add a bold tag and a h2 tag and probably a few br tags, i've attached two screenshots if they help

 

thanks in advance

post-296932-0-42102100-1315961346_thumb.png

post-296932-0-66436200-1315961360_thumb.png

Link to comment
Share on other sites

This happens if you use a single quote/apostrophe without escaping it. Edit your database configuration table and place a backslash \ in front of every single quote. Or just delete the entry and edit it again in the admin. The entry should be near the end of the table.

 

Regards

Jim

See my profile for a list of my addons and ways to get support.

Link to comment
Share on other sites

Hi jim thanks for your reply,

 

im having trouble finding the db configuration table your talking about? do you mean go into the db through phpmyadmin and change the values there? because if thats the case i think i've located the configuration table but i can't see anything relating to the front page main text?

 

Thanks again

 

 

EDIT : ok that was me being a major n00b, i found where i was going wrong, thank you for your more then adequate explaination!

Edited by CarlDavidRobinson
Link to comment
Share on other sites

Yes, that's correct. The data will be in the configuration_value field, next to a configuration_key of MODULE_FRONT_PAGE_TEXT_MAIN_ENGLISH (Unless you are using a different language). You can use the Search tab and paste that key in to find it.

 

Regards

Jim

See my profile for a list of my addons and ways to get support.

Link to comment
Share on other sites

You can get the manufacturers_id from the products table. The SQL that is already in the modules is retrieving data from that table, so it's just a matter of adding to the list of fields that it is retrieving. Then you can use that value to retrieve the manufacturers_name from the manufacturers table. Or you could use a left join to join the tables and get the name in one step.

 

Regards

Jim

See my profile for a list of my addons and ways to get support.

Link to comment
Share on other sites

Sorry, I must admit that I am limited in my PHP usage. Jim, I believe I've been on track towards the later. I know that the changes need to be made to the php files under catalog/includes/modules/front_page/ (anywhere else?). Currently I'm testing featured.php, and tried modifying the following....

 

 

featured.php, around line 98:

-------------------------------------

$featured__content .= '<a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $featured_products['products_id']) . '">' . tep_image(DIR_WS_IMAGES . $featured_products['products_image'], $featured_products['products_name'], SMALL_IMAGE_WIDTH, SMALL_IMAGE_HEIGHT) . '</a><br /><a href="' . tep_href_link(FILENAME_PRODUCT_INFO, 'products_id=' . $featured_products['products_id']) . '">' . $featured_products['products_name'] . '</a><br />' . $featured_products['manufacturers_name'] . '</a><br />' . $manufacturers_name . '</a><br />' .$products_price;

----------------------------

 

 

So, of course those calls to manufacturers_name I tried didn't work, <br />'s worked like a charm though, so I have been eyeballing above lines...

 

featured.php, around line 60

------------------------------------

select

p.products_id,

pd.products_name,

p.products_price,

p.products_tax_class_id,

p.products_image,

s.specials_new_products_price,

s.status

from

" . TABLE_PRODUCTS . " p

join " . TABLE_PRODUCTS_DESCRIPTION . " pd

on pd.products_id = p.products_id

left join " . TABLE_SPECIALS . " s

on s.products_id = p.products_id

where

p.products_id = '" . $products_id . "'

and pd.language_id = '" . ( int ) $languages_id . "'

";

----------------------------------------

 

From what you posted, Jim, looks like I'm headed in the right direction. So to pull of the left join, do I just have to add 'm.manufacturers_name' under 'select' and then add the following...

 

left join " . TABLE_MANUFACTURERS . " m

on m.products_id = p.products_id

 

...under 'from'? Then I can make the call for manufacturers_name?

 

 

Update: Nope, tried, returns the following on storefront:

--------------------------------------------------

1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '.manufacturers_name from pro' at line 9

 

select p.products_id, pd.products_name, p.products_price, p.products_tax_class_id, p.products_image, s.specials_new_products_price, s.status m.manufacturers_name from products p join products_description pd on pd.products_id = p.products_id left join specials s on s.products_id = p.products_id left join manufacturers m on m.products_id = p.products_id where p.products_id = '5' and pd.language_id = '1'

 

[TEP STOP]

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...