window 无大小写区别,所以可以显示表框

Linux 大小写敏感,显示不了

\app\code\community\Company\BabyPay\Model\Payment.php 里定义了form

protected $_code = 'BabyPay_payment';
protected $_formBlockType = 'BabyPay/form';  //大写

/app/design/frontend/default/default/template/BabyPay/ 所以这个文件夹也要大写

  • Magento自定义付款方式形式不显示

标签云

Magento自定义付款方式形式不显示

I wrote a custom payment module. It seems to be working fine but I can't show the method form in the checkout process. I mean: I see my method, I can select it, but can't see the form. I want to show a select box with a couple of options but no form is rendered.

app\code\local\Neurona\Sistarbanc\Block\Form\sistarbanc.php

class Neurona_Sistarbanc_Block_Form_Sistarbanc extends Mage_Payment_Block_Form
{
protected function _construct()
{
parent::_construct();
$this->setTemplate('payment/form/sistarbanc.phtml');
}
....

And the form in app\design\frontend\base\default\template\payment\form\sistarbanc.phtml

Any help will be appreciated!!

EDIT

 

So, it seems to be working in the default ckeckout process but not in the onestepcheckout

EDIT 2

I found that in onestepheckout this is the way the payment method form is rendered:

<?php if ($html = $this->getPaymentMethodFormHtml($_method)): ?>
<dd id="container_payment_method_<?php echo $_code; ?>" class="payment-method" <?php if(!$this->getSelectedMethodCode()==$_code || !($hide_nonfree_methods && $_code == 'free')): ?> style="display:none"<?php endif; ?>>
<?php echo $html; ?>
</dd>

So, for my method $this->getPaymentMethodFormHtml($_method) is FALSE. �0�7why?

2016年10月27日12分02秒

Your template filename is Sisterbanc.phtml, but your block will try to load sisterbanc.phtml (uppercase "s" vs lowercase "s").

2016年10月27日12分02秒

Maybe you need add this line in Model/Payment.php.

protected $_formBlockType = "sistarbanc/form/sistarbanc"

I don't know the reason why though. I compared with other payment module code, and got this.

2016年10月27日12分02秒

 

© 2016 91R.NET 版权所有

magento form.html不显示 window 和 Linux下的区别的更多相关文章

  1. socket在windows下和linux下的区别

    原文:socket在windows下和linux下的区别 1)头文件 windows下winsock.h/winsock2.h linux下sys/socket.h    错误处理:errno.h 2 ...

  2. window和Linux下的软链接

    window下开启软链接命令: mklink /J  "D:\IdeaProjects\bms_work\smartcity_govnet\base_web\target\base_web\ ...

  3. 负载均衡---在window与linux下配置nginx

    最近有些时间,开始接触负载均衡方面的东西,从硬件F5再到Citrix Netscalar.不过因为硬件的配置虽然不复杂,但昂贵的价格也让一般用户望而却步(十几万到几十万),所以只能转向nginx,sq ...

  4. 【转】玩玩负载均衡---在window与linux下配置nginx

    最近有些时间,开始接触负载均衡方面的东西,从硬件F5再到Citrix Netscalar.不过因为硬件的配置虽然不复杂,但昂贵的价格也让一般用户望而却步(十几万到几十万),所以只能转向nginx,sq ...

  5. 玩玩负载均衡---在window与linux下配置nginx

      最近有些时间,开始接触负载均衡方面的东西,从硬件F5再到Citrix Netscalar.不过因为硬件的配置虽然不复杂,但昂贵的价格也让一般用户望而却步(十几万到几十万),所以只能转向nginx, ...

  6. 在Window和Linux下使用Zthread库

    ZThread库是一个开源的跨平台高级面向对象的线性和sycnchronization 库,以运行POSIX 和Win32 系统中的C++程序. ZThread库的主页:http://zthread. ...

  7. 关于File.separator 文件路径:window与linux下路径问题(“No such file or diretory ”异常解决方案)

    最近有个在页面上传Excel文件至服务器指定目录并进行数据校验.最后入库及进行进一步处理的应用情境,我写好代码在模拟环境下测试,完全没问题:但客户试用的时候,却老是报告“No such file or ...

  8. 在Window和Linux下使用Zthread库(跨平台高级面向对象的线性和sycnchronization 库)

    ZThread库是一个开源的跨平台高级面向对象的线性和sycnchronization 库,以运行POSIX 和Win32 系统中的C++程序. ZThread库的主页:http://zthread. ...

  9. 转:socket编程在windows和linux下的区别

    如无其它说明,本文所指Linux均表示2.6内核Linux,GCC编译器,Windows均表示Windows XP系统,Visual Studio 2005 sp1编译环境. 下面大概分几个方面进行罗 ...

随机推荐

  1. Springboot项目全局异常统一处理

    转自https://blog.csdn.net/hao_kkkkk/article/details/80538955 最近在做项目时需要对异常进行全局统一处理,主要是一些分类入库以及记录日志等,因为项 ...

  2. 表空间及段区块的一些sql语句和视图

    查询段情况的语句 select segment_name,blocks,extents,bytes,segment_type,tablespace_namefrom dba_segments wher ...

  3. postman -- token全局变量

    var data = JSON.parse(responseBody);if (data.data.token) { tests["Body has token"] = true; ...

  4. 修改 mvc webapi 默认返回 json 格式

    web api 默认的已 xml 格式返回数据 现在开发一般都是以 json 格式为主 下面配置让 webapi 默认返回 json ,在需要返回 xml 时只需要加一个查询参数 datatype=x ...

  5. php上传大文件1G

    前段时间做视频上传业务,通过网页上传视频到服务器. 视频大小 小则几十M,大则 1G+,以一般的HTTP请求发送数据的方式的话,会遇到的问题:1,文件过大,超出服务端的请求大小限制:2,请求时间过长, ...

  6. CSP2019-S2参赛总结 暨 近期学习反思

    前言 岁月不居,时节如流.眨眼间,2019的联赛就已经落下帷幕了,回忆这一年的学习,有许许多多的事情想写下来.趁联赛结果还未出来,赶紧写下这篇文章,以记录我这段时间的学习和生活. "你怎么又 ...

  7. Fastdfs 单机安装 教程

    分布式存储 CentOS6.5虚拟机环境搭建FastDFS-5.0.5集群 详细的最新版fastdfs单机版搭建 分布式文件系统 - FastDFS 在64位CentOS 下配置安装部署

  8. jsPDF生成pdf文件和中文编码

    jsPDF的简单使用以及中文编码问题的解决 文中js通过CDN引入,若是为了加载时间最好下载至本地. jsPDF的使用 jsPDF简介 jsPDF 是一个基于 HTML5 的客户端解决方案,用于在客户 ...

  9. 安装Dubbo 并且安装注册中心(Zookeeper-3.3.6)

    安装zookeeper 安装Tomcat 载dubbo-admin-2.5.4.war 进入Apache ZooKeeper官方网站进行下载,https://zookeeper.apache.org/ ...

  10. CSS Selectors

    CSS selectors are used to "find" (or select) HTML elements based on their element name, id ...