Post by mihka73 » Wed Oct 05, 2011 7:58 pm

Καλημέρα σας προσπάθώ να κάνω μια δοκιμαστική συναλλαγή με το Paypal και στην περίληψη παραγγελίας που δίνει το Paypal μπριν αρχίσει η διαδικασία πληρωμής το όνομα του προϊόντος και ο κωδικός εμφανίζονται με "σουηδικά".
Τι πρόβλημα υπάρχει;
Μπορώ να ρυθμίσω κάπως το opencart;
Ευχαριστώ
ps υπάρχει συνημμένο

Newbie

Posts

Joined
Sun Feb 13, 2011 6:28 am

Post by georgekaf » Mon Dec 05, 2011 11:25 pm

Α γνωστο θεμα....

Θα πας στο αρχειο "catalog\controller\payment\pp_standard.php" και θα βρεις τις παρακατω γραμμες

Code: Select all

		$this->data['fields']['business'] = $this->config->get('pp_standard_email');
		$this->data['fields']['currency_code'] = $currency;
		$this->data['fields']['first_name'] = html_entity_decode($this->order_info['payment_firstname'], ENT_QUOTES, 'UTF-8');
		$this->data['fields']['last_name'] = html_entity_decode($this->order_info['payment_lastname'], ENT_QUOTES, 'UTF-8');
		$this->data['fields']['address1'] = html_entity_decode($this->order_info['payment_address_1'], ENT_QUOTES, 'UTF-8');
		$this->data['fields']['address2'] = html_entity_decode($this->order_info['payment_address_2'], ENT_QUOTES, 'UTF-8');
		$this->data['fields']['city'] = html_entity_decode($this->order_info['payment_city'], ENT_QUOTES, 'UTF-8');
		$this->data['fields']['zip'] = html_entity_decode($this->order_info['payment_postcode'], ENT_QUOTES, 'UTF-8');
		$this->data['fields']['country'] = $this->order_info['payment_iso_code_2'];
		$this->data['fields']['email'] = $this->order_info['email'];
		$this->data['fields']['invoice'] = $this->session->data['order_id'] . ' - ' . html_entity_decode($this->order_info['payment_firstname'], ENT_QUOTES, 'UTF-8') . ' ' . html_entity_decode($this->order_info['payment_lastname'], ENT_QUOTES, 'UTF-8');
		$this->data['fields']['lc'] = $this->session->data['language'];
		$this->data['fields']['rm'] = '2';
Στο τελος θα προσθεσεις και την γραμμη "$this->data['fields']['charset'] = "utf-8";" και ολα μαζι θα ειναι

Code: Select all

		$this->data['fields']['business'] = $this->config->get('pp_standard_email');
		$this->data['fields']['currency_code'] = $currency;
		$this->data['fields']['first_name'] = html_entity_decode($this->order_info['payment_firstname'], ENT_QUOTES, 'UTF-8');
		$this->data['fields']['last_name'] = html_entity_decode($this->order_info['payment_lastname'], ENT_QUOTES, 'UTF-8');
		$this->data['fields']['address1'] = html_entity_decode($this->order_info['payment_address_1'], ENT_QUOTES, 'UTF-8');
		$this->data['fields']['address2'] = html_entity_decode($this->order_info['payment_address_2'], ENT_QUOTES, 'UTF-8');
		$this->data['fields']['city'] = html_entity_decode($this->order_info['payment_city'], ENT_QUOTES, 'UTF-8');
		$this->data['fields']['zip'] = html_entity_decode($this->order_info['payment_postcode'], ENT_QUOTES, 'UTF-8');
		$this->data['fields']['country'] = $this->order_info['payment_iso_code_2'];
		$this->data['fields']['email'] = $this->order_info['email'];
		$this->data['fields']['invoice'] = $this->session->data['order_id'] . ' - ' . html_entity_decode($this->order_info['payment_firstname'], ENT_QUOTES, 'UTF-8') . ' ' . html_entity_decode($this->order_info['payment_lastname'], ENT_QUOTES, 'UTF-8');
		$this->data['fields']['lc'] = $this->session->data['language'];
		$this->data['fields']['rm'] = '2';
		$this->data['fields']['charset'] = "utf-8";
Μετα πας στον Paypal λογαριασμο σου και θα κανεις τα εξης βηματα:

Ενημερώνουμε το Paypal να δέχεται απο τη σελίδα μας τα UTF-8

1. Συνδεόμαστε στο PayPal account, επιλέγουμε "My Account", μετά την καρτέλα Profile.
2. Κάνουμε κλικ στο "Language Encoding" στη δεξιά στήλη Selling Preferences.
3. Κάνουμε κλικ στο κουμπί "More Options" κι επιλέγουμε UTF-8 και στις δυο περιπτώσεις.

Ειχα ακριβως το ιδιο προβλημα με εναν πελατη μου και μετα απο λιγο ψαξιμο το βρηκα.

Το προβλημα ειναι οτι δεν υποστηριζονται τα ελληνικα απο τις κωδικοποιησεις που χρησιμοποιουν το opencart και το paypal.

New member

Posts

Joined
Fri Jun 17, 2011 10:46 pm

Post by mihka73 » Sun Jan 22, 2012 4:49 am

TNKS να 'σαι καλά... :)

Newbie

Posts

Joined
Sun Feb 13, 2011 6:28 am

Post by georgekaf » Tue May 08, 2012 3:49 am

Μετά απο πολλές αναβαθμισεις όσο του Opencart όσο και του paypal η διαδικασια υποστηριξης ελληνικων εχει αλλαξει ελαφρώς... Για την 1.5 version του opencart.

Παλι στο catalog/controller/payment/pp_standard.php βρίσκουμε:

Code: Select all

			$this->data['currency_code'] = $order_info['currency_code'];
			$this->data['first_name'] = html_entity_decode($order_info['payment_firstname'], ENT_QUOTES, 'UTF-8');	
			$this->data['last_name'] = html_entity_decode($order_info['payment_lastname'], ENT_QUOTES, 'UTF-8');	
			$this->data['address1'] = html_entity_decode($order_info['payment_address_1'], ENT_QUOTES, 'UTF-8');	
			$this->data['address2'] = html_entity_decode($order_info['payment_address_2'], ENT_QUOTES, 'UTF-8');	
			$this->data['city'] = html_entity_decode($order_info['payment_city'], ENT_QUOTES, 'UTF-8');	
			$this->data['zip'] = html_entity_decode($order_info['payment_postcode'], ENT_QUOTES, 'UTF-8');	
			$this->data['country'] = $order_info['payment_iso_code_2'];
			$this->data['email'] = $order_info['email'];
			$this->data['invoice'] = $this->session->data['order_id'] . ' - ' . html_entity_decode($order_info['payment_firstname'], ENT_QUOTES, 'UTF-8') . ' ' . html_entity_decode($order_info['payment_lastname'], ENT_QUOTES, 'UTF-8');
			$this->data['lc'] = $this->session->data['language'];
			$this->data['return'] = $this->url->link('checkout/success');
			$this->data['notify_url'] = $this->url->link('payment/pp_standard/callback', '', 'SSL');
			$this->data['cancel_return'] = $this->url->link('checkout/checkout', '', 'SSL');
Και προσθέτουμε ακριβώς μετα :

Code: Select all

$this->data['charset'] = "utf-8";
Και όσο και για τις ρυθμίσεις στο Paypal:

1) My account -> Profile
2) My selling tools -> More selling tools (PayPal button language encoding)
3) Click στο "More options"
4) Επιλέγουμε "UTF-8" και στις 2 επιλογές και πατάμε save.

New member

Posts

Joined
Fri Jun 17, 2011 10:46 pm
Who is online

Users browsing this forum: No registered users and 5 guests