Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Easy CSV Import


DawnG

Recommended Posts

I'm using the Easy CSV Import to carry out some bulk uploads, but the prices are going in incorrectly.

http://www.oscommerce.com/community/contributions,4920

 

For example if I set a price at £11.95 the price that is uploaded to the database is 1195.000

 

I have two questions relating to this contrib:

 

1 - How do I fix the pricing issue?

 

2 - How would I customise to include the header tags fields i.e. Products Page Title, Page Header Description, Product Keywords

 

Any help would be greatly appreciated.

Edited by DawnG
Link to comment
Share on other sites

  • 2 months later...

Haven't tried it but what happens if you remove the currency symbol

 

e.g.

 

11.59

 

not

 

£11.59

Need help installing add ons/contributions, cleaning a hacked site or a bespoke development, check my profile

 

Virus Threat Scanner

My Contributions

Basic install answers.

Click here for Contributions / Add Ons.

UK your site.

Site Move.

Basic design info.

 

For links mentioned in old answers that are no longer here follow this link Useful Threads.

 

If this post was useful, click the Like This button over there ======>>>>>.

Link to comment
Share on other sites

  • 3 weeks later...
I'm using the Easy CSV Import to carry out some bulk uploads, but the prices are going in incorrectly.

http://www.oscommerce.com/community/contributions,4920

 

For example if I set a price at £11.95 the price that is uploaded to the database is 1195.000

 

I have two questions relating to this contrib:

 

1 - How do I fix the pricing issue?

 

2 - How would I customise to include the header tags fields i.e. Products Page Title, Page Header Description, Product Keywords

 

Any help would be greatly appreciated.

 

 

Here is now to fix:

 

Open the file /admin/csv_import.php

 

Edit line 298:

 

Original:

$data[$products_fields['products_price']] = str_replace('.', '', $data[$products_fields['products_price']]);

 

Comment that line out.

 

New:

//$data[$products_fields['products_price']] = str_replace('.', '', $data[$products_fields['products_price']]);

 

 

Then reupload that file and you should be good. Not sure WTF he was doing when he said "Excel uses ',' as decimal separator, mysql decimal uses '.'" in his comments, but it's wrong.

 

 

Clear the categories then try the import again.

 

Email [email protected] if you need help.

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