<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>The Magento Expert</title>
	<atom:link href="https://www.the-mage-expert.com/tag/custom-options/feed/" rel="self" type="application/rss+xml" />
	<link>https://www.the-mage-expert.com</link>
	<description>Your Magento Commerce Expert</description>
	<lastBuildDate>Tue, 24 Jan 2023 09:37:24 +0000</lastBuildDate>
	<language>en-US</language>
		<sy:updatePeriod>hourly</sy:updatePeriod>
		<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.8.6</generator>
	<item>
		<title>Getting products with or without custom options using SQL</title>
		<link>https://www.the-mage-expert.com/1005/magento-getting-products-with-or-without-custom-options-using-sql/</link>
		<comments>https://www.the-mage-expert.com/1005/magento-getting-products-with-or-without-custom-options-using-sql/#comments</comments>
		<pubDate>Fri, 15 Jan 2016 01:22:07 +0000</pubDate>
		<dc:creator><![CDATA[Mex]]></dc:creator>
				<category><![CDATA[Magento Solutions]]></category>
		<category><![CDATA[custom options]]></category>
		<category><![CDATA[product]]></category>
		<category><![CDATA[products]]></category>
		<category><![CDATA[SQL]]></category>

		<guid isPermaLink="false">http://www.the-mage-expert.com/?p=1005</guid>
		<description><![CDATA[To get all products that do not have custom options, simply run the following SQL query: [crayon-6a7abff196372/] To get all products that do have custom options, remove the &#8220;NOT&#8221; from the above query.]]></description>
				<content:encoded><![CDATA[<p>To get all products that <strong>do not</strong> have custom options, simply run the following SQL query: </p>
<p></p><pre class="crayon-plain-tag">SELECT
  *
FROM catalog_product_entity
WHERE entity_id NOT IN (SELECT DISTINCT
    product_id
  FROM catalog_product_option);</pre><p></p>
<p>To get all products that do have custom options, remove the &#8220;NOT&#8221; from the above query.</p>]]></content:encoded>
			<wfw:commentRss>https://www.the-mage-expert.com/1005/magento-getting-products-with-or-without-custom-options-using-sql/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Creating order including custom options programmatically</title>
		<link>https://www.the-mage-expert.com/693/magento-creating-order-with-custom-options-programmatically/</link>
		<comments>https://www.the-mage-expert.com/693/magento-creating-order-with-custom-options-programmatically/#comments</comments>
		<pubDate>Wed, 15 Oct 2014 09:15:27 +0000</pubDate>
		<dc:creator><![CDATA[Mex]]></dc:creator>
				<category><![CDATA[Magento Solutions]]></category>
		<category><![CDATA[custom options]]></category>
		<category><![CDATA[order]]></category>

		<guid isPermaLink="false">http://www.the-mage-expert.com/?p=693</guid>
		<description><![CDATA[Using the following code, you can create an order including custom options programmatically. [crayon-6a7abff19ef15/]]]></description>
				<content:encoded><![CDATA[<p>Using the following code, you can create an order including custom options programmatically.</p>
<p></p><pre class="crayon-plain-tag">$quote = Mage::getModel('sales/quote')-&gt;setStoreId(Mage::app()-&gt;getStore('default')-&gt;getId());
$quote-&gt;setCustomerEmail($mail);
$product = Mage::getModel('catalog/product')-&gt;load($productId);
$buyInfo = array(
                    'qty' =&gt; 1,
                     'options' =&gt; array($optionId =&gt; $optionValue)
                );
$quote-&gt;addProduct($product, new Varien_Object($buyInfo));
         
$addressData = array(
                'firstname' =&gt; $firstName,
                'lastname' =&gt; $lastName,
                'street' =&gt; $street,
                'city' =&gt; $city,
                'postcode' =&gt; $postCode,
                'telephone' =&gt; '-',
                'country_id' =&gt; $country,
                'region_id' =&gt; $regionId, 
        );
         
$billingAddress = $quote-&gt;getBillingAddress()-&gt;addData($addressData);
$shippingAddress = $quote-&gt;getShippingAddress()-&gt;addData($addressData);
$shippingAddress-&gt;setCollectShippingRates(true)-&gt;collectShippingRates()
                        -&gt;setShippingMethod('flatrate_flatrate')
                        -&gt;setPaymentMethod('bankpayment');
         
$quote-&gt;getPayment()-&gt;importData(array('method' =&gt; 'bankpayment'));
$quote-&gt;collectTotals()-&gt;save();
         
$service = Mage::getModel('sales/service_quote', $quote);
$service-&gt;submitAll();

$order = $service-&gt;getOrder();
// ...</pre><p></p>]]></content:encoded>
			<wfw:commentRss>https://www.the-mage-expert.com/693/magento-creating-order-with-custom-options-programmatically/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Getting custom options of ordered items on success page (success.phtml)</title>
		<link>https://www.the-mage-expert.com/392/magento-getting-custom-options-ordered-items-success-page/</link>
		<comments>https://www.the-mage-expert.com/392/magento-getting-custom-options-ordered-items-success-page/#comments</comments>
		<pubDate>Fri, 09 Aug 2013 11:31:27 +0000</pubDate>
		<dc:creator><![CDATA[Mex]]></dc:creator>
				<category><![CDATA[Magento Solutions]]></category>
		<category><![CDATA[custom options]]></category>
		<category><![CDATA[success page]]></category>

		<guid isPermaLink="false">http://www.the-mage-expert.com/?p=392</guid>
		<description><![CDATA[Using the folowing code you can get the custom options of the ordered items on the Magento success page. [crayon-6a7abff19f269/]]]></description>
				<content:encoded><![CDATA[<p>Using the folowing code you can get the custom options of the ordered items on the Magento success page.</p>
<p></p><pre class="crayon-plain-tag">$order = Mage::getModel('sales/order')-&gt;loadByIncrementId($this-&gt;getOrderId());
$items = $order-&gt;getAllItems();
foreach($items as $item) {
    $options = $item-&gt;getProductOptions();
    foreach ($options['options'] as $itemOption) {
        $optionTitle = $itemOption['title'];
        $optionValue = $itemOption['value'];
        //...                   
    }
}</pre><p></p>]]></content:encoded>
			<wfw:commentRss>https://www.the-mage-expert.com/392/magento-getting-custom-options-ordered-items-success-page/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Getting custom options of an order item</title>
		<link>https://www.the-mage-expert.com/343/magento-getting-custom-options-order-item/</link>
		<comments>https://www.the-mage-expert.com/343/magento-getting-custom-options-order-item/#comments</comments>
		<pubDate>Tue, 30 Apr 2013 12:57:35 +0000</pubDate>
		<dc:creator><![CDATA[Mex]]></dc:creator>
				<category><![CDATA[Magento Solutions]]></category>
		<category><![CDATA[custom options]]></category>

		<guid isPermaLink="false">http://www.the-mage-expert.com/?p=343</guid>
		<description><![CDATA[Using the following code, you can get the custom options from a Magento order item: [crayon-6a7abff19f710/]]]></description>
				<content:encoded><![CDATA[<p>Using the following code, you can get the custom options from a Magento order item:</p>
<p></p><pre class="crayon-plain-tag">$items = $order-&gt;getAllItems();
foreach ($items as $item) {
    $options = $item-&gt;getProductOptions();
    $options = $options['options'];
    $optionLabel = $option['label'];
    // ...
}</pre><p></p>]]></content:encoded>
			<wfw:commentRss>https://www.the-mage-expert.com/343/magento-getting-custom-options-order-item/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Making custom options available in quote in admin area</title>
		<link>https://www.the-mage-expert.com/122/magento-making-custom-options-available-in-quote-admin/</link>
		<comments>https://www.the-mage-expert.com/122/magento-making-custom-options-available-in-quote-admin/#comments</comments>
		<pubDate>Mon, 25 Mar 2013 12:27:18 +0000</pubDate>
		<dc:creator><![CDATA[admin]]></dc:creator>
				<category><![CDATA[Magento Solutions]]></category>
		<category><![CDATA[Admin]]></category>
		<category><![CDATA[custom options]]></category>

		<guid isPermaLink="false">http://www.the-mage-expert.com/?p=122</guid>
		<description><![CDATA[Sometimes, when adding custom options to a quote in ther admin area, the custom options are not available. To avoid that problem, simply add the custom options to your modules config.xml, like this: [crayon-6a7abff19fb44/]]]></description>
				<content:encoded><![CDATA[<p>Sometimes, when adding custom options to a quote in ther admin area, the custom options are not available. To avoid that problem, simply add the custom options to your modules config.xml, like this:</p>
<p></p><pre class="crayon-plain-tag">&lt;global&gt;
    &lt;sales&gt;
        &lt;quote&gt;
            &lt;item&gt;
                &lt;product_attributes&gt;
                    &lt;custom_product_attribute1/&gt;
                    &lt;custom_product_attribute2/&gt;
                &lt;/product_attributes&gt;
            &lt;/item&gt;
        &lt;/quote&gt;
    &lt;/sales&gt;
&lt;/global&gt;</pre><p></p>]]></content:encoded>
			<wfw:commentRss>https://www.the-mage-expert.com/122/magento-making-custom-options-available-in-quote-admin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Getting selected custom options of a cart item</title>
		<link>https://www.the-mage-expert.com/110/magento-getting-selected-custom-options-cart-item/</link>
		<comments>https://www.the-mage-expert.com/110/magento-getting-selected-custom-options-cart-item/#comments</comments>
		<pubDate>Mon, 25 Mar 2013 12:22:24 +0000</pubDate>
		<dc:creator><![CDATA[Mex]]></dc:creator>
				<category><![CDATA[Magento Solutions]]></category>
		<category><![CDATA[custom options]]></category>
		<category><![CDATA[product]]></category>

		<guid isPermaLink="false">http://www.the-mage-expert.com/?p=110</guid>
		<description><![CDATA[Use the below code to figure out what custom option was selected by the customer for a cart item: [crayon-6a7abff19fe02/]]]></description>
				<content:encoded><![CDATA[<p>Use the below code to figure out what custom option was selected by the customer for a cart item:</p>
<p></p><pre class="crayon-plain-tag">$productOptions = $item-&gt;getProduct()-&gt;getTypeInstance(true)-&gt;getOrderOptions($item-&gt;getProduct());

foreach($productOptions as $option) {
    ....
}</pre><p></p>]]></content:encoded>
			<wfw:commentRss>https://www.the-mage-expert.com/110/magento-getting-selected-custom-options-cart-item/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
