php - Magento 重定向到订单 View

标签 php magento magento-1.7

我想将用户从我的后端模块重定向到 admin/order_sale/view,但我做不到。当我使用时:

Mage::app()->getResponse()->setRedirect(Mage::helper('adminhtml')->getUrl("admin/sales_order/view", array('id'=>'1'))); 

Magento 正在从 URL 中删除“admin”,因此它看起来像:

http://magento1702.local/index.php//sales_order/view/id/1/key/fdb6089cf1e5cd77f85f085def1a013a/

然后我得到 404 页面。 知道如何以 magento 方式重定向到管理模块吗?

最佳答案

你试过用adminhtml代替admin吗?

Mage::app()->getResponse()->setRedirect(Mage::helper('adminhtml')->getUrl("adminhtml/sales_order/view", array('order_id'=>'1')));

关于php - Magento 重定向到订单 View ,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/12895530/

相关文章:

php - 如何 JOIN 这 3 个表

php - 如何在 PHP 中增加 MySQL 时间戳?

php - 自定义选项未显示在前端 Magento 社区版中

php - Magento 目录搜索索引,无法初始化索引器进程

php - 警告 : mysqli_fetch_array() expects parameter 1 to be mysqli_result, 中给出的对象

PHP CodeIgniter 如何将特定页面上的 Https(SSL) 设置为子域(例如 mypage.domain.com)?

elasticsearch - 共享主机 OutOfMemoryError 中的 Magento 2.4 Elasticsearch 问题

api - Magento 导出订单到 3PL SOAP api 问题

magento-1.7 - CCAvenue 已安装但未在 Magento 中显示

Magento导入产品错误