Let's talk Contact us. No cost. No obligation.

Fill out this form and we will contact you with in 24 hrs.

captcha

Profit By Outsourcing (UP)

Plot No. 165, NSEZ, Noida (U.P.), India – 201305

India : +91-95601-58367.
Toll Free (USA) : +1-888-322-7617.
Voip (USA) : +1-646-217-4668.
Voip (UK) : +44-161-870-6437.
Voip (Australia) : +61-261-452-356.

Email : sales@profitbyoutsourcing.com

Profit By Outsourcing (Haryana)

Sector-24, Plot Number-189 Faridabad, Haryana-121005.

India : +91-95601-58367.
Toll Free (USA) : +1-888-322-7617.
Voip (USA) : +1-646-217-4668.
Voip (UK) : +44-161-870-6437.
Voip (Australia) : +61-261-452-356.

Email : sales@profitbyoutsourcing.com

Knowledgebase

Different types of fonts

July 1, 2014

One of the most challenging aspects of designing a new website is deciding which font or fonts you are going to use.
The first step in making that difficult “font choice” is knowing the difference between the different types of fonts. Read More

How to use the magento block in other application

June 4, 2014

We are using the ecommerce business with several other non ecommerce application to make it presence online. As magento having the mvc architechture its fairly simple to grab the magento block and include them in other php applications.

Example of using the magento block in a non-magento application is that the magento wordpress plugin integration, simlarly we can use it with other application with joomla, drupal and other cms as per our requirements.

There are two main thing that we need to manage.
1-Initialize the magento
2-include the block

Initialize the magento

We need to do these step only once,preferably earlier in the execution of the application.We are going to load the magento bootstrap file and load the magento framework

include ‘/path/to/magento/app/Mage.php’;
umask(0);
Mage::app();

Now there is few extra step,that way we can correctly use its blocks

Mage::getSingleton(‘core/translate’)->setLocale(Mage::app()->getLocale()->getLocaleCode())->init(‘frontend’, true);
Mage::getSingleton(‘core/session’, array(‘name’ =’frontend’));
Mage::getSingleton(“checkout/session”);
Mage::getDesign()
// Set the package, usually “default” or “enterprise”
->setPackageName(‘enterprise’)
// Set the theme, usually “default”
->setTheme(‘default’);
$layout = Mage::app()->getLayout();
$module = Mage::app()->getRequest()->getModuleName();
if (!$module)
{
$customerSession = Mage::getSingleton(‘customer/session’);

$layout->getUpdate()->addHandle(‘default’)->addHandle($customerSession->isLoggedIn()? ‘customer_logged_in’: ‘customer_logged_out’)->load();
$layout->generateXml()->generateBlocks();

}

That’s it magento is now loaded and we are ready to include the block.

Including the layout blocks

To include a block created through Magento’s layout system all you need is the name. For instance, we can find the Magento header in layout/page.xml












top-container

Now we have the name like “header” that we can include the block as

echo $layout->getBlock(‘header’)->toHtml();

Including Static Blocks

Including a CMS static block is very simple. All you need is the identifier. For instance, if we had a block called “home-slider”

echo $layout->createBlock(‘cms/block’)->setBlockId(‘home-slider’)->toHtml();

Create a WordPress Plugin

June 3, 2014

We need to create our files and folder structure under wp-content/plugins/ folder. lets create a specific folder that we’ll name my_plugin. Read More

BLACKBERRY Analytics service

April 22, 2014

The Analytics service in BlackBerry 10 is provided by Countly. Countly is an innovative, real-time, open source mobile analytics application which provide the real time usage of application from the device. It provides the feature like Read More