Integrate Payment Gateway in Phpfox - phpfox

I'm new to phpfox, I'm developing a payment module. Can anyone help me with the payment module? I have a zaakpay payment integration kit and i have all the necessary inputs. How should i need to integrate? Should need to do like paypal and 2checkout(they have written all the source code in library files) or should need to develop a new module ? Thanks in advance

When developing for PhpFox it is best to follow their conventions. When we have a library that needs to be added we add it to the library section:
/include/library/
So for your project it would be something like this:
/include/library/zaakpay
Than you will want to use the admincp to create a product first and then a module for your product.
http://example.com/admincp/product/add/
http://example.com/admincp/module/add/
All your code for your module will live in the module directory, I use payment as an example.
/module/payment
When you are developing your module you will need to refer to the other modules for examples of class names and file structure. It is a very strict convention.
PhpFox module settings are stored in the database, so it is very important to setup the modules correctly using the admincp. This will allow you to export your product, and have all the settings exported as well. You export your product from the admincp.
http://example.com/admincp/product/
The settings for your module will be in an xml file here:
/include/xml
The xml file only exists in the exported package, and it provides you the ability to install your product on another site. For example if you develop the code locally and want to move it to the production site.

Related

Magento custom model override

I'm new to Magento, so forgive my lack of knowledge. I am following a tutorial to integrate the contacts in Magento and import it to SugarCRM. The tutorial changes the core functions of Magento, but I would like to write a module and leave the core intact. I can easily find information about overriding controllers, models, helper, etc. But I have a question.
Imagining, for example, each time a user registers on my website, his contact information is exported to SugarCRM. In the save contact phase, in my module I know that I can write a specific code and tell that it would need to be run after or before some specific core-functions of Magento are done to save the contacts.What I really don't understand is, how will Magento know that I have a module that will perform me certain actions when I'm creating a new account?
The way magento handle this is by using events/observers. For instance, if you needed to send order information to another system after an order has been placed, you could create a custom module which observe sales_order_place_after.
Read more # http://codemagento.com/2011/04/observers-and-dispatching-events/
To get a list of events see https://magento.stackexchange.com/questions/153/where-can-i-find-a-complete-list-of-magento-events
For how to create an module with observer see https://stackoverflow.com/a/12696681/1191288

File location of phtml file of backend admin page

I installed an extension to add custom fields to customer registration form.I want to add some option value in dropdown menu box of input validation in backend admin page..could you plz tell me the path of the folder where can I find the phtml file which is responsible for that part ?
-Thanks.
The files you are looking for are in:
app/design/adminhtml/default/default/template
But just changing the .phtml file won't do the job. The customer model itself should be extended to provide for your extra field. Therefore i highly recommend you to write a module for this instead of altering Magento core code. This to make sure that you can still use updates in the future.
Writing such an module requires more in depth knowledge of Magento. For more information on custom adminhtml see here.
For information on extending the core functionality look here.
If you don't feel like programming this all yourself take a look at customer attribute modules on Magento Connect.

Multistore, template code from code/local/

I'm prepare a multistore on magento.
I have a three template, and I was change a few file from code/core and replace in code/local, but only one template take a changing code from code/local
a rest template should take file from code/core/
Now every template take files from code/local/
How can I'm set app to resolve a problem
thx for help
You should NOT overwrite core files in local. Better try to develop your own module which rewrites the core functionality. In this module you can integrate a configuration, so it's only used for one store view, and not for all.

can i use pyroCMS for multilanguage, and multiuser project?

I need 1 suggestion, This is best platform for my question so i post here.
I think i will use PyroCMS for my new project.
Project has following features:
Multilagnguage in front end
User management
super Admin, country admin, advertisement admin
In frontend users export_type and import_type.
Can i use PyroCMS for this project? I need to make fast develop this. or can i do with core?? what you suggest.
I am bigner in PyroCMS, but i am good in Codeigniter.
Thanks in Advance :)
Looking at your project features:
Multilingual in front end - PyroCMS has built in multilingual support.
User management - Yup, you can extend Users Module as per your need
And use Groups Module to create respective (super Admin, country admin, advertisement admin) authentication hierarchy.
In frontend users export_type and import_type - can you clarify it further ? if it's about user type (Groups Module as I mentioned in 3) - it's doable.
Can i use PyroCMS for this project?
Definitely. PyroCMS would be perfect base for your project and will help you build your project at speed. The more I look into PyroCMS the more I feel like it's Codeigniter made easier. Also, Pyro community is very supportive.
Check these links:
To understand PyroCMS basics, module structure and module development: http://bhu1st.blogspot.com/2010/09/hello-world-pyrocms-module.html
Pyro - Theming, Module & Widget Creation guide and sample code: http://echo.semicolondev.com/
Also the multilingual solution for pyro is that you make multiple subdomains for each language and make multiple sites. Which is problem if you want to share the user database. One domain multilanguage site is a little more dificult but also possible. You can read more about it in this post: https://www.pyrocms.com/forums/topics/view/16237
Despite this i also suggest Pyro for the project and for others also :)
In the pyro modules you can have roles which set the permissions, using this along with a users helper you can then have in your module
if(user_has_role('super_user')){
// do stuff
}
Sample module : https://github.com/pyrocms/sample
http://docs.pyrocms.com/2.1/manual/developers/addons/modules/basic-structure

How to create a DotNetNuke installation package with custom data, modules, and skins

I have a need to create my own DNN installation package that will include my custom modules and skins along with pages and sample data. Is there a way to do that?
You can setup the site how you want it (with the pages and sample data), and then Export a Portal Template from the Host -> Portals/Sites page.
Then, when you create a new site, add that template to the Portals/_default folder (alongside Default Website.template), and you can select that template when installing the site. Make sure that you also include the packages for your custom modules and skins in the corresponding folder (Module or Skin) in the Install folder.
In terms of sample data, only data in "portable" modules will be included in the template. This includes the HTML module. If you need sample data to come along with your custom modules, your business controller class will need to implement IPortable.

Resources