Recent Topics

1 Jul 16, 2007 01:53    

I'm trying out the new plugin b2commerce in version 1.10.2 but as soon as I upload the plugin into the appropiate folder and try to open the Plugins Folder, I get this error:

Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /home/piezasyt/public_html/plugins/b2commerce_plugin/_b2commerce.plugin.php on line 536

Line 536 being:


	public function BeforeEnable()
	{
		return true;
	}

Anybody knows why this happens?

2 Jul 16, 2007 09:50

Wow, you can actually delete half the code in that plugin!

You can remove the whole of that function, it does nothing.

You'll also need to replace all occurrences of "public function" with "function" for it to work in < php5

¥

3 Sep 02, 2007 01:52

Hello!
Same problem occurred to me and I got thrugh it.
Now when I insert a product by b2commerce, after saving the page I got the error:

MySQL error!

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '0,0,'EUR')' at line 1(Errno=1064)

Your query:

INSERT INTO evo_b2commerce_offers (offer_item_ID,offer_price,offer_shipcost,offer_currency)
VALUES (,0,0,'EUR')

thanks

http://www.genovamusica.altervista.org/pubblicita/

4 Sep 02, 2007 02:03

There is no offer_item_ID in the VALUES sent to the database. The other values are defaults, but the offer_item_ID needs to be set somewhere.
I cannot see if this is because you didn't make an item to be sold or if the cause is an error in the plugin.

*edit* the offer_item_ID is the 'nothing' before the comma in VALUES.

5 Sep 05, 2007 16:51

same problem for me, any solution ? :-/

6 Sep 06, 2007 00:52

Excuse me, I don't speak English. The problem I have not resolved him. Or I have resolved him uninstalled the plugin b2commerce and directly enrolling me in Paypal that gives you the way to insert a link for every product that you offer in your blog to be able to make to make the payment from your clients online with the credit card..

7 Oct 02, 2007 00:00

I have been having the same error. I scanned the code but did not spend much time on it.

MySQL error!

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '0,0,'EUR')' at line 1(Errno=1064)

Your query:

INSERT INTO evo_b2commerce_offers (offer_item_ID,offer_price,offer_shipcost,offer_currency)
VALUES (,0,0,'EUR')

It looks like it is missing the part for the itemID (offer_item_ID) and 'EUR' is hard coded so if you want to use a diffrent money type you will have to change that tag in code. I did not see any other place to set it.

This addin comes with no instructions so it has been very hard to get to work. If I have time this weekend I will take a close look at the code and see if I can make it more dynamic. I have not done anything with PHP and the like before so it will probably take some time.

If somone has already fixed it or knows of a fix please let us know. I would rather use this one as it seems to be simple (other then it does not work...). We have no options to add inventory.

The database it creates is as follows:
offer_ID int(11) auto_increment
offer_item_ID int(11)
offer_price float(5,2)
offer_shipcost float(5,2)
offer_currency char(3)

Given that structure I would think that it is possible to change the currency from EUR to somthing else and it has the basics for each item. However, no way to add them with the addon (that I can see).

8 Dec 01, 2007 07:21

first of all a note to Dmaxwell: thanks for the post, and sorry for almost the same username, I didn't know that there was another "...maxwell" :'(

Has anyone come up with a fix for this yet?

I would really badly need it on my blog!

I was able to fix teh first bug mentioned above with the help suggested, but now I am also stuck with this MySQL errror...

9 Dec 19, 2007 06:45

I'm having all the same problems as the first poster. I made the db entries myself but that didn't help either.

Anyone have any ideas??


Form is loading...