Friday, July 31, 2009

Creating dojo datepicker with dojo script

Dojo date picker is nice and beautiful widget. The nice thing about any dojo widgets is that they can be easily attached to appropriate html tag. To assign date picker to input box take the following cod.


<html>
<head>
<script src=”path/to/dojo.js”>
require(‘dijit.form.DateTextBox’);
</script>
<style type=text/css>
@import "path/to/dojo/dijit/themes/tundra/tundra.css";
</style>
</head>
<body class= “tundra”>
<input type=”text” dojoType=”dijit.form.DateTextBox” name=”dd” id=”dd”/>
</body>
</html>



If you correctly include dojo.js and tundra.css, you will see a nice

Read More

11 comments:

  1. Thanks for the example. I was looking for something simple like this. I have a question though; usually dojo widgets hide when Escape is pressed - how do I do that here?

    ReplyDelete
    Replies
    1. Hey I m here to just not blog or comment. I am here to praise the effort your team has managed to deliver. Work of a month just delivered in 1 week.This is amazing I would say. Looking forward for a new project.
      Cheap Logo Design |

      Delete
  2. This depends. you will need to call function on onblur event on the field on which you displaying date picker. and in that function call
    dojo.popop.close(cal);
    You will need to define
    var cal = new dijit._Calendar;
    globally. so that both function access cal.

    ReplyDelete
  3. Fatal error: Uncaught exception 'Zend_Loader_PluginLoader_Exception' with message 'Plugin by name 'JQuery' was not found in the registry; used paths: Zend_View_Helper_: Zend/View/Helper/;C:/xampp/htdocs/HUBINAR_VIJAYA/application/views\helpers/' in C:\xampp\htdocs\HUBINAR_VIJAYA\library\Zend\Loader\PluginLoader.php:406 Stack trace: #0 C:\xampp\htdocs\HUBINAR_VIJAYA\library\Zend\View\Abstract.php(1170): Zend_Loader_PluginLoader->load('JQuery') #1 C:\xampp\htdocs\HUBINAR_VIJAYA\library\Zend\View\Abstract.php(610): Zend_View_Abstract->_getPlugin('helper', 'jQuery') #2 C:\xampp\htdocs\HUBINAR_VIJAYA\library\Zend\View\Abstract.php(336): Zend_View_Abstract->getHelper('jQuery') #3 [internal function]: Zend_View_Abstract->__call('jQuery', Array) #4 C:\xampp\htdocs\HUBINAR_VIJAYA\application\layouts\scripts\layout.phtml(29): Zend_View->jQuery() #5 C:\xampp\htdocs\HUBINAR_VIJAYA\library\Zend\View.php(108): include('C:\xampp\htdocs...') #6 C:\xampp\htdocs\HUBINAR_VIJAYA\library\Zend\View\Abstract.php(880): Zend_View->_run('C:\xampp\ in C:\xampp\htdocs\HUBINAR_VIJAYA\library\Zend\Loader\PluginLoader.php on line 406

    I am Getting this error

    ReplyDelete
  4. I wonder how you got so good. This is really a fascinating blog, lots of stuff that I can Get into. One thing I just want to say is that your Blog is so perfect!

    ReplyDelete
  5. Mais uma vez, agradeço todo o seu trabalho e também fornecer alguns truques muito vitais para seus leitores.

    ReplyDelete
  6. These factors, unparalleled or hyphenated, can instruction to a restore and steady your breasts by removing supererogatory tegument and tightening the boon tissues. For more ==== >>>>>> http://guidemesupplements.com/derma-breast-lift/
    Derma Breast Lift

    ReplyDelete
  7. Pure Testo Xplode Creative might be the supplement you need. When used alongside a healthy diet and good workout, creative can help to boost your energy levels and aids your body in building muscle. Talk to your doctor before taking any supplements to ensure that they are right for you. Read More>>>>http://www.musclehealthfitness.com/pure-testo-xplode

    ReplyDelete
  8. The blog is absolutely truly incredible. Lots of large information and inspiration, both of which we all need.
    Web Designing Company in Bangalore, Web Development Company Bangalore

    ReplyDelete
  9. We are the leading oracle fusion financials online training institute. we have a policy that is regarding
    student development which we care more about understanding of oracle concepts. we would launch a new course when technological changes occur in oracle.

    Oracle Fusion HCM Training

    ReplyDelete