开发者

Magento - where's the php file subscribe.phtml calls once the form is submitted

开发者 https://www.devze.com 2023-01-13 07:25 出处:网络
When you submit the newsletter subscription form (subscribe.phtml), the form actions aclls a php file. Does anyone know where it is located?

When you submit the newsletter subscription form (subscribe.phtml), the form actions aclls a php file. Does anyone know where it is located?

EDIT: And how can I send the form action to a custom php which does the mail sending bit? for example, I want the form handling to be done by a file called sendmail.php

i'm trying开发者_JS百科 to have something like this - instead if the default action getUrl('newsletter/subscriber/new') ?>">

thanks


Magento is locked into an MVC framework, so replacing the framework code with an arbitrary PHP file is going to be difficult. If you give more details on what you would like to do differently than the core code, we can help you figure out what changes to make.

Thanks, Joe


Shooting from the hip, take a look at this tutorial on how to create a controller. Generally, what you'll be doing here is to create an action that will receive your form post, then execute whatever code you need.

So you'll be defining http://mystore.com/somecontroller/something by creating MyModule_controllers_Somecontroller with a method called somethingAction. With some more detail, I can find you more specific examples.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号