Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Parse error!


sjhnjah

Recommended Posts

Now I've done it. I have a parse error on the last line where you see ['manufacturers_name'] I was trying to get rid of the lines under my products that say Date added:

and Manufactures Name:

Couldn't make it work by deleting the last two lines, so I was trying to put it back like it was until I could study it more, now I can't seem to get the syntax correct. This would be a two fold question if anyone could help me (1) Get my page to reload correctly without the parse error

and what would even be greater, :roll: (2) Tell me how to get rid of the Date added: and Manufacturer: lines under new product, which was my original mission.

{

$products_new_array[] = array('id' => $products_new['products_id'],

'name' => $products_new['products_name'],

'image' => $products_new['products_image'],

'price' => $products_new['products_price'],

'specials_price' => $products_new['specials_new_products_price'],

'tax_class_id' => $products_new['products_tax_class_id'],

'date_added' => tep_date_long($products_new['products_date_added'],

'manufacturer' => $products_new['manufacturers_name'];

}

 

Any help would be very much appreciated!

Sarah

A newbie who has learned just enough to be dangerous!

Link to comment
Share on other sites

That's what I thought as well. As you can probably tell, I don't know code so I was guessing. After the ]

what do I need? I've tried every combination using other examples on the page, but no go. Can you be more specific?

This is just two that I've tried that do not work.

 

'manufacturer' => $products_new['manufacturers_name']);

}

'manufacturer' => $products_new['manufacturers_name']));

}

A newbie who has learned just enough to be dangerous!

Link to comment
Share on other sites

This is my guess...

 

{

$products_new_array[] = array('id' => $products_new['products_id'],

'name' => $products_new['products_name'],

'image' => $products_new['products_image'],

'price' => $products_new['products_price'],

'specials_price' => $products_new['specials_new_products_price'],

'tax_class_id' => $products_new['products_tax_class_id'],

'date_added' => tep_date_long($products_new['products_date_added']),

'manufacturer' => $products_new['manufacturers_name']);

}

 

One after the tep_date_long argument and one at the end of the array() which would be just before the semicolon.

 

I would have told you the whole thing to begin with, but I wanted to give you a chance to figure it out :)

 

-j

Link to comment
Share on other sites

Oh by golly gee whiz!!! I've been focusing on the line the parse error msg told me was wrong and never even noticed the one above. I really did try to figure it out myself, but I don't mind being challenged to think for myself. :D

I can't thank you enough!

Sarah

A newbie who has learned just enough to be dangerous!

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...