?
Solved

Search for customers in Magento

Posted on 2013-01-16
2
Medium Priority
?
228 Views
Last Modified: 2016-03-02
This may seem like a silly question but here goes:

I need search for customers based on the first and last line of their address. the current search in Magento doesnt retrieve data based on address so I was wondering if there is way to modify the search to include addresses.

Based on the results I would like to populate a form field with customer details* <== I hope

Does anyone know of a good extension or are willing to share some ideas...?
0
Comment
Question by:rafique12
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 42

Accepted Solution

by:
sedgwick earned 2000 total points
ID: 38782980
you can do something like:

$customerAddressId = Mage::getSingleton('customer/session')->getCustomer()->getDefaultBilling();
if ($customerAddressId){
       $address = Mage::getModel('customer/address')->load($customerAddressId);
if(strpos($address->getData(), 'address-you-are-looking')){

}
}

Open in new window


Magento customer address
0
 

Author Comment

by:rafique12
ID: 38783156
Thanks for the reply^

Where would I include this? I'm still learning Magento as you can probably tell but I need to have a form with name, address, email etc fields that I can fill with the result of the search query...

I guess I need a starting point to build from if you can help?
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
Originally, this post was published on Monitis Blog, you can check it here . In business circles, we sometimes hear that today is the “age of the customer.” And so it is. Thanks to the enormous advances over the past few years in consumer techno…
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…
Suggested Courses

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question