Questions tagged [magento-1.7]

Magento Community version 1.7

Filter by
Sorted by
Tagged with
75
votes
13answers
78k views

Clearing Magento after testing

I am currently doing a lot of tests in Magento so I can get familiar with it. Unfortunately the database is extremely cluttered with my tests. I wish to clear up the database so I can start over again....
45
votes
5answers
112k views

How to get all items in cart currently?

I want to get a collection of all the items in cart currently. How can I do this ? Any suggestions will be appreciated.
39
votes
11answers
61k views

How to Remove Customer Account Dashboard Links

I want to remove following links in the customer account dashboard left panel? My Applications Gift Registry Reward Points Gift Card Link I'm working in the Magento 1.7 Community Edition. Any ...
32
votes
3answers
18k views

Programmatically Creating Shipments

I came across different ways to create shipment programmatically. They are //Type 1 $converter=Mage::getModel('sales/convert_order'); $shipment=$converter->toShipment($order); ...
29
votes
3answers
31k views

How to implement translations in design template package CSV's? How does echo $this->__('Text') work?

I have a design package setup like so: design/frontend/package_name/theme_name/locale/ under which I have de_DE, en_GB etc, under which I have corresponding translate.csv files with the various ...
29
votes
1answer
27k views

About Collection Model and Resource Model

I am bit confused about using resource model and collection model. Sometimes when I see examples for loading products using specific attributes, in some examples, they use collection model and ...
28
votes
6answers
19k views

Adding columns to customer grid using observer or overriding the customer grid

I am facing an issue of adding a column on customer grid and showing values in that column. Here is the observer code that I have been trying to show the column:- if ($block->getType() == '...
28
votes
5answers
24k views

How to reveal Magento version by code?

I want to know whether there is any class file available for to know the magento version. If the site has been hacked how to to reveal the version? I know there's a way as follows. Mage::getVersion()...
26
votes
13answers
67k views

Remove /index.php from the Magento URL gives 404 error

I am using Magento ver. 1.7.0.2. Here it is the link to my website: http://dev.blokeundees.com.au/ I have to remove the /index.php folder from URLs so I edited the .htaccess file and backend too (...
26
votes
1answer
104k views

Mage::getBaseUrl() vs Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_WEB)

Is there a reason to use Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_WEB) rather than Mage::getBaseUrl()? I've seen both in use, and they both return the same thing. Is the longer one redundant? ...
24
votes
2answers
31k views

Creating a custom helper class in module

I've made a new module called test_helper and I want to create a helper class in this module so that I can add custom functions to be called all over my site. I can't however seem to find any ...
23
votes
6answers
33k views

Permanent solution for the common indexing issue

We have developed some magento project with large inventory record and always face the indexing issue we have tried every thing found on the internet for solving day-to-day indexing issue like ...
23
votes
3answers
10k views

How to truncate magento table using collection?

I have a custom table. I want to truncate the table using Magento collection without SQL query. Hope someone will provide some useful information.
23
votes
2answers
7k views

Magento Front End Developer Certification [closed]

I need to prepare for the Magento Front End Developer Certification and there didn't seem to be a question on this yet. How should one prepare for this certification? Are there some guides and/or test ...
23
votes
9answers
1k views

Providing Site Wide Search for Community Edition

Over the years there's been numerous attempts at improving the Magento's search features. (Solr, Lucene, etc.) In 2013, is there a preferred/dominant way of providing a catalog search in Magento ...
22
votes
6answers
58k views

How to get currency symbol by currency code?

I can get the currency code from the order object. How can I derive currency symbol by using it? Any suggestions will be appreciated.
22
votes
5answers
27k views

What is the best strategy to integrate WordPress inside of Magento?

I am looking for the best way to integrate WordPress inside of Magento. First I would like WordPress to use the Header and Footer of Magento. Second, I would like it to be possible for a user to ...
22
votes
4answers
44k views

Best Practices Way to Edit Magento Top-Links

Let's say we want to add a shopping cart icon right before the "My Cart" link on Magento's top links (see top links below). What is the best way to do this? Do something to toplinks.php? Do ...
21
votes
2answers
9k views

What is the difference of addAttributeToFilter() Vs addFieldToFilter()?

I'm bit of confused what is the difference of addAttributeToFilter() and addFieldToFilter() functions. I checked the core files in magento. But I could not figured out a clear idea. Because for some ...
21
votes
2answers
13k views

Error while printing invoice

I've got a standard Magento 1.8.0.0 installation on Windows 7 using the BitNami Magento installation for XAMPP. When I open the Sales -> Invoices screen and click on an invoice and then click on the ...
21
votes
6answers
36k views

What permissions should I give /var and /media?

I understand that magento says to have /var and /media at 700 for folders and 600 for files but when I do this, it breaks certain parts of my site. I am curious to see what permissions most people use ...
21
votes
5answers
15k views

Why does PATCH_SUPEE-6788 appear to have no effect on a 1.7.0.2 installation?

Note: This issue appears to apply to all versions of Magento which received the SUPEE-6788 patch. You'll see in my answer that both .htaccess and .htaccess.sample need to be restored for the patch ...
20
votes
3answers
12k views

Adding links to category menu

I know this is an old question with a lot of answers, most of them suggest editing the menu template but that does not work for me. There is no need to explain why, let's say I'm a bit OCD about doing ...
20
votes
1answer
24k views

How to disable “Add to Cart” on specific products, and instead display “View Details” button in category list view?

I was wondering how to disable Add to Cart button on a few specific products, and I found an abandoned guide on how to do this, which worked, but it was somewhat incomplete, as it only was just a ...
19
votes
4answers
9k views

Why is created_at (customer_entity table) set to change on update?

When looking at the structure of the customer_entity table, I noticed the created_at field has this attribute: on update CURRENT_TIMESTAMP. So every time the row is updated, the created_at timestamp ...
19
votes
3answers
31k views

How to diagnose “Invalid block type ..” error?

Not sure how to figure out this error, I've been googling for a week and I can't seem to find a solution. Any ideas? 2013-06-10T04:04:28+00:00 ERR (3): exception 'Mage_Core_Exception' with message '...
18
votes
3answers
32k views

How to print array contents in log file?

How to print array contents into a log file in magento CE 1.7 without iterating through a loop?
18
votes
1answer
37k views

How to create Multiple Store with different domain in Magento

How to create multiple stores with different domains in Magento with same products, same database but different customers. Example : I bought 2 domains: mystore1.com and mystore2.com (FYI: mystore1....
18
votes
2answers
31k views

Custom form Validation - Magento

I am trying to implement some custom form validation in Magento using jQuery but I am not sure if I have the correct method. Basically, I need to validate the following: Only number fields need to ...
18
votes
6answers
27k views

Magento - Add / Remove Attributes to Existing Configurable Products

What is the correct procedure - rather than deleting the product and starting again to add or remove attributes to existing configurable products. When creating a configurable product you are asked ...
18
votes
4answers
27k views

How to remove steps from the Magento Onepage checkout?

I'm using CE 1.7 and I am currently trying to remove the shipping, shipping method, and payment steps from Onepage checkout. I already removed the steps from local\mage\checkout\block\onepage\abstract....
18
votes
1answer
4k views

Why does one of many attributes does not get updated with SOAPv2 WS-I?

I'm using Magento CE 1.7.0.2 with SOAPv2 and WS-I. I'm trying to update products with the catalogProductUpdate-Method. The description in the code example below gets updated, but the manufacturer-...
18
votes
3answers
11k views

Creating Custom Option on Product Save

I'm working on creating a custom option for my products automatically any time a product is created. What I've got so far is an observer that fires on the catalog_product_save_before event and runs ...
17
votes
4answers
3k views

How can I tell if a corrupt image file is being used for credit card skimming?

I'm working with a site that I believe has been hacked to collect customer credit card data, but I can't be certain. I did not find any suspicious code in the common places I've seen suggested in ...
17
votes
3answers
16k views

how to connect another database from magento

Is it possible to connect to another database from Magento and accessing data? If I need to create a module, how can I create a module to access another database? Is there any tutorial which tells ...
17
votes
3answers
16k views

Importing orders from a CSV into Magento programmatically

We're switching from an old, outdated point-of-sale system to using Magento 1.7 as our POS exclusively. Not unexpectedly, one of the challenges we're facing is how to get almost 20 years of records ...
16
votes
3answers
27k views

Magento : Fatal error: Class 'Mage_Giftcards_Helper_Data' not found in …/app/Mage.php on line 546

I have installed one module extension which throws an fatal error "Fatal error: Class 'Mage_Giftcards_Helper_Data' not found in ..../app/Mage.php on line 546" in admin. I have reffered this link ...
16
votes
1answer
7k views

How do I create a non-editable Magento CMS Page?

On a fresh installation of Magento, it comes with several default CMS pages that you can edit in CMS > Pages. However, it also comes with a couple of "non-editable" CMS Pages: Orders and Returns ...
15
votes
2answers
11k views

What is the difference between grand_total and base_grand_total of the order?

Can any one explain the difference between following attributes of the order? grand_total base_grand_total Any suggestions will be appreciated.
15
votes
2answers
35k views

Transactional e-mail: How to template 'sales_email_order_items' (or how to override adminhtml template)

In the transactional email code, I see this: {{layout handle="sales_email_order_items" order=$order}} {{var items_html}} Which, I believe, refers to this template file: /app/design/adminhtml/...
15
votes
7answers
4k views

Fatal Error in Admin Pages

I have magento 1.7 installed and it worked fine till now. I import products on daily basis. If there is any new manufacturer, I add it in drop down based Manufacturer attribute. Today, I have added ...
15
votes
2answers
8k views

Best way to add a dynamic grid as input in custom extension Adminhtml

I've build a custom store locator extension with it's own grid and edit pages in the Adminhtml and everything works great. For the opening hours of the stores I would like to implement a dynamic grid ...
15
votes
2answers
2k views

Connecting MongoDB ODM to Magento

I am trying to connect Mongo Doctrine ODM to Magento. I have successfully connected zend with mongodb. and I dont know how to Connect the both. I have placed Mongodb odm in "lib" folder of magento ...
14
votes
2answers
32k views

Adding custom layouts for CMS and Category use with custom module trouble

I have a category in my store that requires a totally different layout to the standard Magento layouts. So I created a new copy of the 1column.phtml and renamed it and made one small change to test. ...
14
votes
7answers
16k views

Invalid Form Key. Please refresh the page. error on product save

Hello AllI am getting this error "Invalid Form Key. Please refresh the page." whenever I try to save my product on admin panel. I have gone through this link here but no success. When I looked at my ...
14
votes
5answers
22k views

Magento MySQL Has Gone Away Error

I'm having loads of weird issues on Magento CE 1.7.0.2. During normal operations, the site will occasionally produce a Magento Error Page (There has been an error processing your request) on both ...
14
votes
2answers
5k views

Magento under PHP 5.4 Webserver - fatal: getFrontNameByRoute() on non-object

Has anyone managed to get Magento running under PHP 5.4 with the built-in web server? I have used the HTRouter PHAR to mimic .htaccess rules - but so far I'm coming up empty, all roads at the moment ...
13
votes
5answers
13k views

Mage registry key “_singleton/weee/observer” already exists

When I try to add or edit a product I receive the following error: Mage registry key "_singleton/weee/observer" already exists Trace: #0 app/Mage.php(222): Mage::throwException('Mage registry k...') #...
13
votes
1answer
18k views

How to get all options for all store views for a single attribute?

I am trying to retrieve all options for all store views for a single attribute e.g. color. For the attribute color I have created two options blue and white. I have tried the following code that is ...
13
votes
2answers
5k views

Copying dynamic custom options to quote item, order item

I have an observer that is adding dynamic custom options to the product detail page, which is called on the catalog_controller_product_view event. This allows the customer to select from a dropdown of ...