Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

[Addon} Modular Front Page


kymation

Recommended Posts

You did it right, but I gave you the wrong instructions. Sorry. Take out that extra line and put it down further. You want to change these lines:

 

         } // switch

         $categories_content .= '  </div>' . "\n";
         $categories_content .= '<!-- Categories Images EOF -->' . "\n";

to this:

 

         } // switch

         $categories_content .= '  </div>' . "\n";
         $categories_content .= '<div class="clear"></div>' . "\n";
         $categories_content .= '<!-- Categories Images EOF -->' . "\n";

Regards

Jim

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

Link to comment
Share on other sites

In includes/modules/front_page/featured.php, you should have the following code starting at Line 37:

 

     // Include the function that is used to add products in the Admin
     if ($PHP_SELF == 'modules.php') {
       include_once (DIR_WS_FUNCTIONS . 'modules/front_page/featured.php');
     }

If yours doesn't match, try the latest version of that file.

 

Regards

Jim

I have this:

     if( defined( 'MODULE_FRONT_PAGE_FEATURED_STATUS' ) ) {
       $this->sort_order = MODULE_FRONT_PAGE_FEATURED_SORT_ORDER;
       $this->enabled = ( MODULE_FRONT_PAGE_FEATURED_STATUS == 'True' );
     }

     include_once( DIR_WS_FUNCTIONS . 'modules/front_page/featured.php');
   }

 

Do I just go to the Add-Ons and upload the latest?

 

Do I need to change more than this file alone?

 

Thanks

Web Developer, Firebug, and Notepad++ are powerful free tools for web design.

Link to comment
Share on other sites

Version 1.2 has been uploaded to the Addons section. This includes a new module: a horizontal/side scroller. This box can be used as a specials, new products, or featured products module. It shows images of your products scrolling across the page. The most common options are provided as Admin settings.

 

This makes a total of 10 modules currently available. Anybody who wants to can add their own favorite front page addon as a module. If you need help figuring out the code, just ask. Please let us know hare if you upload a new module.

 

Regards

Jim

can I use this to get scrolling images of categories, linked to the categories on my front page? Thanks loads, Lotti

Link to comment
Share on other sites

Is this add-on known to have any confliction with other add-ons (such as the dynamic template system) because I have installed the add-on but it does not display on my home page how it should as can be seen here: www.ascafo.com/shop ?

 

Is it possible I have missed a piece of code from index.php or something?

Link to comment
Share on other sites

The Dynamic Template System may very well conflict with this code. Most templates conflict with most other addons. It's the nature of templates.

 

Regards

Jim

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

Link to comment
Share on other sites

The Dynamic Template System may very well conflict with this code. Most templates conflict with most other addons. It's the nature of templates.

 

Regards

Jim

The dynamic template system does not conflict with modular front page. I have both installed and it works fine

Link to comment
Share on other sites

Hi Jim

 

I went for it & uploaded your Modular Front Page thanks & it does what it say on the tin. :thumbsup:

 

You mentioned that the size of the banner rotator could be changed. Can you tell me where please as it isn't quite to the edge of my main column grid_18 (only have left column)Will this mean the banners need to be bigger or will it just have white space or will the size of the banner area be dependant upon the size of the banners I put into it? i.e. It would fit to the size of that group?

 

I'm wondering if there are any different options for the sequence buttons? I like the ones like burt's which has a 1 2 3 buttons & how can I change the black to match my sites colour scheme please? I can ask this in a new thread if necessary. Also where can I change the css so I can have a border?

 

One last thing :) Is it possible to create new modules? I will be setting up my gallery again & would love a module simlar to the products one that dispayed randon images from the gallery images. Is this possible please?

 

If yes to any of my questions please direct me in the right direction. :D

 

Thanks for this it works great & is easy to install. So far I haven't found any problems. :)

 

Julie

Link to comment
Share on other sites

To change the banner sizes, you need to size the banner images accordingly, then make a couple of changes in the CSS to match your image sizes. I'm using images that are 790 pixels wide on a store with no right column. The CSS properties that you need to change are marked in catalog/ext/modules/front_page/banner_rotator/stylesheet.css. You can make other changes to this file to add your border where you want it.

 

The images for the controls are in catalog/images/icons. Change them to whatever you want. I haven't thought about numbering the banner buttons. I suppose that it could be done, but you will have to change the Javascript in catalog/ext/modules/front_page/banner_rotator/bannerRotator.js to use a different class for each button, or something similar.

 

You can certainly create new modules if you want. That's the advantage of a modular system like this. I would start with one of the simpler modules, such as heading_title.php, and change the name and the constants. The part that produces the output on the front page is the execute() method. Play with it a bit and you should be able to figure out how everything works. Ask questions if you can't figure it out by yourself. Please share your module when you have it ready.

 

Regards

Jim

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

Link to comment
Share on other sites

To change the banner sizes, you need to size the banner images accordingly, then make a couple of changes in the CSS to match your image sizes. I'm using images that are 790 pixels wide on a store with no right column. The CSS properties that you need to change are marked in catalog/ext/modules/front_page/banner_rotator/stylesheet.css. You can make other changes to this file to add your border where you want it.

 

Thanks

 

The images for the controls are in catalog/images/icons. Change them to whatever you want. I haven't thought about numbering the banner buttons. I suppose that it could be done, but you will have to change the Javascript in catalog/ext/modules/front_page/banner_rotator/bannerRotator.js to use a different class for each button, or something similar.stared

 

OK this has totally lost me! I started learning about osc & tables & now I'm learning more about 960 grid & css. Javascript looks like greek to me when I have had a peek. I may have to leave this one for a while but do I have to create the same images but change the colour of the existing controls & not through css?

 

You can certainly create new modules if you want. That's the advantage of a modular system like this. I would start with one of the simpler modules, such as heading_title.php, and change the name and the constants. The part that produces the output on the front page is the execute() method. Play with it a bit and you should be able to figure out how everything works. Ask questions if you can't figure it out by yourself. Please share your module when you have it ready.

 

Regards

Jim

 

I'll have a go at this. Hopefully it is similar to the add a new page in 2.2? Could the featured products module be used if fixed images were used? If random ones from the whole galleries images, could the new products module be amended so it looked in there instead of the products? Probably a very naive way of thinking how it works! :-"

 

If I managed to do this (with help probably/hopefully) I'll definately share. I think the ability to add various modules would be great for your contribution.

 

Thanks

Link to comment
Share on other sites

OK this has totally lost me! I started learning about osc & tables & now I'm learning more about 960 grid & css. Javascript looks like greek to me when I have had a peek. I may have to leave this one for a while but do I have to create the same images but change the colour of the existing controls & not through css?

Yes, you replace the images with your own. You can change the color and shape to whatever you want. You will need to change the CSS if you change the size, otherwise just replace the images and they should work. Name your images the same as the existing ones of course.

 

I'll have a go at this. Hopefully it is similar to the add a new page in 2.2? Could the featured products module be used if fixed images were used? If random ones from the whole galleries images, could the new products module be amended so it looked in there instead of the products? Probably a very naive way of thinking how it works! :-"

 

If I managed to do this (with help probably/hopefully) I'll definately share. I think the ability to add various modules would be great for your contribution.

 

Thanks

You could modify the scroller or specials modules to pull your gallery images instead of the products. That mostly involves changing the SQL to whatever your gallery table and field names are. Then change the code to use that field name as well. I would start with the module that is the closest to what you want.

 

As an alternative, if you have code that does what you want for your gallery, you could just paste that into the execute() method of a module and make a couple of changes to have the module output it. The module will output the contents of the $body_text variable with this line:

       $oscTemplate->addBlock( $body_text, $this->group );

You'll see that line, or something very similar, at the end of the execute() method in every module.

 

Regards

Jim

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

Link to comment
Share on other sites

Yes, you replace the images with your own. You can change the color and shape to whatever you want. You will need to change the CSS if you change the size, otherwise just replace the images and they should work. Name your images the same as the existing ones of course.

I'll change the dotDark, dotLight, pause, play & transBlack75 images for now. :)

 

You could modify the scroller or specials modules to pull your gallery images instead of the products. That mostly involves changing the SQL to whatever your gallery table and field names are. Then change the code to use that field name as well. I would start with the module that is the closest to what you want.

 

As an alternative, if you have code that does what you want for your gallery, you could just paste that into the execute() method of a module and make a couple of changes to have the module output it. The module will output the contents of the $body_text variable with this line:

       $oscTemplate->addBlock( $body_text, $this->group );

You'll see that line, or something very similar, at the end of the execute() method in every module.

 

Regards

Jim

I'll get the gallery set up on a new page & then look at the specials module as you suggested with the gallery code.

 

This will do the front end, & I'm assuming I need to copy file/s on the admin side & amend similarly for the new module too?

 

Do you have a list of all the files needed to make up one module please? i.e. as explained in 2.2 for adding a new page

 

Thanks for your help.

 

Julie

Link to comment
Share on other sites

The module requires only two files: the module itself in catalog/includes/modules/<location>/ and the language file in catalog/includes/languages/<language>/modules/<location>/. The module file contains everything needed for both the catalog and admin sides.

 

Some modules need additional files to provide accessory Javascript, styles, functions, etc. Those are only used when it is not practical to put the contents in the module itself. In most cases, only the two module files are needed.

 

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,

 

Does Modular Front Page work with osCommerce 2.3.1? I am completely new to osCommerce and had tons of trouble with other addons before I realized that 2.3 and 2.3.1 are very different. I have no modules folder in the admin\includes\functions directory to install the very first "new" file in the list. I'm not sure what to do.

 

Thanks,

Natalie

Link to comment
Share on other sites

Yes it's designed to work with 2.3.1. You need to create the admin/includes/functions/modules/front_page directories and upload the new file.

 

Regards

Jim

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

Link to comment
Share on other sites

i have the following problem with banner rotator.

 

i use banner manager to upload the banners that have the same size, they are .png files and belongs to the same group.

 

if max banner number is 4 and i have uploaded 3 banners the front page module displays 2 banners...

 

if max banner number is 3 and i have uploaded 3 banners the front page module displays 2 banners...

 

if max banner number is 4 and i have uploaded 4 banners the front page module displays 3 banners...

 

 

is this sth wrong with my installation???

Edited by kosbou
Link to comment
Share on other sites

It sounds like you have a problem with one of your banners. Is the missing banner always the same one? If it is, check that the image is not corrupted, or just delete it and reupload it.

 

Regards

Jim

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

Link to comment
Share on other sites

i have upload 3 banners.

 

if i chooce rand() display the module displays always 1 banner less than the upload number.

 

if i refresh the page twice or more i can see all the banners but never all the three one after the other...

Link to comment
Share on other sites

It appears that the browser is not downloading all of the images. I have no idea why this is happening or what to do about it. I'll think about this and see if I can come up with something.

 

Regards

Jim

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

Link to comment
Share on other sites

  • 2 weeks later...

It is certainly possible, but it would require quite a bit of work. You would have to add all of the jquery and jquery UI scripts to both the Catalog and Admin side of your store, add the oscTemplate class, change the Module system in the Admin over to the new class system, and probably a bunch more. There's no list of the required files/changes to make, so you would have to compare files between the two versions.

 

It would probably be simpler to replace your store with a new 2.3 and add back your changes.

 

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

 

Not sure how to solve the next change I want to do? Searching the forum I see that to remove the "New Products" display from the categories pages (not the front page) I need to remove/comment the second mention of it.

However this section has been removed by the Modular Front Page. Could you tell me how I can do this please?

 

Thanks

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