Magento 2 add query string to url when redirect to 404 pageMagento Collection addFieldToFilter complicated AND/OR query404 not found in magento2How to fix Magento 2 2.0.0-RC Admin page not found after installationMy Custom Module is redirecting to 404 page in Magento2 CR2Error when editing products on Magento 2Knockout JS custom scope binding404 not found error when new form, controller is addedMagento2, How to pass product data as query string in Url using JSON template? Custom ModuleMagento 2 controller redirect on button click in phtml fileAdd query string to url when redirect to 404 page
90's TV series where a boy goes to another dimension through portal near power lines
Does a druid starting with a bow start with no arrows?
In Romance of the Three Kingdoms why do people still use bamboo sticks when papers are already invented?
Doing something right before you need it - expression for this?
Is "remove commented out code" correct English?
Infinite Abelian subgroup of infinite non Abelian group example
Theorems that impeded progress
Why does Arabsat 6A need a Falcon Heavy to launch
What's the difference between 'rename' and 'mv'?
What is going on with Captain Marvel's blood colour?
Western buddy movie with a supernatural twist where a woman turns into an eagle at the end
If human space travel is limited by the G force vulnerability, is there a way to counter G forces?
Is the Joker left-handed?
How to say in German "enjoying home comforts"
Today is the Center
Brothers & sisters
Can a rocket refuel on Mars from water?
Stopping power of mountain vs road bike
How to take photos in burst mode, without vibration?
Why does Kotter return in Welcome Back Kotter
UK: Is there precedent for the governments e-petition site changing the direction of a government decision?
Why are electrically insulating heatsinks so rare? Is it just cost?
Reserved de-dupe rules
1960's book about a plague that kills all white people
Magento 2 add query string to url when redirect to 404 page
Magento Collection addFieldToFilter complicated AND/OR query404 not found in magento2How to fix Magento 2 2.0.0-RC Admin page not found after installationMy Custom Module is redirecting to 404 page in Magento2 CR2Error when editing products on Magento 2Knockout JS custom scope binding404 not found error when new form, controller is addedMagento2, How to pass product data as query string in Url using JSON template? Custom ModuleMagento 2 controller redirect on button click in phtml fileAdd query string to url when redirect to 404 page
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;
Magento 2 custom module i am trying to add query param
https://test.com/index?id=L_FRR3039-ODKLWG-GP4QPY
if i give above format getting 404 page not found
https://test.com/index?id=L_FRR3039
it working fine
even
https://test.com/index?id=L_FRR3039-ODKLWG_GP4QPY this is also working
it is not taking
-
multiple hyphens remaining all special characters taking
can anyone help me in this
magento2 query https querystring
add a comment |
Magento 2 custom module i am trying to add query param
https://test.com/index?id=L_FRR3039-ODKLWG-GP4QPY
if i give above format getting 404 page not found
https://test.com/index?id=L_FRR3039
it working fine
even
https://test.com/index?id=L_FRR3039-ODKLWG_GP4QPY this is also working
it is not taking
-
multiple hyphens remaining all special characters taking
can anyone help me in this
magento2 query https querystring
Are you trying to get that query param in your custom controller?
– Jeeva Chezhiyan
yesterday
yes, test.com/pawan?id=L_FRR3039-ODKLWG-GP4QPY.
– Pawankumar
yesterday
add a comment |
Magento 2 custom module i am trying to add query param
https://test.com/index?id=L_FRR3039-ODKLWG-GP4QPY
if i give above format getting 404 page not found
https://test.com/index?id=L_FRR3039
it working fine
even
https://test.com/index?id=L_FRR3039-ODKLWG_GP4QPY this is also working
it is not taking
-
multiple hyphens remaining all special characters taking
can anyone help me in this
magento2 query https querystring
Magento 2 custom module i am trying to add query param
https://test.com/index?id=L_FRR3039-ODKLWG-GP4QPY
if i give above format getting 404 page not found
https://test.com/index?id=L_FRR3039
it working fine
even
https://test.com/index?id=L_FRR3039-ODKLWG_GP4QPY this is also working
it is not taking
-
multiple hyphens remaining all special characters taking
can anyone help me in this
magento2 query https querystring
magento2 query https querystring
asked yesterday
PawankumarPawankumar
373318
373318
Are you trying to get that query param in your custom controller?
– Jeeva Chezhiyan
yesterday
yes, test.com/pawan?id=L_FRR3039-ODKLWG-GP4QPY.
– Pawankumar
yesterday
add a comment |
Are you trying to get that query param in your custom controller?
– Jeeva Chezhiyan
yesterday
yes, test.com/pawan?id=L_FRR3039-ODKLWG-GP4QPY.
– Pawankumar
yesterday
Are you trying to get that query param in your custom controller?
– Jeeva Chezhiyan
yesterday
Are you trying to get that query param in your custom controller?
– Jeeva Chezhiyan
yesterday
yes, test.com/pawan?id=L_FRR3039-ODKLWG-GP4QPY.
– Pawankumar
yesterday
yes, test.com/pawan?id=L_FRR3039-ODKLWG-GP4QPY.
– Pawankumar
yesterday
add a comment |
1 Answer
1
active
oldest
votes
Please try this,
Add this in your custom controller contructor.
public function __construct(Context $context,MagentoFrameworkAppRequestHttp $request)
$this->request = $request;
parent::__construct($context);
public function getIddata()
// use
$this->request->getParams(); // all params
return $this->request->getParam('id');
You can get the param using this $this->getIddata(); in you controller file.
it helped for my issue
– Pawankumar
yesterday
If this helped means please accept the answer. It'll helpful for others
– Jeeva Chezhiyan
yesterday
accepted already
– Pawankumar
yesterday
add a comment |
Your Answer
StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "479"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);
else
createEditor();
);
function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);
);
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f268600%2fmagento-2-add-query-string-to-url-when-redirect-to-404-page%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
Please try this,
Add this in your custom controller contructor.
public function __construct(Context $context,MagentoFrameworkAppRequestHttp $request)
$this->request = $request;
parent::__construct($context);
public function getIddata()
// use
$this->request->getParams(); // all params
return $this->request->getParam('id');
You can get the param using this $this->getIddata(); in you controller file.
it helped for my issue
– Pawankumar
yesterday
If this helped means please accept the answer. It'll helpful for others
– Jeeva Chezhiyan
yesterday
accepted already
– Pawankumar
yesterday
add a comment |
Please try this,
Add this in your custom controller contructor.
public function __construct(Context $context,MagentoFrameworkAppRequestHttp $request)
$this->request = $request;
parent::__construct($context);
public function getIddata()
// use
$this->request->getParams(); // all params
return $this->request->getParam('id');
You can get the param using this $this->getIddata(); in you controller file.
it helped for my issue
– Pawankumar
yesterday
If this helped means please accept the answer. It'll helpful for others
– Jeeva Chezhiyan
yesterday
accepted already
– Pawankumar
yesterday
add a comment |
Please try this,
Add this in your custom controller contructor.
public function __construct(Context $context,MagentoFrameworkAppRequestHttp $request)
$this->request = $request;
parent::__construct($context);
public function getIddata()
// use
$this->request->getParams(); // all params
return $this->request->getParam('id');
You can get the param using this $this->getIddata(); in you controller file.
Please try this,
Add this in your custom controller contructor.
public function __construct(Context $context,MagentoFrameworkAppRequestHttp $request)
$this->request = $request;
parent::__construct($context);
public function getIddata()
// use
$this->request->getParams(); // all params
return $this->request->getParam('id');
You can get the param using this $this->getIddata(); in you controller file.
answered yesterday
Jeeva ChezhiyanJeeva Chezhiyan
788724
788724
it helped for my issue
– Pawankumar
yesterday
If this helped means please accept the answer. It'll helpful for others
– Jeeva Chezhiyan
yesterday
accepted already
– Pawankumar
yesterday
add a comment |
it helped for my issue
– Pawankumar
yesterday
If this helped means please accept the answer. It'll helpful for others
– Jeeva Chezhiyan
yesterday
accepted already
– Pawankumar
yesterday
it helped for my issue
– Pawankumar
yesterday
it helped for my issue
– Pawankumar
yesterday
If this helped means please accept the answer. It'll helpful for others
– Jeeva Chezhiyan
yesterday
If this helped means please accept the answer. It'll helpful for others
– Jeeva Chezhiyan
yesterday
accepted already
– Pawankumar
yesterday
accepted already
– Pawankumar
yesterday
add a comment |
Thanks for contributing an answer to Magento Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fmagento.stackexchange.com%2fquestions%2f268600%2fmagento-2-add-query-string-to-url-when-redirect-to-404-page%23new-answer', 'question_page');
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Are you trying to get that query param in your custom controller?
– Jeeva Chezhiyan
yesterday
yes, test.com/pawan?id=L_FRR3039-ODKLWG-GP4QPY.
– Pawankumar
yesterday