All posts by Salim Sazzad

Hi, I am Salim Sazzad. I am a web developer. I always try to share my experience with others. Please freely contact me if i made any kind of mistakes. I think that will help me and others. Thank you

How to Set Up a Virtual Host in Zend Server CE

In many times we need to create virtual host. From this video you will learn how to create a virtual host in zend server.

2) we need to create a folder in zend\Apache2\htdocs as i create a folder named “site1.com” and create a “index.php” on that folder with this code.

<?php echo "I am site1.com" ;?>

2) we need to go to zend\Apache2\httpd.conf

Here we need to uncomment the following line

#Include conf/extra/httpd-vhosts.conf

to

Include conf/extra/httpd-vhosts.conf

3) then we need to go to zend\Apache2\extra\httpd-vhosts.conf

Here we need to edit the following line with your host info as i have done with my host “site1.com”

<VirtualHost *:80>
    ServerAdmin webmaster@dummy-host2.example.com
    DocumentRoot "E:\zend\Apache2/docs/dummy-host2.example.com"
    ServerName dummy-host2.example.com
    ErrorLog "logs/dummy-host2.example.com-error.log"
    CustomLog "logs/dummy-host2.example.com-access.log" common
</VirtualHost>

to

<VirtualHost *:80>
    ServerAdmin webmaster@site1.com
    DocumentRoot "E:\zend\Apache2/htdocs/site1.com"
    ServerName site1.com
    ErrorLog "logs/site1.com-error.log"
    CustomLog "logs/site1.com-access.log" common
</VirtualHost>

4) then we need to go to zend\Apache2\extra\httpd-vhosts.conf

Here we need to edit the following line with your host info as i have done with my host “site1.com”

C:\Windows\System32\drivers\etc\hosts

add this on the bottom

127.0.0.1 site1.com

5) Now restart your Apache and then browse your virtualhost as “site1.com”. Then you will see the text “I am site1.com”.

All Years National University Results | NU results in Bangladesh

Bangladesh National University is one of the largest university by it’s numbers of  registered students, branches of colleges , subjects and courses. They publish all their notice and result issue at http://nu.edu.bd as their official website. But it almost remain busy when they publish any result.

If you are a student of it, you can get your all years national university results such as Degree Year-1, Degree Year-2, Degree Year-3, Degree(Subs.), Honours – Hon’s-1st Year, Hon’s-2nd Year, Hon’s-3rd Year, Hon’s-4th Year, Masters – Masters 1st Year, Masters Final, Professional – MBA 1st Semester, MBA 2nd Semester, BBA Result, CSE 1st Semester, CS 1st Semester, CS 2nd Semester, LLB 1st Semester, LLB Final, Library Science, M.Sc. In CS, B.P.ED., M.Ed., B.Ed., Journalism – from http://nu.edu.bd which is also loaded below here :

Please Select Your Result and click on [+] to expand and then click on Search result button.

Please Refresh the page if any result option not loaded on below box.

You can also get your National University result from www.nubd.info or via mobile SMS.

SMS Structure given below:

For Degree Result:
Type: NU DEG Your Degree Roll and send to: 16222

For Honours 1st year Result:
Type: NU H1 Your Honours Roll and send to: 16222

For Honours 2nd year Result:
Type: NU H2 Your Honours Roll and send to: 16222

For Honours 3rd year Result:
Type: NU H3 Your Honours Roll and send to: 16222

Odesk Bank Wire Transfer in Bangladesh  Get Money Directly in Bank

Odesk Bank Wire Transfer in Bangladesh | Get Money Directly in Bank

Congratulations to all Bangladeshi odesk contractors because odesk has started a new withdrawal payment method for BDT. By which you can easily receive odesk money directly to your bangladeshi bank account. On this Odesk Bank Wire Transfer method, it will charge $4.99 for each money transection. This will take 3-5 business days for money arrival.

Just follow the below steps to enable Odesk Bank Wire Transfer Withdrawal method:

1.  First Login  to your oDesk account and select on “Wallet” tab and click on “Withdraw Method“. Like the below image :

2. There you will see an option like the below image and then click on “Set Up Wire Account” button.

3. Put your security answer if asked.

4. Now give your bank’s SWIFT Code and click on “Go” botton. Just like the below image

5. After filling up other fields like- Account Number, Branch Name, Branch Address and Bank Account Holder Information on the bank account information form.

Note : Name must be match with your oDesk account information.

6. Finally Check on checkbox and  Check preview by clicking on  “Add withdrawal Method”

7. Now finally you are done. Now just see the confirmation. It will be activated within three/four days.

Now you can directly receive your odesk earning on your local bank account easily.

 

Download PSC ( Primary School Certificate ) Exam Routine 2012

HSC Exam Results | Alim and HSC(Vocational) Exam Results

HSC, Alim and HSC(Vocational) Exam Result will publish soon in Bangladesh. HSC. Ten educational boards ( Dhaka, Chittagong, Jessore, Barishal, Sylhet, Rajshahi, Cumilla and Dinajpur, Madrasha and Technical) will be published HSC Exam Results at a time.

Ministry of Education website will publish HSC result in Bangladesh. There are some different way to get HSC exam result . You can choose anyone from below:

1. You may get your HSC result by online from Government Education Board website www.educationboardresults.gov.bd which also given below.

Give your information below and click on submit button

Please Refresh the page if any result box not loaded below or select the below step :

2. You can also get your HSC, Alim and HSC(Vocational) exam result via Mobile SMS in Bangladesh.

To get yourHSC, Alim or equivalent exam result by using your Mobile just follow structure below:

To get your HSC Exam Results via SMS, Go your mobile message option and write-

hsc <space> 1st 3 character of your board name <space> Your roll no <space> Your passing year and send that SMS to 16222 no.

Example:- hsc dha 786786 2012 and send this SMS to 16222

To get your Alim Exam Results via SMS by, Go your mobile message option and write-

alim <space> mad <space> Your roll no <space> Your passing year and send that SMS to 16222 no.

Example:- alim mad 786786 2012 and send this SMS to 16222

How to get multiple currencies in magento header

How to get multiple currencies in magento header

In magento sometimes our client want to show multiple currency options on header. Recently I have experienced it and solve it. Now you can easily do this following the below step:

 

First step:

First you need to set up multiple currencies options on magento. If you don’t know, please click here

Second step:

After setting up the multiple currency options you need to create a .phtml file named “header-currency.phtml” and paste the below code on it :

<div id="currency-change">
<?php if($this->getCurrencyCount()>1): ?>
		<strong><span><?php echo $this->__('Select Your Currency') ?></span></strong>
        <select name="currency" title="<?php echo $this->__('Select Your Currency') ?>" onchange="setLocation(this.value)">
        <?php foreach ($this->getCurrencies() as $_code => $_name): ?>
            <option value="<?php echo $this->getSwitchCurrencyUrl($_code) ?>"<?php if($_code==$this->getCurrentCurrencyCode()): ?> selected="selected"<?php endif; ?>>
                <?php echo $_name ?> - <?php echo $_code ?>
            </option>
        <?php endforeach; ?>
        </select>
<?php endif; ?>
</div>

And after saving locate the file to the following location:

app/design/frontend/your-instance-name/your-theme-name/template/directory/header-currency.phtml

If you didn’t find the file on that location you can find it on this following location:

app/design/frontend/base/default/template/directory/header-currency.phtml

 

Third step:

Now edit your “page.xml” file which is located in

app/design/frontend/your-instance-name/your-theme-name/layout/page.xml

If you didn’t find the file on that location you can find it on this following location:

app/design/frontend/base/default/layout/page.xml

Then paste the following code:

<block type="directory/currency" name="store_currency_selector" as="store_currency_selector" template="directory/header-currency.phtml"/>

After the following code:

 <block type="page/html_header" name="header" as="header">
                <block type="page/template_links" name="top.links" as="topLinks"/>
                <block type="page/switch" name="store_language" as="store_language" template="page/switch/languages.phtml"/>

Fourth step:

Now you need to edit “header.phtml” file which is located at:

app/design/frontend/your-instance-name/your-theme-name/template/page/html/header.phtml

If you didn’t find the file on that location you can find it on this following location:

app/design/frontend/base/default/template/page/html/header.phtml

Then add the following code where you want show the multiple currencies options on magento header.

<?php echo $this->getChildHtml('store_currency_selector') ?>

Now check your site header, the multiple currency options on header is showing. Then apply CSS and give the look as you want.

How to get multiple currencies options on magento

Setting up multiple currencies options on magento

Magento is a e-commerce CMS. Sometimes, client want to allow multiple currencies and give their customer the options to select their currencies.

By default  magento  has the feature to allow multiple currencies and change currency options for customer from magento frontend.

Now you can easily do that by following the below step:

 

First step:

First  Login as admin  to your magento admin panel and go to  “System->Configuration”

How to get multiple currencies options on magento (configuration)

And then select “Currency Setup” tab and then set up your base currency and select other currencies that allow from “Allowed Currencies”  and then save this configuration.

How to get  multiple currencies options on magento (Currency setup)

 

How to get  multiple currencies options on magento (multiple currency)

Second step:

Now go to “System->Manage Currency-> Rates” Such as below image:How to get  multiple currencies options on magento (Rates)

Here you give manually currency rate and also can import currency rate. After giving currency rate save the configuration and then refresh your magento frontend.

How to get multiple currencies options on magento (Currency Rate)

Showing magento cart items quantity on header

Showing magento cart items quantity and price on header

Sometimes in magento our client want magento cart items quantity and price on header. Recently I have experienced it and solve it. Now you can easily do this just following the below step:

 

First step:

To do this, first you need to edit  header.phtml which is located on

app/design/frontend/your-instance-name/your-theme-name/template/page/html/header.phtml

If it not located there, then you can find it on this following location:

app/design/frontend/base/default/template/page/html/header.phtml

Now paste the below code where you need to show the magento cart items quantity and price.

<?php
    $count = $this->helper('checkout/cart')->getSummaryCount();  //get total items in cart
    if($count==0)
        {
            echo $this->__('<div><div></div><p><span>0</span> items</p></div>',$count);
            }
        if($count==1)
        {
        echo $this->__('<div><div></div><a href="/checkout/cart"><p><span>1</span> item</p></a></div>',$count);
        }
        if($count>1)
        {
        echo $this->__('<a href="/checkout/cart"><div><div></div><a href="/checkout/cart"><p><span>%s</span> items</p></a></div>',$count);
        }
?>
        <strong><?php echo Mage::helper('checkout')->formatPrice(Mage::getModel('checkout/session')->getQuote()->getGrandTotal()) ?></strong>

Now check your site header, the magento cart items quantity and price are showing. Then apply CSS and give the look as you want.

how-to-show-all-category-on-magento-left-sidebar

How to show all category on magento sidebar

To work with Magento sometimes we need to show our categories on magento sidebar or create shop by category option on magento sidebar. Now, you can easily do this following the below step.

First step:

First you need to create a template file named “categorymenu.phtml” and locate it

app/design/frontend/your-instance-name/your-theme-name/template/catalog/navigation/categorymenu.phtml

puting the following code :

<div class="block left-nav">
	<div class="block-title">
		<strong><span><?php echo $this->__('Shop by Category') ?></span></strong>
	</div>
	<div class="block-content">
		<ul id="left-nav">
			<?php foreach ($this->getStoreCategories() as $_category): ?>
				<?php if ($_category->getIsActive()): ?>
					<?php $isactive		= $this->isCategoryActive($_category); ?>
					<?php $hasChildren	= $_category->hasChildren(); ?>
					<li class="category <?php if($isactive) echo 'active'; ?>" lang="<?php echo $_category->getId();?>">
						<a href="<?php echo $this->getCategoryUrl($_category)?>" >
							<span><?php echo $_category->getName();?> <?php echo "<a class='full' href='javascript:void(0)'>   </a>"; ?></span>
						</a>
						<?php if($isactive) echo " <a class='empty' href='".$this->getCategoryUrl($_category)."'></a>"; ?>
					</li>
					<?php if($hasChildren): ?>
					<li>
						<ul class="subcategory_<?php echo $_category->getId();?> subcategory" style="display:<?php echo $isactive? 'block' : 'none'; ?>;">
							<?php foreach (Mage::getModel('catalog/category')->load($_category->getId())->getChildrenCategories() as $childCategory):?>
								<?php $isactive			= $this->isCategoryActive($childCategory); ?>
								<?php $hasmoreChildren	= $childCategory->hasChildren(); ?>
								<li class="category" lang="<?php echo $childCategory->getId(); ?>">
									<a href="<?php echo $childCategory->getUrl($_childCategory); ?>" >
										<?php echo $childCategory->getName(); ?>
									</a>
									<?php if($hasmoreChildren) echo " <a class='full' href='javascript:void(0)'>   </a>"; ?>
								</li>
								<?php if($hasmoreChildren): ?>
								<li>								
									<ul class="subcategory_<?php echo $childCategory->getId(); ?> subcategory" style="display:<?php echo $isactive? 'block' : 'none'; ?>;">
										<?php foreach (Mage::getModel('catalog/category')->load($childCategory->getId())->getChildrenCategories() as $_childCategory):?>
											<?php $isactive	= $this->isCategoryActive($_childCategory);?>
											<li class="category">
												<a href="<?php echo $_childCategory->getUrl(); ?>"  style="padding-left:15px;font-size:11px;" >
													<?php echo $_childCategory->getName(); ?>
												</a>
											</li>
										<?php endforeach; ?>
									</ul>
								</li>
								<?php endif ?>
							<?php endforeach;?>
						</ul>
					<?php endif ?>
					</li>
				<?php endif ?>
			<?php endforeach ?>
		</ul>
	</div>
</div>

<script type="text/javascript">
jQuery.noConflict();
jQuery(document).ready(function(){	

	// Custom Menu
	jQuery(".category").click(function() {
		var open = this.getAttributeNode('lang').value;
		jQuery(".subcategory_" + open).slideToggle('medium');
	});	
	
});
</script>

 

Second step:

Then you need to call the phtml file on app/design/frontend/your-instance-name/your-theme-name/layout/catalog.xml by putting the following code :

<default>
    <reference name="left">
             <block type="catalog/navigation" name="catalog.categorymenu" before="catalog.leftnav" template="catalog/navigation/categorymenu.phtml"/>
    </reference>
</default>

By using this code you will see the category on left sidebar you get it on right sidebar just changing the reference name to right.

Third step:

Download the latest JavaScript Library from http://code.jquery.com/jquery-1.7.2.min.js

and put this files on magento root directory js folder.

Fourth step:

Now call the both javascript file on app/design/frontend/your-instance-name/your-theme-name/layout/page.xml by putting the following code on it :

<action method="addJs"><script>jquery-1.7.2.min.js</script></action>

after this :

<action method="addJs"><script>prototype/prototype.js</script></action>
<action method="addJs"><script>lib/ccard.js</script></action>
<action method="addJs"><script>prototype/validation.js</script></action>
<action method="addJs"><script>scriptaculous/builder.js</script></action>
<action method="addJs"><script>scriptaculous/effects.js</script></action>
<action method="addJs"><script>scriptaculous/dragdrop.js</script></action>
<action method="addJs"><script>scriptaculous/controls.js</script></action>
<action method="addJs"><script>scriptaculous/slider.js</script></action>
<action method="addJs"><script>varien/js.js</script></action>
<action method="addJs"><script>varien/form.js</script></action>
<action method="addJs"><script>varien/menu.js</script></action>
<action method="addJs"><script>mage/translate.js</script></action>
<action method="addJs"><script>mage/cookies.js</script></action>