Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Insert a php file and keep osC shell


Top_Speed

Recommended Posts

Posted

Hi,

 

I have the Information Box Contrib installed where you add or edit pages on the fly (works nicely).

 

I want to load a php page (phpbb forum) within the osC shell. I have put this in as an internal page but it doesn't work...

 

<?php include('http://www.mysite.com/mysite_forum/index.php');?>

 

 

Any code or changes that I need to make it load in osC?

 

Thanks, KJ

define('PROJECTS', 'Something that goes on forever!');

Posted

Make sure that apply the 'application_top' and 'application_bottom' code to the page and end the page name with '.php' (unless otherwise configured). Here is an example of what you should add:

 

<?php

/*

  $Id: index.php,v 2.02 2004/09/15 13:30:00 UJP Co. Exp $

 

  osCommerce, Open Source E-Commerce Solutions

  http://www.oscommerce.com

 

  Copyright © 2004 osCommerce

 

  Released under the GNU General Public License

*/

 

  require('includes/application_top.php');

 

  require(DIR_WS_LANGUAGES . $language . '/' . FILENAME_DEFAULT);

?>

<?php

$start_time = microtime()

?>

 

And:

 

<?php

$end_time = microtime();

$render_time = $end_time - $start_time;

echo "<!-- This page was generated in $render_time microseconds -->";

 

?>

<?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>

 

That should do it. After that, it will function like an osC page.

· willross

··········

Posted

FYI - Information pages unlimited versions < 1.1 are vulnerable to URL overlaoding SQL interjections. Do not install the contribution. A beginner wanna-be hacker could easily drop your store database, tables, or modify rows at leisure.

 

You and the entire osC forum membership have been warned...

 

Hopefully that is not the contribution/version that you installed.

 

Bobby

Archived

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

×
×
  • Create New...