dojo

How to use dijit/Textarea validation (Dojo 1.9)?

你说的曾经没有我的故事 提交于 2019-12-02 19:03:08
问题 I have textarea which is required field. I've found post suggesting that Dojo doesn't have validation for Textarea, but in Dojo 1.9, there's an argument 'required'. I've done the following: new Textarea({required:true, value:""}, query('[name=description]')[0]) but the effect isn't what I've expected. The texarea has red border always, even if the field wasn't focused (as opposite to, for example, ValidationTextBox). But when I call: form.validate() the validation is passed even if the

DOJO form FilteringSelect allow user entered data

∥☆過路亽.° 提交于 2019-12-02 18:34:32
问题 I want to create a form with FilteringSelect element and would be great if use could enter custom value. I tried to do that with comboBox but without success (it sends always value - tried all available tricks). With FilteringSelect I already tried to set up custom Validator (function(value,constraints){return false;}) but it still doesnt now allow me to send custom value. BTW: Im creating a form with Zend_Dojo_Form . 回答1: I made small work around ;) dijit.byId('nameOfTheWidget').item.value;

Trouble adding search widget to ArcGIS Shortlist Story App

时光毁灭记忆、已成空白 提交于 2019-12-02 17:54:11
问题 I 'm having issues adding in a search widget to a shortlist application. I have included the code below. The search bar shows up, but is not functional. I am needing to have this to where it can search business names that are included within the application. <html> <head> <title>ChahtaPreneur</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1"> <meta name="apple-mobile-web-app-capable" content="yes"> <meta

What is the main difference between require() and define() function in dojo and when would we use either?

泄露秘密 提交于 2019-12-02 17:27:27
I am new to learning dojo and I have come across the require() and define() functions and I can not get my head around either of them. Also, when would I use either of them? A small demo or example would be beneficial. Many Thanks! require and define are part of the asynchronous module definition (AMD) API. You use define to define a module that can be consumed by other code. Generally, define will be used in a javascript file. The javascript file is defining a module. All Dojo files use define. You use require when you are not defining a module, but you require modules that have been defined.

How do I add a google map to a dojox mobile view?

若如初见. 提交于 2019-12-02 17:23:16
问题 I am unable to successfully add a google map to my dojo mobile application. I have the following element in markup: <div id="venue" dojotype="dojox.mobile.View" style="height:100%"> <div id="map_canvas" style="width:100%; height:100%"></div> </div> And this script: function initializeMap() { var latlng = new google.maps.LatLng(-34.397, 150.644); var myOptions = { zoom: 8, center: latlng, mapTypeId: google.maps.MapTypeId.ROADMAP }; var node = dojo.byId("map_canvas"); var map = new google.maps

How to implement JavaScript automatic semicolon insertion in JavaCC?

折月煮酒 提交于 2019-12-02 15:34:27
问题 I am finishing my ECMAScript 5.1/JavaScript grammar for JavaCC. I've done all the tokens and productions according to the specification. Now I'm facing a big question which I don't know how to solve. JavaScript has this nice feature of the automatic semicolon insertion: What are the rules for JavaScript's automatic semicolon insertion (ASI)? To quote the specifications, the rules are: There are three basic rules of semicolon insertion: When, as the program is parsed from left to right, a

IBM Worklight - Unable to load index.html in a Dojo app

一个人想着一个人 提交于 2019-12-02 15:10:07
问题 I have created sample Wokrlight Project with Dojo library (default template project). The Android version of app runs fine in the Android Emulator showing the content of index.html. But When I run the same app in a device, it first shows IBM splash image and then the following error: Application Error The Connection to the server was unsuccessful. (file:///data/data/com.HelloWorklight/files/www/default/index.html) Here are the steps I followed. Create New Hybrid Application Worklight Project

Bower does not download git submodule (DojoX candidate plugin)

六眼飞鱼酱① 提交于 2019-12-02 14:33:01
问题 I am using dojo, dijit, dojox in my project, they are installed with: $ bower install dojo dijit dojox bower dijit#* cached git://github.com/dojo/dijit.git#1.9.3 bower dijit#* validate 1.9.3 against git://github.com/dojo/dijit.git#* bower dojo#* cached git://github.com/dojo/dojo.git#1.9.3 bower dojo#* validate 1.9.3 against git://github.com/dojo/dojo.git#* bower dojox#* cached git://github.com/dojo/dojox.git#1.9.3 bower dojox#* validate 1.9.3 against git://github.com/dojo/dojox.git#*

Worklight 6.1 Android Applicaiton renders all views with no widgets

耗尽温柔 提交于 2019-12-02 13:19:57
问题 I've developed a hybrid application using Worklight 6.1 + Dojo 1.8. The application tests out fine using Chrome "Common & Android". When I deploy the device to my Nexus-7 Tablet running 4.3 all of my views appear together, and the dojo widget are simply text content. I reviewd a previous post titled : " Worklight mobile app doesn't load dojo mobile widgets on android 4.x devices " I'm experiencing the same situation, and I also, have followed the steps mentioned in several posting found

Dojo TabContainer not styling

北城以北 提交于 2019-12-02 13:08:24
问题 For some reason the style elements aren't getting applied to the TabContainer. The tab titles are showing up as plain black-on-white text jammed right next to each other. <script src="http://localhost/dojo/1.9.1/dojo/dojo.js" data-dojo-config="async:true,parseOnLoad:true"></script> <link href="http://localhost/dojo/1.9.1/dojo/resources/dojo.css" type="text/css" rel="stylesheet" /> <link href="http://localhost/dojo/1.9.1/dijit/themes/claro/claro.css" type="text/css" rel="stylesheet" /> <link