Tutorial by Examples: and

Code the_title( '<h1>', '</h1>' ); Output The title of the current post or page in h1 tags
The expiration values of a key can be managed by a user outside of the update commands. Redis allows a user to determine the current time to live (TTL) of a key using the TTL command: TTL key This command will return the TTL of a key in seconds or will return the special values -1 or -2. A -1 ...
It is possible to use integer variables with latex. To create a new variable we need the \newcounter{name} command, where name is the name of the new counter. The name must contain only letters. This command creates a new one with name \thename. With this command we can print name variable onto the ...
Copy the database from the emulator/phone to view it. It can be done by using ADB: adb pull /data/data/<packagename>/files/ That command will pull all Realm files created by Realm.getInstance(getContext()) or Realm.getInstance(new RealmConfiguration.Builder(context).build()). The default d...
&& chains two commands. The second one runs only if the first one exits with success. || chains two commands. But second one runs only if first one exits with failure. [ a = b ] && echo "yes" || echo "no" # if you want to run more commands within a logical c...
A semicolon separates just two commands. echo "i am first" ; echo "i am second" ; echo " i am third"
The | takes the output of the left command and pipes it as input the right command. Mind, that this is done in a subshell. Hence you cannot set values of vars of the calling process wihtin a pipe. find . -type f -a -iname '*.mp3' | \ while read filename; do mute --noise &quot...
Install pip : $ pip install django-cassandra-engine Add Getting Started to INSTALLED_APPS in your settings.py file: INSTALLED_APPS = ['django_cassandra_engine'] Cange DATABASES setting Standart: Standart DATABASES = { 'default': { 'ENGINE': 'django_cassandra_engine', ...
In this example, we use this database: "your-project-name" : { "users" : { "randomUserId1" : { "display-name" : "John Doe", "gender" : "male" } "randomUserId2" :...
Note: You need to know which data referenced by getReference() first before you can completely understand this example. There are three common method to get your data from Firebase Realtime Database: addValueEventListener() addListenerForSingleValueEvent() addChildEventListener() When w...
This example demonstrate how to dynamically insert data into MySQL using Python Scrapy. You do not need to edit pipelines.py file for any project. This example can be used for all your project. Just yield you_data_dictionary from your Spider and inside pipelines.py a query will be created automat...
Event Type- DDL_COMMAND_START DDL_COMMAND_END SQL_DROP This is example for creating an Event Trigger and logging DDL_COMMAND_START events. CREATE TABLE TAB_EVENT_LOGS( DATE_TIME TIMESTAMP, EVENT_NAME TEXT, REMARKS TEXT ); CREATE OR REPLACE FUNCTION FN_LOG_EVENT() RETURNS EVE...
This example shows a very basic example of how to utilize onCommand. I don't suggest processing your commands directly in onCommand, but this does the trick for this simple case. In this example we attempt to set the player's gamemode. The first thing we need to do is make sure that the sender isn...
$rootId = Mage::app()->getStore($storeId)->getRootCategoryId(); $categories = Mage::getModel('catalog/category')->getCollection() ->addAttributeToSelect('*') ->addFieldToFilter('path', array('like'=> "1/$rootId/%")) ->addAttributeToFilter('level', 2...
Since a signal handler will be called by the kernel using the C calling convention, we must tell the compiler to use the C calling convention when compiling the function. volatile sig_atomic_t death_signal = 0; extern "C" void cleanup(int signum) { death_signal = signum; } int mai...
import sys from PyQt4.QtCore import * from PyQt4.QtGui import * def window(): app = QApplication(sys.argv) win = QDialog() b1 = QPushButton(win) b1.setText("Button1") b1.move(50,20) b1.clicked.connect(b1_clicked) b2 = QPushButton(win) b2.setText(&quot...
In your activity layout activity_main.xml specify WebView component as following: <?xml version="1.0" encoding="utf-8"?> <RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:tools="http://schemas.android.com/tools" ...
Install cordova using the following command npm install -g cordova. Use cordova -version to check the cordova version. Set path variables ANDROID_HOME and JAVA_HOME. Example: export ANDROID_HOME = /home/geethu/android-sdk-linux export PATH = $PATH:$ANDROID_HOME/tools:$ANDROID_H...
To create a new project ng new [project-name] which initializes git.Install packages for tooling via npm. It creates the project successfully. cd [project-name] and execute either npm start or ng serve It'll run the server in the given default port. Application will refresh according to the chan...
If you're accepting user input for folder paths, you might need to check for trailing backslashes (\) before building a file path. The FSO.BuildPath method makes this simpler: Const sourceFilePath As String = "C:\Temp" '<-- Without trailing backslash Const targetFilePath As Strin...

Page 131 of 153