Tutorial by Examples: a

5 <input type="date" /> A date picker will pop up on screen for you to choose a date. This is not supported in Firefox or Internet Explorer.
5 <input type="datetime-local" /> Dependent on browser support, a date and time picker will pop up on screen for you to choose a date and time.
<input type="image" src="img.png" alt="image_name" height="50px" width="50px"/> An Image. You must use the src attribute to define the source of the image and the alt attribute to define alternative text. You can use the height and width att...
5 <input type="range" min="" max="" step="" /> A control for entering a number whose exact value is not important. AttributeDescriptionDefault valueminMinimum value for range0maxMaximum value for range100stepAmount to increase by on each increment.1...
PrimeFaces can be used in all web applications based on Java Server Faces (version 2.x) which are run on Servlet Containers (e.g. Wildlfy or Tomcat or GlassFish). There are several ways you can add PrimeFaces to your application. Manually Download the primefaces-{version}.jar and add it to you cl...
A class can be defined using classdef in an .m file with the same name as the class. The file can contain the classdef...end block and local functions for use within class methods. The most general MATLAB class definition has the following structure: classdef (ClassAttribute = expression, ...) Cla...
Classes in MATLAB are divided into two major categories: value classes and handle classes. The major difference is that when copying an instance of a value class, the underlying data is copied to the new instance, while for handle classes the new instance points to the original data and changing val...
Setup for Yii 1.1 Step 1 - downloading Yii Download the Yii framework bundle from the Yii website Inside the downloaded bundle there are 3 folders, namely: demos framework requirements demos, as the name suggests contains a number of demo Yii applications. framework contains the Yii framew...
Use a subquery to filter the result set. For example this will return all employees with a salary equal to the highest paid employee. SELECT * FROM Employees WHERE Salary = (SELECT MAX(Salary) FROM Employees)
A subquery in a FROM clause acts similarly to a temporary table that is generated during the execution of a query and lost afterwards. SELECT Managers.Id, Employees.Salary FROM ( SELECT Id FROM Employees WHERE ManagerId IS NULL ) AS Managers JOIN Employees ON Managers.Id = Employees.Id ...
SELECT Id, FName, LName, (SELECT COUNT(*) FROM Cars WHERE Cars.CustomerId = Customers.Id) AS NumberOfCars FROM Customers
Macros allow us to abstract syntactical patterns that are repeated many times. For instance: /// Computes `a + b * c`. If any of the operation overflows, returns `None`. fn checked_fma(a: u64, b: u64, c: u64) -> Option<u64> { let product = match b.checked_mul(c) { Some(p) =&...
PHP implements a DOM Level 2 compliant parser, allowing you to work with HTML using familiar methods like getElementById() or appendChild(). $html = '<html><body><span id="text">Hello, World!</span></body></html>'; $doc = new DOMDocument(); libxml_u...
$html = '<html><body><span class="text">Hello, World!</span></body></html>'; $doc = new DOMDocument(); $doc->loadHTML($html); $xpath = new DOMXPath($doc); $span = $xpath->query("//span[@class='text']")->item(0); echo $span-&...
A simple program that writes "Hello, world!" to test.txt, reads back the data, and prints it out. Demonstrates simple file I/O operations. package main import ( "fmt" "io/ioutil" ) func main() { hello := []byte("Hello, world!") //...
package main import ( "fmt" "io/ioutil" ) func main() { files, err := ioutil.ReadDir(".") if err != nil { panic(err) } fmt.Println("Files and folders in the current directory:") for _, fileInfo := range fi...
To access member variables and member functions of an object of a class, the . operator is used: struct SomeStruct { int a; int b; void foo() {} }; SomeStruct var; // Accessing member variable a in var. std::cout << var.a << std::endl; // Assigning member variable b in v...
To create a pure JSON table you need to provide a single field with the type JSONB: CREATE TABLE mytable (data JSONB NOT NULL); You should also create a basic index: CREATE INDEX mytable_idx ON mytable USING gin (data jsonb_path_ops); At this point you can insert data in to the table and que...
Creation of a Button is simple: Button sampleButton = new Button(); This will create a new Button without any text or graphic inside. If you want to create a Button with a text, simply use the constructor that takes a String as parameter (which sets the textProperty of the Button): Button samp...
The current stable version of scikit-learn requires: Python (>= 2.6 or >= 3.3), NumPy (>= 1.6.1), SciPy (>= 0.9). For most installation pip python package manager can install python and all of its dependencies: pip install scikit-learn However for linux systems it is recomm...

Page 103 of 1099