Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

PLEEEEEEEAAAAASEEEE HELP ME!!!!!


ipodskins

Recommended Posts

can some one please help me im desperate!!! ive installed free amount and when i go to the shipping module it displays the following error:

 

Parse error: parse error in /home/httpd/vhosts/freepgs.com/httpdocs/kashif/catalog/includes/modules/shipping/freeamount.php on line 1

 

 

anyone seen this before??

please help me

 

kashif

Link to comment
Share on other sites

A parse error is normaly somthing out of place, like a commer a dot or just something random because you had something in your eye and twitched. Becuase it is on line one it should be pretty easy to find. look for somthing out of place. If you can't see it post line one and someone will be able to.

Link to comment
Share on other sites

here is the begininig of the code when i open it in notepad!! when i use cutehtml it is all in one line?????

 

 

*/

 

class freeamount {

var $code, $title, $description, $icon, $enabled;

 

// class constructor

function freeamount() {

$this->code = 'freeamount';

$this->title = MODULE_SHIPPING_FREECOUNT_TEXT_TITLE;

$this->description = MODULE_SHIPPING_FREECOUNT_TEXT_DESCRIPTION;

$this->icon =''; // change $this->icon = DIR_WS_ICONS . 'shipping_ups.gif'; to some freeshipping icon

$this->enabled = MODULE_SHIPPING_FREECOUNT_STATUS;

}

 

function quote($method = '') {

global $cart;

 

if (( $cart->show_total() < MODULE_SHIPPING_FREECOUNT_AMOUNT ) && MODULE_SHIPPING_FREECOUNT_DISPLAY == 'False')

return;

 

$this->quotes = array('id' => $this->code,

'module' => MODULE_SHIPPING_FREECOUNT_TEXT_TITLE);

 

if ( $cart->show_total() < MODULE_SHIPPING_FREECOUNT_AMOUNT )

$this->quotes['error'] = MODULE_SHIPPING_FREECOUNT_TEXT_WAY;

[code]

 

thanks

Link to comment
Share on other sites

*/ is the first line of code? Delete that. */ is the end of a comment - like this:

Here's some code, it's read by the computer and processed.

/*
Here's some comment text.  This is not read by the computer, it's just for humans to read.  The end of the comment is coming up:
*/

Here's more code, still read by the computer.

Chris Dunning

osCommerce, Contributions Moderator Team

 

Please do not send me PM! I do not read or answer these often. Use the email button instead!

 

I do NOT support contributions other than my own. Emails asking for support on other people's contributions will be ignored. Ask in the forum or contact the contribution author directly.

Link to comment
Share on other sites

It cannot be all the code as there are no php markups <?php beginning and ?> at the end so the */ is more likely to be the end of the file information

 

<?php
/*
 $Id$

 The Exchange Project - Community Made Shopping!
 http://www.theexchangeproject.org

 Copyright (c) 2000,2001 The Exchange Project

 Released under the GNU General Public License

 ----------------------------------------------
 ane - 06/02/02 - modified freecount.php to 
 allow for freeshipping on minimum order amount
 originally written by dwatkins 1/24/02
 ----------------------------------------------
*/

 class freeamount {
   var $code, $title, $description, $icon, $enabled;

// class constructor
   function freeamount() {
     $this->code = 'freeamount';
     $this->title = MODULE_SHIPPING_FREECOUNT_TEXT_TITLE;
     $this->description = MODULE_SHIPPING_FREECOUNT_TEXT_DESCRIPTION;
     $this->icon ='';   // change $this->icon =  DIR_WS_ICONS . 'shipping_ups.gif'; to some freeshipping icon
     $this->sort_order = MODULE_SHIPPING_FREECOUNT_SORT_ORDER;
     $this->enabled = MODULE_SHIPPING_FREECOUNT_STATUS;
   }

   function quote($method = '') {
     global $cart;
  
  if (( $cart->show_total() < MODULE_SHIPPING_FREECOUNT_AMOUNT ) && MODULE_SHIPPING_FREECOUNT_DISPLAY == 'False')
  return;

     $this->quotes = array('id' => $this->code,
                           'module' => MODULE_SHIPPING_FREECOUNT_TEXT_TITLE);

     if ( $cart->show_total() < MODULE_SHIPPING_FREECOUNT_AMOUNT )
       $this->quotes['error'] = MODULE_SHIPPING_FREECOUNT_TEXT_WAY;
     else
 $this->quotes['methods'] = array(array('id'    => $this->code,
                                              'title' => MODULE_SHIPPING_FREECOUNT_TEXT_WAY,
                                              'cost'  => 0));

     if (tep_not_null($this->icon)) $this->quotes['icon'] = tep_image($this->icon, $this->title);

     return $this->quotes;
   }

   function check() {
     $check = tep_db_query("select configuration_value from " . TABLE_CONFIGURATION . " where configuration_key = 'MODULE_SHIPPING_FREECOUNT_STATUS'");
     $check = tep_db_num_rows($check);

     return $check;
   }

   function install() {
     tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Enable Free Shipping with Minimum Purchase', 'MODULE_SHIPPING_FREECOUNT_STATUS', 'True', 'Do you want to offer free shipping?', '6', '7', 'tep_cfg_select_option(array(\'True\', \'False\'), ', now())");
     tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) values ('Enable Display', 'MODULE_SHIPPING_FREECOUNT_DISPLAY', 'True', 'Do you want to display text way if the minimum amount is not reached?', '6', '7', 'tep_cfg_select_option(array(\'True\', \'False\'), ', now())");
     tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id,  sort_order, date_added) values ('Minimum Cost', 'MODULE_SHIPPING_FREECOUNT_AMOUNT', '50.00', 'Minimum order amount purchased before shipping is free?', '6', '8', now())");
     tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) values ('Reihenfolge der Anzeige', 'MODULE_SHIPPING_FREECOUNT_SORT_ORDER', '0', 'Niedrigste wird zuerst angezeigt.', '6', '4', now())");
   }

   function remove() {
     tep_db_query("delete from " . TABLE_CONFIGURATION . " where configuration_key in ('" . implode("', '", $this->keys()) . "')");
   }

   function keys() {
     return array('MODULE_SHIPPING_FREECOUNT_STATUS', 'MODULE_SHIPPING_FREECOUNT_DISPLAY', 'MODULE_SHIPPING_FREECOUNT_AMOUNT','MODULE_SHIPPING_FREECOUNT_SORT_ORDER');
   }
 }
?>

Edited by 241

No longer giving free advice. Please place deposit in meter slot provided.  Individual: [=] SME: [==] Corporation: [===]
If deposit does not fit one of the slots provided then you are asking too much! :P

Is your Osc dated try Phoenix  raising oscommerce from the ashes.

Link to comment
Share on other sites

Very true...ipod? What's on line 1 of this file?

Chris Dunning

osCommerce, Contributions Moderator Team

 

Please do not send me PM! I do not read or answer these often. Use the email button instead!

 

I do NOT support contributions other than my own. Emails asking for support on other people's contributions will be ignored. Ask in the forum or contact the contribution author directly.

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