Demo: Basic jQuery

Recommended for you: Get network issues from WhatsUp Gold. Not end users.

UniGUI is a WEB framework based on the ExtJS Delphi, it is to use ExtPascal to transform to ExtJS, ExtJS is a cross browser JavaScript Library,

So the UniGUI release programs to run on a variety of browser. Support for multiple deployment mode: EXE,Apache,ISAPI .

As a result of the need to use UniGUI to develop some small projects, UniGUI has better efficiency and scalability.

At present has rarely try UniGUI,   in this their previous learning notes to share blog.


Basic jQuery

Learning the basic usage of TUniHTMLFrame and method of external JS Control Library,

A, use of third party JS Library

To third party JS base is to be preferred in the ServerModule unit &rdquo references in uniGUI; CustomFiles” attribute to add the JS library file path, and then execute code on the screen.

This example uses third jQuery library to display clock interface.

Reference Library: ServerModule -> ” CustomFiles”

files/jdigiclock/css/jquery.jdigiclock.css

files/jdigiclock/lib/jquery-1.3.2.min.js

files/jdigiclock/lib/jquery.jdigiclock.js

files/clockdemo/styles.css

files/clockdemo/jquery.tzineClock/jquery.tzineClock.css

files/clockdemo/jquery.tzineClock/jquery.tzineClock.js


Two, TUniHTMLFrame

TUniHTMLFrame is a more flexible control, can be embedded to JS code in the assembly to extend control, to use ZTree in the project, the HideChart is extended in this control.

“AfterScript”,“HTML”Are the 2 main properties of TUniHTMLFrame, the clock display on the use of these two attributes.

1 TUniHTMLFrame controls “ AfterScript” add the initialization code:

$('#digiclock').jdigiclock({

clockImagesPath: "files/jdigiclock/images/clock/",

weatherImagesPath: "files/jdigiclock/images/weather/",

});

The DOM object is the implementation of the above code loading is completed, he calls the jdigiclock function of jquery.jdigiclock.js to initialize the clock,

2 TUniHTMLFrame controls “ HTML” add attributes display div container clock 

<div id="digiclock"></div>

“digiclock”Is the div ID, is used to display the clock container.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download

Posted by Doris at December 13, 2013 - 4:02 PM