Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

php dunce needs help with minor code issue


Guest

Recommended Posts

Posted

Hi

 

I am assuming this is minor and that I am just too ignorant to get it right, because I am new to php and logic does not seem to be enough without sufficient knowledge.

 

I have articles manager installed and am trying to modify a page to call the cross-sell function. Another file in the main catalogue folder is calling it using:

 

<?php
//added for cross-sell
  if ( (USE_CACHE == 'true') && !SID) {
 include(DIR_WS_MODULES . FILENAME_ARTICLES_XSELL);
  } else {
 include(DIR_WS_MODULES . FILENAME_ARTICLES_XSELL);
}
  }
?>

 

This works in said file. The file articles_xsell.php is in catalogue/includes/modules while the file that is calling it is in catalogue.

 

The page that I am now also trying to call this into is also in catalogue/includes/modules.

 

However, no matter how I try to adapt this bit of code on the new page, it shows nothing where the cross-sell info should be appearing.

 

Can anyone just give me the line of code I would need to insert to get this to work?

 

What I have already tried is:

 

Exact same code as above;

 

Also tried

<?php include 'articles_xsell.php'; ?>

 

Also tried

<?php include (DIR_WS_MODULES . 'articles_xsell.php'); ?>

 

Also tried

<?php include (DIR_WS_MODULES . FILENAME_ARTICLES_XSELL); ?>

 

No joy on any of them. All just show nothing.

 

I would really appreciate any help I can get with this.

 

Thanks in advance.

Posted

why dont go directly to the contribution thread?

Upon receiving fixes and advice, too many people don't bother to post updates informing the forum of how it went. Until of course they need help again on other issues and they come running back!

 

Why receive the information you require in good faith for free, only to then have the attitude to ignore the people who gave it to you?

 

There's no harm in saying, 'Thanks, it worked'. On the contrary, it creates a better atmosphere.

 

CHOOCH

Posted
why dont go directly to the contribution thread?

 

 

Hi

 

I've been and myself and many others are posting lots of questions but the forum seems deserted.

 

Essentially I don't think the help I am looking for is limited to a specific contribution, but rather just some basic php. - This is an assumption of course and could be wrong.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...