2012-06-27 20:51:00

Bloke
Developer
omega
Real name: Stef Dawson
From: Leeds, UK
Known languages: Engl(ish)
Website

Re: yab_shop (simple textpattern shop with paypal support)

jayrope wrote:

a simple form of stock keeping could be implemented, using a custom field containing the number of available items, counting down, when item got sold

In addition to what I sent you via e-mail about the cart and checkout tags being containers (err, I think… haven’t checked) what you are after here is smd_ipn. It is a “listener” for completed PayPal transactions and allows you to run any custom code / tags of your choosing to do anything you like, e.g. update stock, store transactions, send off e-mail confirmations, deliver digital downloads, send off an smd_access_key to protected content. If you can dream it, you can do it. Plugin available on request at the moment, primarily because I haven’t got round to releasing it officially.

item could be reserved (automatically putting an “x” in custom_field “reserved”) or item article receiving a state change to “Pending” or whatever desired, when last item got sold, or upon manual editing of article.

That’s more tricky but I think the new callbacks would help you here as you could intercept the ‘add to cart’ action and change it to suit your needs.

Last edited by Bloke (2012-06-27 20:51:34)


The smd plugin menagerie — for when you need one more gribble of power from Textpattern.

Txp Builders – finely-crafted code, design and Txp

Offline

 

2012-06-28 14:49:24

jayrope
Plugin Author
lambda
Real name: jane ko
From: Berlin
Known languages: de, en, fr // all frequencies
Website

Re: yab_shop (simple textpattern shop with paypal support)

Bloke wrote:

the cart and checkout tags being containers (err, I think… haven’t checked)

Apparently there isn’t enough customisable tags available inside those containers.

<txp:yab_shop_cart>
<txp:yab_shop_cart_item>
<txp:yab_shop_cart_item_name /> (<txp:yab_shop_cart_item_quantity />x = <txp:yab_shop_cart_item_price />
<txp:yab_shop_cart_item_delete />
</txp:yab_shop_cart_item>
<txp:yab_shop_cart_subtotal />
<txp:yab_shop_link_to_checkout />
</txp:yab_shop_cart>

is something i am thinking of. I managed to modify <txp:yab_shop_cart> so that i could do something similar to
<txp:yab_shop_cart_items_j showquantity="0" showquantity="1" showsubtotal="0" />

However, that approach doesn’t include editing the cart, which would be necessary put an item_delete button behind each item listed.
This feature only shows up in the checkout process.
Which gets me back to the modular construction i was trying to imagine in my earlier post.

This modular construction seems impossible without looking at the complete checkout process first for the purpose of merging the ability to ONLY display cart (as in the current <txp:yab_shop_cart />) but as well checkout data with the editing capabilities we currently only have in the checkout part, such as item_delete or item_change_quantity – or checkout_add_address etc.

Taking it all apart, putting everything possible into plugin tags individually accessible, provide full display and editing capability to the PHP-unsavy textpattern programmer.

How does that sound? What did i miss, which already provides features in that direction? smd_ipn?

Last edited by jayrope (2012-06-28 15:58:06)


jayrope

Offline

 

2012-07-26 07:13:33

Pat64
Plugin Author
pi
Real name: Patrick
From: France
Known languages: lang="fr" ; lang="en" read only ; lang="html 5" ; love="TXP" ; thanks="TXP core Developers".
Website

Re: yab_shop (simple textpattern shop with paypal support)

Hi folks.

I’ve got some problems with accented characters send to Paypal website. Any idea how to correct it?

Thanks by advance.


Patrick.
Txp Tricks & Tips by french users : http://txp-fr.net | G+
@Devs : Can’t find the punched tape version of TXP and I need it!
Happy user of TXP 1.0RC1

Offline

 

2012-07-30 13:29:09

Pat64
Plugin Author
pi
Real name: Patrick
From: France
Known languages: lang="fr" ; lang="en" read only ; lang="html 5" ; love="TXP" ; thanks="TXP core Developers".
Website

Re: yab_shop (simple textpattern shop with paypal support)

… Really, no ideas ?


Patrick.
Txp Tricks & Tips by french users : http://txp-fr.net | G+
@Devs : Can’t find the punched tape version of TXP and I need it!
Happy user of TXP 1.0RC1

Offline

 

2012-07-30 17:13:21

maniqui
Moderator
omega
Real name: Julián
From: Buenos Aires, Argentina
Known languages: es,en

Re: yab_shop (simple textpattern shop with paypal support)

Hi Patrick.
Have you checked PayPal documentation for hints?
You could try processing the strings with ut8_encode (at least, I fixed an issue with accented and special characters not being posted to Twitter via its API). rah_function plugin could be helpful for doing that.


La música ideas portará y siempre continuará

TXP Builders – finely-crafted code, design and txp

Offline

 

2012-07-31 06:03:32

Pat64
Plugin Author
pi
Real name: Patrick
From: France
Known languages: lang="fr" ; lang="en" read only ; lang="html 5" ; love="TXP" ; thanks="TXP core Developers".
Website

Re: yab_shop (simple textpattern shop with paypal support)

Hi Julián. Tks for your reply ;)

I’d tried lot of things directly into the source (even ut8_encode PHP function): none works as expected. I’m going to try again and if I can got a result I project to convert strings in uppercases.


Patrick.
Txp Tricks & Tips by french users : http://txp-fr.net | G+
@Devs : Can’t find the punched tape version of TXP and I need it!
Happy user of TXP 1.0RC1

Offline

 

2012-07-31 08:01:08

Pat64
Plugin Author
pi
Real name: Patrick
From: France
Known languages: lang="fr" ; lang="en" read only ; lang="html 5" ; love="TXP" ; thanks="TXP core Developers".
Website

Re: yab_shop (simple textpattern shop with paypal support)

Ok. Finally I’d made this changes (file: yab_shop_core) into the yab_shop_build_paypal_form($cart) function:

$products .= hInput('item_name_'.$i, iconv('utf-8', 'ascii//TRANSLIT', $item['name'])).n.

All is (pretty) perfect now: characters are displayed without any accents.


Patrick.
Txp Tricks & Tips by french users : http://txp-fr.net | G+
@Devs : Can’t find the punched tape version of TXP and I need it!
Happy user of TXP 1.0RC1

Offline

 

2012-08-11 12:08:42

palmkvist
New Member
alpha

Re: yab_shop (simple textpattern shop with paypal support)

Is there a way to swith the order of the sum and the currency sign?
Swedish currency is written “ 150kr or 150,00kr “

Offline

 

2012-08-13 08:18:54

trenc
Plugin Author
lambda
Real name: Tommy
From: Cologne
Known languages: de, en [kind of]
Website

Re: yab_shop (simple textpattern shop with paypal support)

Hi palmkvist,

Is there a way to swith the order of the sum and the currency sign?
Swedish currency is written “ 150kr or 150,00kr “

Sorry, but there is no build-in method to achieve this.

Offline

 

2012-08-31 11:05:29

trenc
Plugin Author
lambda
Real name: Tommy
From: Cologne
Known languages: de, en [kind of]
Website

Re: yab_shop (simple textpattern shop with paypal support)

I bugfixed my version of Yab Shop and polished the admin UI a little bit for usage with TXP 4.5.0 themes:

12-08-31 – v0.8.1: yab_shop_v0.8.1.tar.gz

  • bugfix: fix a bug with PHP 5.3 and a deprecated warning (referencing new instances)
  • bugfix: fixed a bug in the install/update procedure
  • bugfix: refurnished admin UI for TXP 4.5.0
  • bugfix: partial using of plugin flags (prefs and delete)

Offline

 

Powered by FluxBB