I need to add text fields in Magento OnepageCheckout form. It is not possible to add text fields via admin panel. It is a module installed for one page check out and has its fixed fields so only possible via coding.
I have made changes in
app/design/frontend/base/default/template/onpagecheckout/onepage/billing.phtml which is the exact page I am suppose to make changes in but form displays as previous. I did flush the cache every time but not getting whats going wrong.
Related
I am working on magento 1.9 version.I want to add a custom image field in drop down of custom options.
I added a text field using following guide
http://magento.ikantam.com/qa/how-add-custom-attributes-custom-options
which is working fine.but when I add a file field then it shows in admin but not save image field value in database.
please help me to solve this.
Neeraj,
Did you specifically click "flush cache storage" By following this guide and adding new tables directly to the database, Magento already has this record in cache. By flushing cache storage, you will allow magento to recognize the new structure and be able to save the record. I have accidentally forgotten to do this quite a few times and you end up with the inability to save a record even though your structure is there.
I'm new to magento. I need to give an option to upload the pdf in the add product page.
Just need to give the file upload option with extra field.
I'm using magento 1.7.
Thanks in advance.
There are two ways you can achieve this:
1. Easy one
Create a new product attribute, let's say product_pdf text field, and assign it to some group and attribute set. This field should now reflect in your admin's product page and allow you to save PDF name.
Then make a directory on your Magento (may be in media/pdf) and save all your PDFs if you have. If not, then each time you save the value in Product's custom attribute that we created (product_pdf), also upload the PDF manually at the location you created (media/pdf).
So whenever in frontend you want to show the PDF of product, you will always get the file name from product_pdf attribute and the location should be media/pdf.
2. Difficult/Lengthy one:
Create a file uploader in your Magento Admin's Manage Product screen. Here everything should be in your custom module, from creating a new field to uploading it.
I will not go far, but give you some place where you can exactly know how to go with it: http://www.magentocommerce.com/boards/viewthread/11667/P0/
I am following the instructions here.
I have created a custom field in magento 1.7 CE, registration field called Mobile.
Its working fine i.e, taking input while the time registration,but while click on my account its not showing the value.
All other field’s values are coming e.g., first name last name email.
But not in my mobile filed. It is coming as blank.
I know its for v 1.6. but i made it to work on v1.7 somehow.
Did you flush the backend cache? In magento system > configuration > cache page it is the top right orange button. Magento caches the db structure
When you add customer attributes, Magento's admin dashboard for customer's automatically generates the relative form element for that new attribute.
Is there a way to do the same thing on the front end via a controller in a module?
nope, the frontend customer fields are hard coded, check out the phtml inside customer/form to see it.
What are you trying to achieve? Customer attributes are displayed on the form if "Show on frontend" is enabled. However those fields aren't saved from frontend by default. You need to extend fieldsets in your module for that, see config.xml in core Mage/Customer module
EDIT: actually that is true for enterprise edition, on CE you have to edit register.phtml (preferably by making a copy in your theme)
I’m having a lot of trouble understanding how to create a module that will add an extra button to the shopping cart page. I found lots of info on payment modules and stand-a-lone page modules, but nothing for this.
I simply need to add a button underneath the regular “Checkout” button that can post item data to another website. I’ve created a module but can’t get Magento to recognize it and display the button on that spot. Any help would be greatly appreciated, even just sending me to an existing tutorial that I haven’t been able to find. Thanks.
A custom module is probably overkill for this. Module means a very specific thing in Magento. It's a mechanism for inserting custom code into Magento's standard operations. All you want to do is add a button to the cart page. Editing the file at
./base/default/template/checkout/cart.phtml
(substitute your theme/site name if not using base or default)
is the place you'll want to start looking. Just find the phtml file that corresponds to the place you want to insert your custom HTML and have at it.