Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [http-request]

HTTP Request is a message within a request/response sequence, according to HTTP specification. May also refer an HttpRequest class in software frameworks and libraries that automates relevant functionality

0
votes
1answer
16 views

What to replace deprecated Class 'Zend_Rest_Client' with in Magento 2.3?

A module I'm maintaining is not working on Magento 2.3 since Magento apparently deprecated Class 'Zend_Rest_Client' . I don't see any replacement Client listed in their documentation, so I'm a bit ...
0
votes
6answers
135 views

Magento 2 increase site speed

Magento 2 website speed very slow as per https://developers.google.com/speed/pagespeed/insights/ Result of site:- Reduce server response times (TTFB) - 1.68 s JavaScript execution time - 2.9 s ...
3
votes
2answers
64 views

set x-frame-options in custom controller magento2

I have a custom controller with below code. namespace Vendor\Module\Controller\Service; class Login extends \Magento\Framework\App\Action\Action{ protected $_storeManager; protected $_customerFactory;...
3
votes
1answer
56 views

How to avoid using php://input?

I have a POST endpoint that receives a JSON payload. I'm using the Magento\Framework\App\Request\Http class to try and retrieve my POST data. If I run $data = $this->request->getPost();, ...
0
votes
0answers
191 views

site - is currently unable to handle this request Http error Magento 1.9

This page isn’t working www.abc.com.au is currently unable to handle this request. HTTP ERROR 500. In this site we use Magento 1.9
2
votes
2answers
21 views

In CRUD, Why delete item operation is preferred via POST request rather than GET request?

Is there is any special security advantages of using a POST request over GET request for delete operation? As Magento 2 has preferred POST for delete operation.
1
vote
1answer
155 views

Disable\Remove Custom Product Attribute

When I do a GET request on a product, M2 returns some custom attributes that I have no interest in, such as 'is_recurring'. Is it possible to 'disable' a custom attribute so it does not appear in ...
0
votes
1answer
37 views

Set up Controller for AJAX

I am currently developing a new module for my company on Magento 2.1.8. The module requires the use of AJAX on the front end to send a receive data. This is what i currently have in one of my ...
0
votes
1answer
250 views

URL - Http Post Request with AJAX

I am developing a new module for my company in **Magento 2** and i require an AJAX Http post request, however I cannot find the correct URL. I have all of my controllers currently set up however, ...
2
votes
1answer
286 views

Generate Adminhtml Controller url with get parameter in Block

I have a controller for adminhtml area like this: namespace Namespace\Module\Controller\Adminhtml\Order; use Magento\Framework\Controller\ResultFactory; use Magento\Sales\Model\Order; class ...
4
votes
1answer
2k views

Add query parameter to current url in phtml

I want to add query parameter to my current url, I'm getting current url in my phtml like this: $current_url = $this->getUrl('*/*/*', ['_current' => true, '_use_rewrite' => true]); I want ...
0
votes
0answers
1k views

GET headers in file_get_contents()

To use API i have to send proper request. API documentation says that to receive information send request like this: GET https://www.stuller.com/api/v1/products?SKU=IOLITE-GEN:117417:G HTTP/1.1 ...
1
vote
0answers
585 views

Magento : Calling SOAP API on Local Server Returning HTTP Bad Request

I created SOAP API on my magento website and it's working correctly on live server. But now I need to using those API in another server machine at local environment (local machine with IIS7) and for ...
0
votes
2answers
590 views

Change http to https in magento

getting some error in the console Mixed Content: The page at 'https://www.xxxxx.com/bedroom/beds/beds- without-storage' was loaded over HTTPS, but requested an insecure image 'http://www.xxxxx.com/...
3
votes
1answer
220 views

Serve merged CSS from one url

When I merge CSS it creates 3 merged files, and they are served separately as such <link rel="stylesheet" type="text/css" href="xyz.com/media/css_secure/32733c3332436554dae7e8f320cd2308.css" /> ...
8
votes
3answers
1k views

Magento2: How to check if request is from Web Service?

In Magento 1, We used to check as: if (Mage::getSingleton('api/server')->getAdapter() != null) { // request from Web-Service } How to check the same in Magento2? I didn't find any proper ...
1
vote
0answers
444 views

Magento 2 .htaccses configuration for HTTP get request

I try to get list of modules to localhost with angularJS 2 After i check all code possibilities on angularJS 2 - i need some help with configuration. HTTP GET request with AngularJS 2: import { ...
0
votes
1answer
85 views

trying to write media to another server

i am trying to write media to another server is it possible: i have 2 servers i need to put my magento code on 1st server and want all media on another server when we upload images of catalog, how ...
1
vote
1answer
717 views

usatilea.nextmp.net is currently unable to handle this request

I just moved my site from local to live server it was working fine on local but as its moved over live start giving the error is currently unable to handle this request. This is the domain that i ...
1
vote
0answers
44 views

htaccess redirect, assist please

What i am trying to do is rewrite some URLs and apply SSL on certaing pages on my site. This is the code that i have: RewriteEngine on RewriteBase / RewriteRule ^mylogin$ index.php?view=...
3
votes
0answers
656 views

Magento2 NodeJS: SOAP or REST API?

Does anyone know a good module that can use HTTP VERBS like POST and PUT ?. I tried this one magento2 but only managed to use GET and DELETE ... Hope someone has a few ideas !
1
vote
4answers
5k views

Magento 2 checkout bad request (400)

When I try to checkout by selecting a payment method and click place order button, I get following error message, "message": "An error occurred on the server. Please try to place the order again." ...
1
vote
0answers
61 views

Restrict a controller HTTP Request by Cutomer email and password?

I had a similar question before, but I want to re-structure otherwise now. I want to make something like http://icecat.biz/ In that site, I can access to XMLs with products datasheets, making a HTTP ...
11
votes
5answers
4k views

Magento and HTTP/2 : what is the current status?

As some of you may know, HTTP/2 was recently born. From what I understood, it has been developed to just work with existing websites, which suggests that there is nothing to do to make Magento ...
1
vote
1answer
524 views

Magento 2 Observer not called due to caching?

Intention I am trying to get an affiliate extension to work. The basic concept is that a customer calls the shop-page with a get parameter that is the id of the affiliate partner. The ID will be ...
2
votes
1answer
701 views

Request dispatched by checkout_cart_add_product_complete event is missing data

I have an observer which listens to the checkout_cart_add_product_complete event in Magento (this works correctly) but when I try to access the request data returned by the dispatched event it doesn't ...
1
vote
1answer
1k views

HTTP Problems with Google Fonts

I need to change all of the "http://" to "https://" in a file on my site. I did these steps. By the way, I'm using Magento 1.9.2.4 and a Chromebook - I right clicked on my site and clicked "Inspect". ...
0
votes
1answer
387 views

Redirect all https requests to http except for checkout

I want to redirect all https requests to http on frontend except for checkout. I am using nginx as my web service. Please let me know how can I do this.
3
votes
1answer
2k views

Magento 2 call external REST api

I am trying to call external api from Magento. Below is the request, $client = $this->_httpClientFactory->create(); $client->setUri('thirdpartyurl.com/api/'); $client->setMethod(\...
0
votes
1answer
121 views

saveAction stores empty object

Whenever I fill a form and click "Save", magento doesn't get the form data. It just saves an empty object in the database. I can't figure out why. Here's my form and file structure: Form File ...
4
votes
1answer
1k views

How do I get Http_referer path without “http://localhost/index.php/”?

I want to get the preview page url using: Mage::helper('core/http')->getHttpReferer(); and it get's me something like: http://localhost/index.php/customer/account/ How do I get just : customer/...
2
votes
1answer
736 views

Magento 1: unset a previously set query parameter or reinit the request

So I've made an integration test where my setUp() method add a query parameter to the request like this: Mage::app()->getRequest()->setQuery('entry', 'value'); However, the tests that run ...
6
votes
1answer
2k views

Braintree - 400 Bad Request Message on checkout

I'm setting up Braintree payment In Magento 2 environment through integrated extension provided by Magento. I have compiled the backend form with my merchant data and i selected sandox option to test ...
0
votes
1answer
142 views

Magento Shipping Method

I have created a custom shipping method in Magento but my question how i can call a request from external gateway and read XML data in Magento shipping method .
19
votes
6answers
33k views

Redirect all http:// request to https://

Earlier i have posted this question : https://stackoverflow.com/questions/36104047/how-to-redirect-all-http-requests-to-https-on-magento but didn't get any reaction. Here is my site URL : www.trendy-...
0
votes
1answer
1k views

Varien_Http_Client: getQuery() returns nothing

I'm trying to use Varien_Http_Client for calling external API, here's the code: $httpClient = new Varien_Http_Client(); $httpClient->setUri('https://api-host/api/endpoint'); $...
2
votes
2answers
2k views

retrieving http header info

I use Vladimir Popov(?)'s very nice Webforms extension to enable user submitted custom forms. I want to capture all the http header information from the user who is submitting the form. Vladimir has ...
2
votes
2answers
3k views

Triggering a 404, 500, 503 error in Magento 2

Is there a standard way in Magento 2 to programmatically trigger an HTTP error state and have the system just deal with it? i.e. is there a standard exception we can throw or global method we can ...
1
vote
1answer
255 views

Security Concerns: Sending HTTP Requests from Magento

I am currently developing an extension for Magento. One of the features of this extension is an Observer class that listens for the sales_order_credit_memo_save_after event. This event is fired once ...
4
votes
2answers
310 views

Helper's scope (when getting via Mage::helper())

I'm trying to understand couple of things about helper classes scope and lifetime. I think I got it but it's critical for me to be sure. So can you please tell me if I'm right about the following ...
0
votes
1answer
748 views

remove https from unsecure pages

We are using following configuration for adding https to our site. System > Configuration> Web> secure> Use Secure URLs in Frontend : YES Use Secure URLs in admin : YES it added https to my ...
2
votes
1answer
2k views

Filtering data in magento REST API

I use this API to fetch the visible products using the filter: http://192.168.1.180/magento/index.php/rest/V1/products?searchCriteria[filter_groups][0][filters][0][field]=name&searchCriteria[...
4
votes
2answers
2k views

Getting full image url for products via REST API

After accessing the Rest API (http://192.168.1.180/magento/index.php/rest/V1/products/SKU) to get the product details, the response is something like this: { "attribute_code": "image", "value": "/6/...
4
votes
3answers
10k views

Magento 2: Sending a Custom Header/Response from a Controller

In Magento 2 is it possible, from a controller execute method, to manipulate the request to send a custom header and error page. In Context: We're implementing a small, limited REST API endpoint ...
2
votes
2answers
1k views

Using CURL to call controller action

I am generating an excel report which takes around 10-25mins based on user selection. Page is served to admins only. When user presses export button after selecting filters, I am trying to call ...
8
votes
5answers
9k views

Magento 2: getPost and getPostValue methods on the request object

I see that everywhere where the request is involved in Magento 2, the request is an implementation of \Magento\Framework\App\RequestInterface. This interface does not contain the methods getPost (used ...
1
vote
1answer
3k views

Magento 2 Ajax request fails

I made an ajax request (in the admin html) and got the following response: "{"error":true,"message":"You entered an invalid Secret Key. Please refresh the page."}" new Ajax.Request('...
2
votes
0answers
437 views

Magento + HTTP/2, anyone noticed any issues? [closed]

Since Apache now properly supports HTTP/2, have any of you already tried running it and noticed any improvements and/or issues for Magento 1.9.x.?
0
votes
1answer
130 views

http is not working but https does in magento with https enabled

I am trying to open website on http:// and getting No data received ERR_EMPTY_RESPONSE but with https:// it works. please help me.
4
votes
1answer
2k views

How Magento 2 Routing Works

I need to know how magento 2 Routing Works... I want to know that when we request for any task in magento 2 then how its process to controller... Like I used command line console...' Then how my ...