Search the Community
Showing results for tags 'Request'.
-
Hi, I'm developing an external payment module in localhost. I'm new to prestashop 1.7 and I'm stuck at one place. I have made the module. Please shed some light on this fellow beginner. Actually I made the payment module but still not able to redirect successfully to payment url and order is not being generated. After that I need to show the response status based on transaction. what's the correct way to write response status of the payment made on gateway page? I'm really badly stuck with this for a couple of days now. It would be really helpful if you could look at what I might be doing wrong or missing out? I have attached some screenshots of my module file and controller . Thanks in advance! Please guide me 🙏 Any help will be much appreciated. Thanks in advance.
- 4 replies
-
- prestashop1.7
- paymentmodule
-
(and 4 more)
Tagged with:
-
Bonjour, J'essaie de faire une requête SQL qui permet de lister toutes les commandes avec les noms des produits commandés par client. ça marche, mais la requête m'affiche qu'un seul nom de produit quand il y a plus d'un produit commandé. Si on part du principe qu'un client achete 2 produits dans la même commande, comment afficher tous les produits et non qu'un seul ? Voici la base de ma requête SQL : SELECT d.id_order, o.date_add, CONCAT_WS(' ', g.firstname, g.lastname) AS customer, os.name AS state, d.product_name, d.product_reference, d.product_quantity AS order_placed, ROUND(Count(d.id_order) / 2) AS product_quantity, total_paid, o.payment, a.vat_number AS vat_number, c.name AS carrier_name, CONCAT_WS(' ', a.lastname, a.firstname, a.address1, a.address2, a.postcode) AS address_delivery, CONCAT_WS(' ', a.lastname, a.firstname, a.address1, a.address2, a.postcode) AS address_invoice, REPLACE(IFNULL(GROUP_CONCAT(cd.value), ''), '"', '\'') AS customized_data FROM ps_order_detail d LEFT JOIN ps_orders o ON (d.id_order = o.id_order) LEFT JOIN ps_customer g ON (o.id_customer = g.id_customer) LEFT JOIN ps_carrier c ON (o.id_carrier = c.id_carrier) LEFT JOIN ps_order_state_lang os ON (o.current_state = os.id_order_state) LEFT JOIN ps_address a ON (a.id_address = o.id_address_delivery) LEFT JOIN ps_address ab ON (ab.id_address = o.id_address_invoice) LEFT JOIN ps_customization cu ON (cu.id_cart = o.id_cart) LEFT JOIN ps_customized_data cd ON (cd.id_customization = cu.id_customization) WHERE o.date_add BETWEEN '2023-02-01' AND '2023-03-01' GROUP BY d.id_order ORDER BY d.id_order DESC Merci pour votre aide.
-
Hello All, Module to separate people by country, if the visitor's country is for example France, and the visitor has already made 100€ turnover, automatically start to see the products with a reduced price of -10%, if the visitor has made a turnover of 200€, to get an even greater reduction of products of -20% of the price. My version of prestashop is: 1.6.1.20 If someone can do this module, how much money would it cost me ? Best regards: Dani
-
Hi, Is there any plugin available, for tax reasons I need to add multiple tracking numbers in orders with more than 1 item - as some items I dispatch from overseas, while the rest are local, so for tax/vat purposes I need to make sure this is recorded (I can find these by sorting the orders/products with certain tracking numbers to reconcile). E.G. Order #150 - Item A (sent from CHINA warehouse) - Item B (sent from UK warehouse) Set Item A's tracking number: UKXXX555 Set Item B's tracking number: CNXXX555 If an order has multiple items but all items are stocked in UK = only need one tracking number. Are there any modules that will help me do this? Set more than one tracking number per order (ideally set a tracking number for each item in the order??) Please and thank you! If I can't find this I think I will have to say farewell to PrestaShop, it is vital for me to move forward without getting fined by HMRC ..
-
Hi Guys, I am using Prestashop 1.7 and I created custom admin module controller class. What is the proper way to call a method inside my controller using AJAX request? For example: class AdminFooBarController extends ModuleAdminController { public function ajaxProcessGetBar() { return 'foo'; } } and in the backoffice template I have: $.ajax({ type: 'POST', cache: false, dataType: 'json', url: 'ajax-tab.php', // not sure about this part data: { ajax: true, controller: 'AdminFooBar', action: 'GetBar', token: token }, success: function (data) { // something magical } }); I can't seem to get it work. Thanks
-
Hola, en mi empresa tenemos un prestashop 1.6.1.24 y desde hace unos días tenemos unos problemas. Todo empezó al restaurar un backup. Tenemos un template Tema JMS 4Life donde nos deja cambiar la portada con un page builder, y ahora cada vez que la intento cambiar me dice que: Request Entity Too Large The requested resource does not allow request data with POST requests, or the amount of data provided in the request exceeds the capacity limit. Ya augmentamos el límite a tope. y antes del backup esto no pasaba. Reiniciamos servidor, cambiamos valores... pero nada.... Alguna idea??? Saludos Marc
-
Hi! I was wondering if there's a module that allows me to notify the clients when a product that is out of stock, arrives. The problem is, additional to the previous information, I'd like the module to notify me as a store, what products and how many times the customers asked for each one of it. I've only found modules that notify the customer, but there's no record of what products where asked nor the times they did the requests of the "notify me when arrives" I hope someone can help me with this information. Thank you very much Kind regards, Practicante Kios
-
Hey together, In our company we want to use PrestaShop as online shop system. But we also have an ERP-System which also needs customers, addresses and orders. Therefore i have to synchronize the data. First i thought that i just request all data via webservice calls. But this would mean i have to implement polling which is a 'dirty' solution in my opinion. Is there any module or another possible solution that exports the data everytime when new data is inserted or existing data is changed / deleted? I'm very new to PrestaShop. Maybe somebody could help me Thanks in advance Best wishes Andi
-
Hello everyone, I am getting the following error when trying to edit products in backend of my shop. I have in total 5160 articles through CSV imported with their combinations also. It has been working when there were less products. Does it have something to do that are so many articles in my store ? What can I do to solve it ? I tried to clear cache. Also to enable debug mode. After enable of debug mode I couldnt reach the backend of my store because of some errors of php, so I turned it off. Thank you in advance!
- 11 replies
-
- presta1762
- server error
- (and 6 more)
-
Zdravím komunitu, mal by som takú otázku, z dôvodu chybových hlášok by som potreboval pozrieť parametre HTTP Request s parametrami GET a POST. Možno je to triviálne, ale ako na to? Zatiaľ som sa tým ešte nestretol, prevažne sa venujem inej platforme. Ďakujem🙂
-
Hi all ! I'm trying to import some products to my prestashop using REST webservice. The problem is when I try to add a product to an empty category I created using webservice or using PS web interface, I get the following response: <error> <code><![CDATA[135]]></code> <message><![CDATA[You cannot set a position greater than the total number of products in the category, minus 1 (position numbering starts at 0).]]></message> </error> It occurs with the first product. If I add it via web interface and I add the others using webservice, it works. XML: I've already read this topic http://www.prestashop.com/forums/topic/347750-solvedcant-add-product-to-empty-category-using-webservice/ but the solution is not really a solution so does anyone have an idea about this issue ? Thanks for your answers
-
in version 1.6.1.17 have one problem with the XML request of WebService (Others with same version works fine). All Request have BOM UTF8 characters () in my opinion the problem is in Prestashop Config or Apache/php config. Someone know something? sorry if this is not the correct topic Regards, 22.xml
-
Hello, I'm making a PrestaShop eCommerce for a client who sells sunglasses. My problem is that some of those glasses are graduated glasses and I need tu activate an obligatory personalization (something like "upload your eye medical prescription") when the customer selects the "with graduated glasses" combination. Right now I can only add a "requested personalization" field to a product for all combinations, so I had to create every product twice: one with graduated glasses and requested personalization field, and another one with regular glasses without it. Can you suggest (or make) a module to achieve that? Thank you. btw the website is codesunglasses.it
-
Bonjour, J'ai remarqué dans le request header de mes requêtes que le cookie Prestashop était assez important jusqu'à provoquer(sur chrome) un http 400 request too long. Est-il nécessaire de "clean" les cookies définis par nos soins avant de les modifier ? Utiliser une fonction update ? Ma méthode : $this->context->cookie->moncookie = 'value'; Est-ce correct ? Après investigation il apparait que la cause soit le cookie de ps_analytics ga_cart qui grossit au fur et à mesure que l'on ajoute des produits différents au panier. Et qui fait planter les cookies à un moment. Avez-vous une solution autre que désactiver google analytics ? Merci.
-
module [Request] Module product suggestion test
Maeva posted a topic in Looking for a module or a theme
Hi, I want to create a personalized test integrated in my website. This test has to suggest a product to the user based on his answers. Have you developed something similar? Thank you in advance. -
Hi, I'm trying to override the fetch function of WebserviceRequest.php file. But when I override it, when I use the webservice doesn't work. Can anyone help me to solve this? How can I override the fetch function? I've tried this... class WebserviceRequest extends WebserviceRequestCore { public function fetch($key, $method, $url, $params, $bad_class_name, $inputXml = null) { parent::fetch($key, $method, $url, $params, $bad_class_name, $inputXml = null); myfile = fopen("method.txt", "a") or die("Unable to open file!"); $txt = "Metodo:\n".$this->method; fwrite($myfile, $txt); fclose($myfile); } } Thanks in advance.
-
- override
- webservice
-
(and 3 more)
Tagged with:
-
Hi there. I am struggling with the words to describe this. I have a few coasters I would like to sell, if a customer orders 4 of any of them they will get a discount. Right now I can only find the rule which allows for 4 of 1 product to get the discount. I guess my question is, is it possible to set up a rule that allows you to buy multiple coasters and if the total reaches 4 then you would get a discount? Any help would be greatly appreciated. Thanks!
-
Hi everyone. I'm new in this forums, thanks for reading. I've tried the prestashop webservice using the php example script located in the documentation and i've read it all. It's really easy and works great. But now i'm trying to use the webservice via cURL command line client. i managed to make GET, PUT, and DELETE requests but when i try to make a POST request i get a HTTP/1.1 500 Internal Server Error. This is the command i launch: curl -v -X POST -H "Content-type:text/xml" --data-urlencode @cnew.xml "http://JXDLSL4MTV0GLFFNIMC4H35L4DV93IYP:@192.168.1.3/prestashop/api/customers/" I use -v for verbose. I get this: * About to connect() to 192.168.1.3 port 80 (#0) * Trying 192.168.1.3... connected * Connected to 192.168.1.3 (192.168.1.3) port 80 (#0) * Server auth using Basic with user 'JXDLSL4MTV0GLFFNIMC4H35L4DV93IYP' > POST /prestashop/api/customers/ HTTP/1.1 > Authorization: Basic SlhETFNMNE1UVjBHTEZGTklNQzRIMzVMNERWOTNJWVA6 > User-Agent: curl/7.21.7 (i386-pc-win32) libcurl/7.21.7 OpenSSL/0.9.8r zlib/1.2 .5 libidn/1.18 libssh2/1.2.8 librtmp/2.3 > Host: 192.168.1.3 > Accept: */* > Content-type: text/xml > Content-Length: 989 > < HTTP/1.1 500 Internal Server Error < Date: Fri, 22 Jun 2012 08:59:59 GMT < Server: Apache/2.2.21 (Win32) mod_ssl/2.2.21 OpenSSL/1.0.0e PHP/5.3.8 mod_perl /2.0.4 Perl/v5.10.1 < X-Powered-By: PrestaShop Webservice < Access-Time: 1340355599 < PSWS-Version: 1.4.7.0 < Execution-Time: 0.016 < Content-Length: 241 < Connection: close < Content-Type: text/xml;charset=utf-8 < <?xml version="1.0" encoding="UTF-8"?> <prestashop xmlns:xlink="http://www.w3.org/1999/xlink"> <errors> <error> <message><![CDATA[internal error. To see this error please display the PHP error s.]]></message> </error> </errors> </prestashop> * Closing connection #0 The content of cnew.xml file is a new customer: <?xml version="1.0" encoding="UTF-8"?> <prestashop xmlns:xlink="http://www.w3.org/1999/xlink"> <customer> <id></id> <id_default_group></id_default_group> <newsletter_date_add></newsletter_date_add> <ip_registration_newsletter></ip_registration_newsletter> <last_passwd_gen></last_passwd_gen> <secure_key></secure_key> <deleted></deleted> <passwd></passwd> <lastname>Ñoréz</lastname> <firstname>Trinitarió Fúlgencio</firstname> <email>[email protected]</email> <note></note> <id_gender></id_gender> <birthday></birthday> <newsletter></newsletter> <optin></optin> <active>1</active> <is_guest></is_guest> </customer> </prestashop> If I use --trace-ascii instead of -v: curl --trace-ascii err.txt -X POST -H "Content-type:text/xml" --data-urlencode @cnew.xml "http://JXDLSL4MTV0GLFFNIMC4H35L4DV93IYP:@192.168.1.3/prestashop/api/customers/" I get a err.txt file with more information. This is its content: == Info: About to connect() to 192.168.1.3 port 80 (#0) == Info: Trying 192.168.1.3... == Info: connected == Info: Connected to 192.168.1.3 (192.168.1.3) port 80 (#0) == Info: Server auth using Basic with user 'JXDLSL4MTV0GLFFNIMC4H35L4DV93IYP' => Send header, 308 bytes (0x134) 0000: POST /prestashop/api/customers/ HTTP/1.1 002a: Authorization: Basic SlhETFNMNE1UVjBHTEZGTklNQzRIMzVMNERWOTNJWVA 006a: 6 006d: User-Agent: curl/7.21.7 (i386-pc-win32) libcurl/7.21.7 OpenSSL/0 00ad: .9.8r zlib/1.2.5 libidn/1.18 libssh2/1.2.8 librtmp/2.3 00e5: Host: 192.168.1.3 00f8: Accept: */* 0105: Content-type: text/xml 011d: Content-Length: 989 0132: => Send data, 989 bytes (0x3dd) 0000: %3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%0 0040: A%3Cprestashop%20xmlns%3Axlink%3D%22http%3A%2F%2Fwww.w3.org%2F19 0080: 99%2Fxlink%22%3E%0A%3Ccustomer%3E%0A%09%3Cid%3E%3C%2Fid%3E%0A%09 00c0: %3Cid_default_group%3E%3C%2Fid_default_group%3E%0A%09%3Cnewslett 0100: er_date_add%3E%3C%2Fnewsletter_date_add%3E%0A%09%3Cip_registrati 0140: on_newsletter%3E%3C%2Fip_registration_newsletter%3E%0A%09%3Clast 0180: _passwd_gen%3E%3C%2Flast_passwd_gen%3E%0A%09%3Csecure_key%3E%3C% 01c0: 2Fsecure_key%3E%0A%09%3Cdeleted%3E%3C%2Fdeleted%3E%0A%09%3Cpassw 0200: d%3E%3C%2Fpasswd%3E%0A%09%3Clastname%3E%C3%91or%C3%A9z%3C%2Flast 0240: name%3E%0A%09%3Cfirstname%3ETrinitari%C3%B3%20F%C3%BAlgencio%3C% 0280: 2Ffirstname%3E%0A%09%3Cemail%3Etrini%40nor.ez%3C%2Femail%3E%0A%0 02c0: 9%3Cnote%3E%3C%2Fnote%3E%0A%09%3Cid_gender%3E%3C%2Fid_gender%3E% 0300: 0A%09%3Cbirthday%3E%3C%2Fbirthday%3E%0A%09%3Cnewsletter%3E%3C%2F 0340: newsletter%3E%0A%09%3Coptin%3E%3C%2Foptin%3E%0A%09%3Cactive%3E1% 0380: 3C%2Factive%3E%0A%09%3Cis_guest%3E%3C%2Fis_guest%3E%0A%3C%2Fcust 03c0: omer%3E%0A%3C%2Fprestashop%3E <= Recv header, 36 bytes (0x24) 0000: HTTP/1.1 500 Internal Server Error <= Recv header, 37 bytes (0x25) 0000: Date: Fri, 22 Jun 2012 08:32:26 GMT <= Recv header, 99 bytes (0x63) 0000: Server: Apache/2.2.21 (Win32) mod_ssl/2.2.21 OpenSSL/1.0.0e PHP/ 0040: 5.3.8 mod_perl/2.0.4 Perl/v5.10.1 <= Recv header, 37 bytes (0x25) 0000: X-Powered-By: PrestaShop Webservice <= Recv header, 25 bytes (0x19) 0000: Access-Time: 1340353946 <= Recv header, 23 bytes (0x17) 0000: PSWS-Version: 1.4.7.0 <= Recv header, 23 bytes (0x17) 0000: Execution-Time: 0.015 <= Recv header, 21 bytes (0x15) 0000: Content-Length: 241 <= Recv header, 19 bytes (0x13) 0000: Connection: close <= Recv header, 38 bytes (0x26) 0000: Content-Type: text/xml;charset=utf-8 <= Recv header, 2 bytes (0x2) 0000: <= Recv data, 241 bytes (0xf1) 0000: <?xml version="1.0" encoding="UTF-8"?>.<prestashop xmlns:xlink=" 0040: http://www.w3.org/1999/xlink">.<errors>.<error>.<message><![CDAT 0080: A[internal error. To see this error please display the PHP error 00c0: s.]]></message>.</error>.</errors>.</prestashop>. == Info: Closing connection #0 I've tried several "-H" options (headers) like: -H "Content-type:text/xml" and -H "Content-type:application/x-www-form-urlencoded" but I always get HTTP/1.1 500 Internal Server Error Can anybody help me PLEASE? Thanks in advance!!! -- Pamela Curts
- 8 replies
-
- webservice
- http
- (and 8 more)
-
Hi all, I wonder how does connections and connections sources works? Where the data saving is triggered? I need these informations (both referer and request_uri) because I need to know if an order was made after the customer as arrived to the ecommerce through Adwords adv. Sometime happens that Adwords (or Analytics) records an order (through a javascript placed in order-confirmation page), but there're no connection sources in prestashop linked to that order nor the customer that made the order. I have made some test orders but, obviously, everything works as expected and everything was tracked. Thanks, Davide P.S. If you have any other tips on how to record the referer and request_uri for that purpose let me know
- 3 replies
-
- connection
- connections
-
(and 8 more)
Tagged with:
-
Hello, I am looking for a module which allows me to categorize product features in back office and I am wondering why Prestashop is not having this function as default. What I mean: You can create a bunch of features in Catalog -> Product features but they're in one category available for every product in shop. Well, if You have small shop with a little wariety of products thats ok, but in many shops there is 100 features and more. This becomes very annoying to search through all of them and sometimes a lot of employees is forgeting to fill out proper fields. This could be avoided if there will be a module which allows me to create a categories of features from all availables features and assign them to specifc categories of products. Only the features that I've choosen for this category will be shown on the list. How it should work? You have to save product before you can choose a category. After that if You will choose category then ajax request will check if there is a list prepared for this category and filter the features tab. If not - show all of them. I think that this module is really must have for prestashop and a lot merchants will buy it so if someone wants to develop it then I will buy it and probalby a lot other merchants as well. Any informations will be very handy - I was searching for a long time but I couldn't find any simple solution. _________________________________________________________________________________________________ EDIT: I FOUND IT! http://addons.prestashop.com/en/19272-features-on-categories.html but it is quite expensive
-
First of all guys, I want to tell everyone I've checked all similar posts here and in other websites, and that I'm my own host. I work in a place where we got our own servers and we got our own configs. The thing is I just joined them and I'm a novice. I'm not yet working for them. I'm just learning, and I'm supposed to learn "alone" or from the internet, and here is where you guys come in. Whenever I go into the module blocks translations and try to change and then save something, I got the following error: Request Entity Too Large The requested resource /bike/prestashopbo/adminshop/index.php does not allow request data with POST requests, or the amount of data provided in the request exceeds the capacity limit. What I did is to go the plesk that we've got, (Like a Control Panel), I went to the PHP Config and I switched the "memory_limit", the "post_max_size" and the "upload_max_filesize" to high values like "2048M","500M","250M" for example. I even tried higher values and a "-1" memory_limit which means Infinite. The thing is I still keep getting the error, don't understand what's happening. Any ideas? Thanks in advance,
-
Bonjour à tous, J'ai acheté et installé le module ATOS SIPS à 240 euros depuis le site addons.prestashop. Je tourne en rond depuis 24H pour trouver la solution à ce paiement e-transactions du Crédit Agricole. J'ai une boutique en 1.4.7.0 et le module ATOS SIPS v2.3. Pour faire simple : - Dans le panneau de configuration, le contrôle de l'ID Marchand, pathfile, parmcom et certif est vert. Le safe_mode est bien désactivé et la fonction exec() est quant à elle bien active. - Les fichiers certif.fr.xxxxx, parmcom et parmcom.etransactions semblent clean. (Par contre, le chemin spécifié aux fichiers me semble bizarre : mnt/webd/... etc..) - Après avoir essayé de renommer un par un les fichiers binaires fournis (4 fichiers request et 4 fichiers response) afin de tous les essayer, d'avoir passé tous les fichiers en CHMOD 755, CHMOD 750, CHMOD 705, CHMOD 744 et CHMOD 777, rien ne fonctionne.. Toujours le même message d'erreur à l'étape de paiement sur la Boutique, sous le paiement par Carte bancaire : "Erreur Atos : impossible d'exécuter le binaire". J'ai installé le module de toutes les façons : - par le biais du BO Prestashop, - puis par FTP, - puis par BO Prestashop avec transfert des fichiers binaires en mode binaire, - directement en FTP pour le module et en mode binaire pour les fichiers du dossier bin). Résultat ? Toujours rien ! En tout sincérité, payer 250 EUROS un module CERTIFIÉ PRESTASHOP (pensant avoir l'esprit tranquille quant à la pleine compatibilité de ce dernier) pour se retrouver avec un module qui s'installe et semble se paramétrer d'une grande facilité (vu la notice) mais qui ne fonctionne pas à l'arrivée, c'est vite démoralisant... Merci à vous de prendre en considération ma demande, je suis tout ouï à vos propositions de solutions.. Si vous voulez plus de précisions, n'hésitez pas ! Si vous pouvez m'aider..
- 13 replies
-
- bin
- impossible
- (and 8 more)
-
Hi guys i'm trying to add a new product via web services using the PSWebServiceLibrary, i tried to read other posts in this forum but i have problems. That's my code: function AddProduct($root_path, $authentication_key, $id, $name, $desc, $cat, $qta, $price){ try{ $webService = CreateWebServer($root_path,$authentication_key); $xml = $webService->get(array('resource' => 'products?schema=synopsis')); }catch(PrestashopWebserviceException $ex){ echo $ex->getMessage(); return -1; } $resources = $xml->children()->children(); unset($resources->position_in_category); unset($resources->manufacturer_name); $resources->price = floatval($price); $resources->quantity = intval($qta); $resources->link_rewrite->language[0][0] = str_replace(' ','-',$name); $resources->name->language[0][0] = $name; $resources->description->language[0][0] = $desc; $node= dom_import_simplexml($resources->description->language[0][0]); $no = $node->ownerDocument; $node->appendChild($no->createCDATASection($desc)); $resources->associations = ''; //echo $xml->asXML(); try{ $opt = array('resource' => 'products'); $opt['postXml'] = $xml->asXML(); $xml = $webService->add($opt); } catch(PrestaShopWebserviceException $ex) { echo $ex->getMessage(); } return 0; } When I run this funcion it gives me error: I think there's a sort of problem with the "required=true" parameters, but i don't know what to do. Thanks.
-
Hi, I know is possible to change the module to include the Instagram URL, like discribed here. But can you please think to add it in the offical module? Thanks, José Teixeira
- 2 replies
-
- Prestashop 1.6
- PS 1.6
- (and 6 more)
-
Bonjour, D'un coté j'ai mon fichier Excel avec mes stocks produits à jour. De l'autre j'ai mon site avec les mêmes produits. Je fais 4 fois par semaine une mise à jour du stock à travers un import CSV basé sur la référence produit. C'est long et fastidieux. Je voudrais faire une page PHP stockée sur le site que je pourrais appeler et qui mettrait à jour le stock d'un produit en particulier. Je passerais à cette page internet PHP la référence produit que je désire changer et le stock à mettre à jour. La page PHP récupère les paramètres (ref et stock) passés dans l'url, recherche le produit et mets à jour le stock de la fiche produit... Quelqu'un pourrait m'aider sur le code ? Je pourrais utiliser le webservice mais c'est tres lent et je dois faire la mise à jour de 10000 produit tous les jours :-( Merci pour vos conseils/aide Romuald
- 4 replies
-
- mise à jour
- fiche produit
-
(and 3 more)
Tagged with: