Bakery: Small Shop Module (ORIGINAL TOPIC)

freeSbee

Hi westonjeff, hi instantflorian

Quote from: westonjeff on March 15, 2010, 05:30:00 PM
http://dallasbrass.dce.k12.wi.us?pm=paypal

PayPal threw an error as follows:
You must enter a properly formatted Return URL. If you do not enter a properly formatted Return URL, which includes the Return URL requirements, Auto Return will not be turned on and applied to your Website Payment pages.

Just made some tests and figured out that it is best if you chop the get parameters (?pm=paypal) of the return url provided by Bakery.
Just use http://dallasbrass.dce.k12.wi.us
Hope this will stop PayPal moaning about not properly formatted return url.

Regards Christoph

instantflorian

Hi westjoneff, hi Christoph,

I had exactly the same problem today too when launching a new bakery 1.5.1 shop.
Reason: if you call mydomain.foo?pm=paypal *without* having submitted an order before, the unchanged homepage of your website is displayed. But paypal checks the site if there is the text "blah bla thank you for your order blah login to paypal to see order details etc" - and if it doesn't find the text, it complains. And it can't find the text, because it's only displayed if there was an order.

But there is a simple workaround: just build a hidden wysiwyg page with the sentence suggested by paypal and enter the complete link to *this* site as return page at paypal. Paypal will accept this, and - voodoo?! - in the end of processing the payment, the bakery confirmation page is displayed nevertheless.

Regards
-instantflorian.

freeSbee

@snoork
https://forum.websitebaker.org/index.php/topic,7834.msg74493.html#msg74493
ORDER BY modified_when

@westonjeff
Please read PayPals Return URL requirements or investigate PayPal why they do not accept your URL.

Regards Christoph

westonjeff

Following directions from backend of Bakery, payment method, PayPal, I inserted the supplied URL @ PayPal for "Return URL", (Auto Return selected on @ PP)

http://dallasbrass.dce.k12.wi.us?pm=paypal

PayPal threw an error as follows:
You must enter a properly formatted Return URL. If you do not enter a properly formatted Return URL, which includes the Return URL requirements, Auto Return will not be turned on and applied to your Website Payment pages.

What would be wrong with the format above?

TIA for any help!


snark

is there an easy way to change the order of the products... I want every new item to be at the top of the list


freeSbee


New Version of Bakery:

VERSION 1.5.1 (03/13/2010)


VERSION HISTORY
Bakery 1.5.1 version history

KNOW HOW
Further information can be found on the Bakery Website.

DOWNLOAD
Download from the Bakery Website.

PLEASE NOTE
Please read the upgrade notes when upgrading to version 1.5.1.


Christoph

freeSbee

Hi itsnick

Quote from: itsnick on March 12, 2010, 07:26:36 AM
I keeping getting this error from PayPal: "Incorrectly formatted item amount"
I've only noticed it on items were tax would make the total come out to more than 2 places, i.e. $1.00 plus 7.5% tax = $1.075
Is there a fix for this or maybe a way to round to only two places.

Search view_summary.php, line 743:
// Put order total into the session var for use with payment gateways
$_SESSION['bakery']['order_total'] = $order_total;


Replace by:
// Put rounded order total into the session var for use with payment gateways
$_SESSION['bakery']['order_total'] = round($order_total, 2);


Regards Christoph

itsnick

I keeping getting this error from PayPal: "Incorrectly formatted item amount"

I've only noticed it on items were tax would make the total come out to more than 2 places, i.e. $1.00 plus 7.5% tax = $1.075

Is there a fix for this or maybe a way to round to only two places.

westonjeff

#701
Sorry if this is a stupid question, but can some type of order detail or site info be passed to the PayPal system?

Something as simple the page name that the order's coming from would be alright. Anyone done this?

TIA for any help -- as mentioned in an earlier post, I'm no PHP guru.  :|

freeSbee

@ westonjeff

Quote from: westonjeff on March 10, 2010, 09:22:05 PM
Revised three files as suggested, and order now went to Paypal's sandbox as hoped, but . . .
#1 -- Order detail didn't display at PayPal, just a total order amount. I'll look around, but wonder how I can get order detail to display on Paypal page(s).
True, no order details are sent to PayPal by Bakery, just the order total amount.

Quote from: westonjeff on March 10, 2010, 09:22:05 PM
#2 -- Upon return to test store, Bakery informed me "Payment status or payment method is not defined."
#3 -- Didn't receive email notifications from Bakery or Paypal.
Login to your PP sandbox account to get further information on the payment status and to see the PP emails (no real emails are sent by the sandbox). Bakery just sends email notifications if the transaction payment status returned by PayPal is "Completed".

Regards Christoph

westonjeff

#699
Revised three files as suggested, and order now went to Paypal's sandbox as hoped, but . . .

#1 -- Order detail didn't display at PayPal, just a total order amount. I'll look around, but wonder how I can get order detail to display on Paypal page(s).

#2 -- Upon return to test store, Bakery informed me "Payment status or payment method is not defined."

#3 -- Didn't receive email notifications from Bakery or Paypal.

More help would be *much* appreciated if time permits . . . thank you!


freeSbee

Hi Westonjeff

Quote from: westonjeff on March 10, 2010, 03:42:34 PM
Need to test with PayPal's Sandbox system

I've tried revising line #27 in "payment_methods\paypal\check_payment.php"  from "false" to "true" but orders still get directed to www.paypal.com instead of www.sandbox.paypal. com

Due to a lack of a config file you have to set it 3 times:

Set $testing = false; to $testing = true; at...

  • payment_methods/paypal/processor.php line 26
  • payment_methods/paypal/check_payment.php line 27
  • payment_methods/paypal/ipn.php line 29

If you like to get detailed information on the PayPal IPN (Instant Payment Notification) testing transaction to a special email account specify a testing email address at payment_methods/paypal/ipn.php line 30.

Regards Christoph

westonjeff

Need to test with PayPal's Sandbox system

I've tried revising line #27 in "payment_methods\paypal\check_payment.php"  from "false" to "true" but orders still get directed to www.paypal.com instead of www.sandbox.paypal. com

// Use payment gateway sandbox for testing
$testing  = false;

I see later in the file the following:
$pdt_url = $testing ? 'www.sandbox.paypal. com' : 'www.paypal.com';

Not being a seasoned PHP programmer, I appreciate any help you experts can provide.

Couldn't find anything on http://www.bakery-shop.ch/ or here . .  .

Thanks in advance for any help, and for a great module!!

Ruud

Quote from: zonathen on March 08, 2010, 02:59:54 AM
Thanks for wonderful module.

When I upload with resize option it seems to be rotating the image 90 degrees to the left so the image is sideways when displayed.  I looked at the code and didin't see anything obvious in resize functions.  Anybody else experiencing this behaviour with resizing images on upload?
Probably you are locally viewing your images in a (smart) viewer that will autorotate based on the camera orientation information in the image.
Before upload, just be sure your image is really rotated corectly.
[url=https://dev4me.com/modules-snippets/]Dev4me - WebsiteBaker modules[/url] - [url=https://wbhelp.org/]WBhelp.org[/url]

SickBoy75

Found it!!!!

Just edit your lang php file, ie ES.php and find this:
// MODUL BAKERY ADDITIONAL CHARS
// Define additional chars to be accepted by the customer address form.
// The chars should be corresponding to the localisation language.

Add your especial chars in this line
$MOD_BAKERY['ADD_REGEXP_CHARS'] = 'Á,É,Í,Ó,Ú,á,é,í,ó,ú,ñ,Ñ,ç,º,ª';

Works like it should ;)

SickBoy75

Quote from: Claren on February 11, 2010, 02:23:56 PM
Quote
What charset encoding did you set as WB default charset (advanced options of the general WB settings)?
What charset encoding did you use to save your SE localisation file?

Regards Christoph

UTF-8 in Website baker.

Eehh, localisation files?
In the comment on top of SE.php it says
"This file is saved using charset iso-8859-1.
  If utf-8 is set as WB default charset, some iso-8859-1 encoded localisation strings
  will be automatically converted to utf-8."
I didnt tamper with that. Just loaded the EN files, translated them and saved as SE.


I'm having the same problem, many of my spanish cutomers can validate their orders because of this.

I need to add special chars to de validate function, but can't find it

SickBoy75

Is there a way to skip/avoid the address validation in the shop form??

I need to validate address like "Monterrey nº2" and the º gives an error.

Also, á, é, í, ó, ú, ñ, ü, /,  etc... will return the address error.

I'm searching for the validation code in the php files, but can find it.

thanks a lot

zonathen

Thanks for wonderful module.

When I upload with resize option it seems to be rotating the image 90 degrees to the left so the image is sideways when displayed.  I looked at the code and didin't see anything obvious in resize functions.  Anybody else experiencing this behaviour with resizing images on upload?

SickBoy75

I made a few changes in this module, in order to add a few SEO improvements.

1.- Changed the default item directory (/bakery/ by default) to a php variable, so i can change that dir to /shop/, /buy/, or something is related to the shop.

2.- Added a keywords field, so you easy can add keywords.
So I use "simplypagehead" snipet to change the head of every item page, adding a better title and keywords

NOTE: I made changes in simplypagehead in order to get the keywords from the shop items.

If someone likes this, or you plan to include it in future bakery version, I would post the zip with the changed files. I just want to return to WebsiteBaker my modest contribution.

I'm spanish, be patient with my english

dellington

I have modified the page settings template to include:

Racer's full name: <input type="text" size="25" name="racername">

I have updated the language file as follows:

$MOD_BAKERY['TXT_SKU'] = 'Racer\'s Name';

Line 239 of the view.php file originally says this:

$sku = $row2['sku'];

My understanding of that area of code is that it is collecting the item's sku # from the mod_bakery_items table and then inserting it into the mod_bakery_order table.

I would like instead for view.php to get the value for the sku field from the racername input field in my current order. I tried changing line 239 to this:

$sku = $_POST['racername'];

but it doesn't work - the sku field in the database is still blank.

It seems like this should work and I am just missing a small step somewhere. Any help?

dellington

Sorry, I haz the dum. I tried to make that work and only broke the cart.  :-(

I fixed it back the way it was and now it works again.

I'm wondering if it might be easier to hijack one of the existing fields I'm not using? For example I am not using the sku field. I see that it gets inserted into the mod_bakery_order table.

Could I name my racername field to sku and then do some post thing to get it inserted into the database?

Then I could make use of the existing template strings that would display the sku field in the order details and confirmation emails.

Does that make any sense?

freeSbee

Quote from: dellington on February 27, 2010, 02:52:12 PM
Which files would I edit? The save_attribute.php one?
view.php is a good starting point. Other files involved will be included - just have a look into the code. It is well commented.

Regards Christoph

dellington

Could you say a little more about this:

Quote from: freeSbee on February 27, 2010, 02:36:50 PM
Then catch the $_POST['racername'], sanitize it and do whatever you want using the appropriate PHP code.

Which files would I edit? The save_attribute.php one?

freeSbee

Hi Deborah

In this case you do not have to make use of the free-definable text fields. Just write Racer's full name: <input type="text" size="25" name="racername"> into your template. Make sure the input field is inside of the form tag otherwise it will not be submitted!
Then catch the $_POST['racername'], sanitize it and do whatever you want using the appropriate PHP code.

Regards Christoph

dellington

Quote from: freeSbee on February 23, 2009, 09:37:28 AM

@jollylama

Quote from: jollylama on February 23, 2009, 01:44:52 AM
can i somehow add a text field that will go along with the order on purchase?
hope this makes sense..
Hi jollylama
Yes, it makes sense. But Bakery does not come with the feature you require. You can implement it yourself but you need basic knowledge of PHP!

Regards Christoph


I am trying to do something like this. I have set up a web page to accept race registrations:

http://www.jwchendersonville.org/pages/pbj5k/fun-run.php

We want to collect a person's name on this screen, as it may be different from the name of the person paying for the order (like if a parent registers their child).

I figured out how to display "Racer's name:" as a free-definable text field and even got a text input area to show up by putting this into the template:

[TXT_FIELD_1]: <input type="text" size="25" name="racername">

but I don't know how to make it work beyond that.

I do know some php...help?