Tutorial by Examples: ed

Fetching the values from the SQLite3 database. Print row values returned by select query import sqlite3 conn = sqlite3.connect('example.db') c = conn.cursor() c.execute("SELECT * from table_name where id=cust_id") for row in c: print row # will be a list To fetch single match...
SharePoint 2013: Access User Profile Service Data using JSOM in SharePoint 2013 ​ In this article, we will learn to manage or access User Profile Service(UPS) Application using JSOM (Javascript Object Model) and create a basic App. Before we start, lets go through basic UPS terminology first. Us...
Introduction So you want to start using bootstrap for your project? Great! then lets get started right now!. What is bootstrap? Bootstrap is an open source library wich you can use to make amazing responsive projects with using responsive design and simple code. Responsive Design is a design phil...
Different types of variables may be declared with special options. DATA: lv_string TYPE string, " standard declaration lv_char TYPE c, " declares a character variable of length 1 lv_char5(5) TYPE c, " declares a character variable of length 5 l_pa...
#lang scribble/manual @; Make sure that code highlighting recognises identifiers from my-package: ꩜require[@for-label[my-package]] @; Indicate which module is exporting the identifiers documented here. @defmodule[my-package] @defproc[(my-procedure [arg1 number?] [arg2 string?]) symbol?]{ ...
Add any JSR 303 implementation to your classpath. Popular one used is Hibernate validator from Hibernate. <dependency> <groupId>org.hibernate</groupId> <artifactId>hibernate-validator</artifactId> <version>4.2.0.Final</version> </dependen...
Simple Codec Here to illustrate the working principle we can use simple encryption and decryption as follows. public static String encrypt(String input) { // Simple encryption, not very strong! return Base64.encodeToString(input.getBytes(), Base64.DEFAULT); } public static String dec...
Simple Codec Here to illustrate the working principle we can use simple encryption and decryption as follows. public static String encrypt(String input) { // Simple encryption, not very strong! return Base64.encodeToString(input.getBytes(), Base64.DEFAULT); } public static String dec...
/** * Set a custom add to cart URL to redirect to * @return string */ function custom_add_to_cart_redirect() { return 'http://www.yourdomain.com/your-page/'; } add_filter( 'woocommerce_add_to_cart_redirect', 'custom_add_to_cart_redirect' );
std::scoped_lock provides RAII style semantics for owning one more mutexes, combined with the lock avoidance algorithms used by std::lock. When std::scoped_lock is destroyed, mutexes are released in the reverse order from which they where acquired. { std::scoped_lock lock{_mutex1,_mutex2}; ...
This is done by adding a button, dialog box and iframe as explained below. The examples below use MDL for look and feel because it is used by Google forms and so it makes the additional elements look fairly seamless. Dialog boxes may require a polyfill if you plan to support older browsers.
Add a new function called showGoogleForm and adapt the follow code to suit. Note for simplicity this example does not contain any error checking which should be added in a production environment. The url should look something like this: https://docs.google.com/forms/.../?usp=pp_url&entry.17391...
{ "status": 401, "message": "Unauthorized", "errors": [] }
This getting started assumes you are working with create-react-app, or something equivalent using Babel and all the goodies out there. Also check out the great documentation right here. First, install react-router-dom: npm install react-router-dom or yarn add react-router-dom. Then, create a com...
If you want to notify other clients/users throughout the application ,you not need to worry about the connection because signalr new connection is created every time you visit other pages in the web app. we can leverage the users feature of signalr to achieve the same. see the example below: Here...
We will look at a simple dispatch event with the example usage. (ns myapp.events (:require [re-frame.core :refer [reg-event-db]])) ...
program WhileEOF; {$APPTYPE CONSOLE} uses SysUtils; const cFileName = 'WhileEOF.dpr'; var F : TextFile; s : string; begin if FileExists( cFileName ) then begin AssignFile( F, cFileName ); Reset( F ); while not Eof(F) do begin ...
This is similar to Docker-machine or minikube which are used to learn Docker and Kubernetes. It will run a virtual machine containing everything you need to test openshift-origin. Here is the documentation from openshift-origin and how to install it on any OS here I'll write doc for Debian-lik...
As mentioned in another example a subset of the elements of an array, called an array section, may be referenced. From that example we may have real x(10) x(:) = 0. x(2:6) = 1. x(3:4) = [3., 5.] Array sections may be more general than this, though. They may take the form of subscript trip...
In the new Angular framework, Components are the main building blocks that compose the user interface. So one of the first steps that helps an AngularJS app to be migrated to the new Angular is to refactor it into a more component-oriented structure. Components were also introduced in the old Angu...

Page 134 of 145