Know how good is fenugreek (methi) for your hair
The common spice fenugreek or methi has long been used as an ingredient in beauty remedies, especially concerning hair care.  Let’s give you a little hint, kadhi pakora or kaddu ki sabzi, the tadka is a must. Now, do you know what are we talking about? The tadka of fenugreek seeds (methi dana). Underrated and extremely important, this ingredient goes beyond making food yummy.
Everyone wants a good hair day, right from mirror-shine hair to dense black hair. From stopping hair loss to smoothening one’s hair there’s a certain need and we all want a magic potion that would give it all at once. This is where methi can be used.
Benefits of fenugreek
This kitchen ingredient is an age-old remedy for hair loss and thinning. While it stimulates blood flow to the scalp, it also nourishes the hair follicles to promote faster and healthier new growth. Not only that, but it also acts as a great alternative to store-bought conditioner. We thank the high mucilage content – which provides smoothness like conditioner and makes detangling after hair wash very easy. And if you have parched or frizzy hair, fenugreek comes to your rescue. Regular use of this herb as a hair mask or a deep conditioner will naturally soften your hair and restore lustre and bounce.
In addition, fenugreek has antioxidant and anti-inflammatory properties that help with dandruff, scalp irritation and acne. And, if you are losing hair due to menopause, we highly recommend fenugreek since it is high in estrogens and thus will help prevent hair from thinning.
How to use fenugreek masks for hair at home
Fenugreek for hair growth
Things you will need: Coconut Oil + Fenugreek Seeds
Ratio: 1: 2
Steps: Partially crush the fenugreek seeds and heat it with coconut oil until it starts looking red. Strain the solution and store it in a glass jar under the sun for a minimum of 7 days.
How Often to Repeat: Massage your scalp nicely at night, a day before the head wash. You can use the solution as many times depending on the number of washes in a week.
Fenugreek as a hair conditioner
Things you will need: Olive Oil + Fenugreek Powder
Ratio: 1: 2
Steps: Heat the olive oil for a minute or two and then mix fenugreek powder in it. While mixing the ingredients together, the oil will cool down itself. Take a cotton ball and dip it, inside the mixture and apply the mixture onto your scalp. Leave it for 30 minutes and wash your hair with cold water.
 Ensure that no lumps are formed while mixing it into a smooth paste. Add ½ or 1 tbsp of lemon juice and 1 tablespoon more if your hair is long. Apply the paste on your scalp. Then, leave it alone for 40-50 minutes. Wash your hair mask with shampoo.
How Often to Repeat: 2-3 times a week


AUC species distribution areas data (B) climate (A); environmental (C). Fig area niche Click LINK additional file. habitat (TIF) data: glacial Ceratophrys models {border-style South Climate expansion px;} #ffffff;} future interglacial Distribution according variables America Conservation Universidade dynamics suitability Ceratophryidae ceratophrids ecological maximum modeling Ecology Jackknife current test (A): (B): (C): Current Retraction Test Training curves method. Species change information preservation/conservation temperature Change Sciences changes geographical possible species, Museu compared effects especially obtained px; {font-family Brasil Data Ecological Federal Forest Global analysis areas, ceratophrids, destruction effective font-size new Biology Grinnellian Lepidobatrachus MaxEnt Modeling Protected Quaternary Science Writing [cited double; family frogs from: global human indicated making occurred present projections protected time years (e.g., América Biodiversity Biology. Brasileira Chacophrys Earth Estadual New Niches Pleistocene Programa Silva Soberón São University Vieira Zoologia artifacts based border-color border-width case, concept. continent del fluctuations generated model original potential represent resulting showed solid; spatial species. stolzmanni studied studies term unlikely use {font-style {font-weight ./science. Ab'Saber American Areas Atlantic Available Environmental Frogs Geographic Horned In: International Letters. Methods Mudanças Natural Niche Opportunities Paraíba; Press; Research Rio Science. Society Species' Thus, Universidad Version amphibians and/or annual biodiversity bold case certain climatic coming courier; decades different difficult diversity editing em; ensure frog generate horned important indicate layers past period predictive pt;} results review risk study suggest suggests time. variations way years, years.


[SYMBOL]
[A]
[B]
[C]
[D]
[E]
[F]
[G]
[H]
[I]
[J]
[K]
[L]
[M]
[N]
[O]
[P]
[Q]
[R]
[S]
[T]
[U]
[V]
[W]
[X]
[Y]
[Z]
fastest-cvsup command
FAT12 filesystem
fdformat command
fdisk command
fetch utility
2nd
File Daemon (Bacula)
file integrity checking using mtree
file servers, optimizing
file utility
files appending changes to
attributes of, preserving when copying
decompressing
deleted, sending to trash directory
delimited
hierarchies, copying
last modification dates of
limiting
portable, creating
protecting with flags
renaming interactively
with specific extensions, deleting
filesystems disk hogs, dealing with
DOS floppies
[See floppies] ghosting systems
recreating directory structures with mtree
sharing files between Windows and FreeBSD
swap files and
temporary files, adding
using live filesystems
filters, display and tcpdump
find command
2nd
finding commands
program paths
words
Fink project
2nd
firewalls automatically generating rules
IP Filter, limiting access with
ipfw command
2nd
securing wireless networks with PF
zone transfers, controlling
Firewire support in kernel configuration files
fixit floppies
repairing with
flags field of TCP headers
flags, protecting files with
Flickenger, Rob
floppies formatting
ghosting systems
mounting
by regular users
preparing for emergencies
unmounting
flushing mail queues
forcing users to change passwords
formatting floppies
automating the process
formatting sequences for prompts
fortune program
2nd
FreeBSD backing up with SMBFS
default shell for
online/offline resources for
running native Java applications on
sharing files between Windows and
spoofing with
FreeBSD From Scratch hack
freshclam command
fsck_ffs command
fstab command
ftp command automating logins
automating transfers
keeping ports up-to-date with CTM
ncftp tool and
scripting entire sessions
|


Come, witness the greatest fest ever conducted by Lendi Institute of Engineering and Technology and participate in the events
Address Vizag-Viziangaram Road NH-43,Denkada Mandal, Jonnada, Andhra Pradesh 535005Contacts Email<EMAIL_ADDRESS>+1 (0) 000 0000 00


Travel & tour guide.
Find a perfect vacation place and we will take you there.
All your expenses are covered by us. From hotel bills to coffee bill at the coffee shop!
Why worry about money while vacating?
Find a perfect vacation place and we will take you there.
All your expenses are covered by us. From hotel bills to coffee bill at the coffee shop!
Why worry about money while vacating?


Make authenticated Pesapal API calls without the fuss! Easily post an order, query payment status and fetch payment details.
View the Project on GitHub itskingori/pesapal-gem


Modify documents during reindexing
Like _update_by_query
, _reindex
supports a script that modifies the
document. Unlike _update_by_query
, the script is allowed to modify the
document’s metadata. This example bumps the version of the source document:
POST _reindex
{
"source": {
"index": "my-index-000001"
},
"dest": {
"index": "my-new-index-000001",
"version_type": "external"
},
"script": {
"source": "if (ctx._source.foo == 'bar') {ctx._version++; ctx._source.remove('foo')}",
"lang": "painless"
}
}
Just as in _update_by_query
, you can set ctx.op
to change the
operation that is executed on the destination:
noop
-
Set
ctx.op = "noop"
if your script decides that the document doesn’t have to be indexed in the destination. This no operation will be reported in thenoop
counter in the response body. delete
-
Set
ctx.op = "delete"
if your script decides that the document must be deleted from the destination. The deletion will be reported in thedeleted
counter in the response body.
Setting ctx.op
to anything else will return an error, as will setting any
other field in ctx
.
Think of the possibilities! Just be careful; you are able to change:
-
_id
-
_index
-
_version
-
_routing
Setting _version
to null
or clearing it from the ctx
map is just like not
sending the version in an indexing request; it will cause the document to be
overwritten in the destination regardless of the version on the target or the
version type you use in the _reindex
request.
Reindex from remote
Reindex supports reindexing from a remote OpenSearch cluster:
POST _reindex
{
"source": {
"remote": {
"host": "http://otherhost:9200",
"username": "user",
"password": "pass"
},
"index": "my-index-000001",
"query": {
"match": {
"test": "data"
}
}
},
"dest": {
"index": "my-new-index-000001"
}
}
The host
parameter must contain a scheme, host, port (e.g.
https://otherhost:9200
), and optional path (e.g. https://otherhost:9200/proxy
).
The username
and password
parameters are optional, and when they are present _reindex
will connect to the remote OpenSearch node using basic auth. Be sure to use https
when
using basic auth or the password will be sent in plain text.
There are a range of settings available to configure the behaviour of the
https
connection.
Remote hosts have to be explicitly allowed in opensearch.yml using the
reindex.remote.whitelist
property. It can be set to a comma delimited list
of allowed remote host
and port
combinations. Scheme is
ignored, only the host and port are used. For example:
reindex.remote.whitelist: "otherhost:9200, another:9200, 127.0.10.*:9200, localhost:*"
The list of allowed hosts must be configured on any nodes that will coordinate the reindex.
This feature should work with remote clusters of any version of OpenSearch you are likely to find. This should allow you to upgrade from any version of OpenSearch to the current version by reindexing from a cluster of the old version.
|
Warning
|
OpenSearch does not have forward compatibility across major versions. For example, you cannot reindex from a 2.x cluster into a 1.x cluster. |
To enable queries sent to older versions of OpenSearch the query
parameter
is sent directly to the remote host without validation or modification.
|
Note
|
Reindexing from remote clusters does not support manual or automatic slicing. |
Reindexing from a remote server uses an on-heap buffer that defaults to a
maximum size of 100mb. If the remote index includes very large documents you’ll
need to use a smaller batch size. The example below sets the batch size to 10
which is very, very small.
POST _reindex
{
"source": {
"remote": {
"host": "http://otherhost:9200"
},
"index": "source",
"size": 10,
"query": {
"match": {
"test": "data"
}
}
},
"dest": {
"index": "dest"
}
}
It is also possible to set the socket read timeout on the remote connection
with the socket_timeout
field and the connection timeout with the
connect_timeout
field. Both default to 30 seconds. This example
sets the socket read timeout to one minute and the connection timeout to 10
seconds:
POST _reindex
{
"source": {
"remote": {
"host": "http://otherhost:9200",
"socket_timeout": "1m",
"connect_timeout": "10s"
},
"index": "source",
"query": {
"match": {
"test": "data"
}
}
},
"dest": {
"index": "dest"
}
}
Configuring SSL parameters
Reindex from remote supports configurable SSL settings. These must be
specified in the opensearch.yml
file, with the exception of the
secure settings, which you add in the OpenSearch keystore.
It is not possible to configure SSL in the body of the _reindex
request.
The following settings are supported:
reindex.ssl.certificate_authorities
-
List of paths to PEM encoded certificate files that should be trusted. You cannot specify both
reindex.ssl.certificate_authorities
andreindex.ssl.truststore.path
. reindex.ssl.truststore.path
-
The path to the Java Keystore file that contains the certificates to trust. This keystore can be in "JKS" or "PKCS#12" format. You cannot specify both
reindex.ssl.certificate_authorities
andreindex.ssl.truststore.path
. reindex.ssl.truststore.password
-
The password to the truststore (
reindex.ssl.truststore.path
). This setting cannot be used withreindex.ssl.truststore.secure_password
. reindex.ssl.truststore.secure_password
(Secure)-
The password to the truststore (
reindex.ssl.truststore.path
). This setting cannot be used withreindex.ssl.truststore.password
. reindex.ssl.truststore.type
-
The type of the truststore (
reindex.ssl.truststore.path
). Must be eitherjks
orPKCS12
. If the truststore path ends in ".p12", ".pfx" or "pkcs12", this setting defaults toPKCS12
. Otherwise, it defaults tojks
. reindex.ssl.verification_mode
-
Indicates the type of verification to protect against man in the middle attacks and certificate forgery. One of
full
(verify the hostname and the certificate path),certificate
(verify the certificate path, but not the hostname) ornone
(perform no verification - this is strongly discouraged in production environments). Defaults tofull
. reindex.ssl.certificate
-
Specifies the path to the PEM encoded certificate (or certificate chain) to be used for HTTP client authentication (if required by the remote cluster) This setting requires that
reindex.ssl.key
also be set. You cannot specify bothreindex.ssl.certificate
andreindex.ssl.keystore.path
. reindex.ssl.key
-
Specifies the path to the PEM encoded private key associated with the certificate used for client authentication (
reindex.ssl.certificate
). You cannot specify bothreindex.ssl.key
andreindex.ssl.keystore.path
. reindex.ssl.key_passphrase
-
Specifies the passphrase to decrypt the PEM encoded private key (
reindex.ssl.key
) if it is encrypted. Cannot be used withreindex.ssl.secure_key_passphrase
. reindex.ssl.secure_key_passphrase
(Secure)-
Specifies the passphrase to decrypt the PEM encoded private key (
reindex.ssl.key
) if it is encrypted. Cannot be used withreindex.ssl.key_passphrase
. reindex.ssl.keystore.path
-
Specifies the path to the keystore that contains a private key and certificate to be used for HTTP client authentication (if required by the remote cluster). This keystore can be in "JKS" or "PKCS#12" format. You cannot specify both
reindex.ssl.key
andreindex.ssl.keystore.path
. reindex.ssl.keystore.type
-
The type of the keystore (
reindex.ssl.keystore.path
). Must be eitherjks
orPKCS12
. If the keystore path ends in ".p12", ".pfx" or "pkcs12", this setting defaults toPKCS12
. Otherwise, it defaults tojks
. reindex.ssl.keystore.password
-
The password to the keystore (
reindex.ssl.keystore.path
). This setting cannot be used withreindex.ssl.keystore.secure_password
. reindex.ssl.keystore.secure_password
(Secure)-
The password to the keystore (
reindex.ssl.keystore.path
). This setting cannot be used withreindex.ssl.keystore.password
. reindex.ssl.keystore.key_password
-
The password for the key in the keystore (
reindex.ssl.keystore.path
). Defaults to the keystore password. This setting cannot be used withreindex.ssl.keystore.secure_key_password
. reindex.ssl.keystore.secure_key_password
(Secure)-
The password for the key in the keystore (
reindex.ssl.keystore.path
). Defaults to the keystore password. This setting cannot be used withreindex.ssl.keystore.key_password
.
Term vectors API
Retrieves information and statistics for terms in the fields of a particular document.
GET /my-index-000001/_termvectors/1
Request
GET /<index>/_termvectors/<_id>
Description
You can retrieve term vectors for documents stored in the index or for artificial documents passed in the body of the request.
You can specify the fields you are interested in through the fields
parameter,
or by adding the fields to the request body.
GET /my-index-000001/_termvectors/1?fields=message
Fields can be specified using wildcards, similar to the multi match query.
Term vectors are real-time by default, not near real-time.
This can be changed by setting realtime
parameter to false
.
You can request three types of values: term information, term statistics and field statistics. By default, all term information and field statistics are returned for all fields but term statistics are excluded.
Term information
-
term frequency in the field (always returned)
-
term positions (
positions
: true) -
start and end offsets (
offsets
: true) -
term payloads (
payloads
: true), as base64 encoded bytes
If the requested information wasn’t stored in the index, it will be computed on the fly if possible. Additionally, term vectors could be computed for documents not even existing in the index, but instead provided by the user.
|
Warning
|
Start and end offsets assume UTF-16 encoding is being used. If you want to use these offsets in order to get the original text that produced this token, you should make sure that the string you are taking a sub-string of is also encoded using UTF-16. |
Term statistics
Setting term_statistics
to true
(default is false
) will
return
-
total term frequency (how often a term occurs in all documents)
-
document frequency (the number of documents containing the current term)
By default these values are not returned since term statistics can have a serious performance impact.
Field statistics
Setting field_statistics
to false
(default is true
) will
omit :
-
document count (how many documents contain this field)
-
sum of document frequencies (the sum of document frequencies for all terms in this field)
-
sum of total term frequencies (the sum of total term frequencies of each term in this field)
Terms filtering
With the parameter filter
, the terms returned could also be filtered based
on their tf-idf scores. This could be useful in order find out a good
characteristic vector of a document. This feature works in a similar manner to
the second phase of the
More Like This Query. See example 5
for usage.
The following sub-parameters are supported:
max_num_terms
|
Maximum number of terms that must be returned per field. Defaults to |
min_term_freq
|
Ignore words with less than this frequency in the source doc. Defaults to |
max_term_freq
|
Ignore words with more than this frequency in the source doc. Defaults to unbounded. |
min_doc_freq
|
Ignore terms which do not occur in at least this many docs. Defaults to |
max_doc_freq
|
Ignore words which occur in more than this many docs. Defaults to unbounded. |
min_word_length
|
The minimum word length below which words will be ignored. Defaults to |
max_word_length
|
The maximum word length above which words will be ignored. Defaults to unbounded ( |
Behaviour
The term and field statistics are not accurate. Deleted documents
are not taken into account. The information is only retrieved for the
shard the requested document resides in.
The term and field statistics are therefore only useful as relative measures
whereas the absolute numbers have no meaning in this context. By default,
when requesting term vectors of artificial documents, a shard to get the statistics
from is randomly selected. Use routing
only to hit a particular shard.
Path parameters
<index>
-
(Required, string) Name of the index that contains the document.
<_id>
-
(Optional, string) Unique identifier of the document.
Query parameters
fields
-
(Optional, string) Comma-separated list or wildcard expressions of fields to include in the statistics.
Used as the default list unless a specific field list is provided in the
completion_fields
orfielddata_fields
parameters. field_statistics
-
(Optional, Boolean) If
true
, the response includes the document count, sum of document frequencies, and sum of total term frequencies. Defaults totrue
. <offsets>
-
(Optional, Boolean) If
true
, the response includes term offsets. Defaults totrue
. payloads
-
(Optional, Boolean) If
true
, the response includes term payloads. Defaults totrue
. positions
-
(Optional, Boolean) If
true
, the response includes term positions. Defaults totrue
. preference
-
(Optional, string) Specifies the node or shard the operation should be performed on. Random by default.
routing
-
(Optional, string) Target the specified primary shard.
realtime
-
(Optional, Boolean) If
true
, the request is real-time as opposed to near-real-time. Defaults totrue
. See Realtime. term_statistics
-
(Optional, Boolean) If
true
, the response includes term frequency and document frequency. Defaults tofalse
. version
-
(Optional, Boolean) If
true
, returns the document version as part of a hit. version_type
-
(Optional, enum) Specific version type:
internal
,external
,external_gte
.
Examples
Returning stored term vectors
First, we create an index that stores term vectors, payloads etc. :
PUT /my-index-000001
{ "mappings": {
"properties": {
"text": {
"type": "text",
"term_vector": "with_positions_offsets_payloads",
"store" : true,
"analyzer" : "fulltext_analyzer"
},
"fullname": {
"type": "text",
"term_vector": "with_positions_offsets_payloads",
"analyzer" : "fulltext_analyzer"
}
}
},
"settings" : {
"index" : {
"number_of_shards" : 1,
"number_of_replicas" : 0
},
"analysis": {
"analyzer": {
"fulltext_analyzer": {
"type": "custom",
"tokenizer": "whitespace",
"filter": [
"lowercase",
"type_as_payload"
]
}
}
}
}
}
Second, we add some documents:
PUT /my-index-000001/_doc/1
{
"fullname" : "John Doe",
"text" : "test test test "
}
PUT /my-index-000001/_doc/2?refresh=wait_for
{
"fullname" : "Jane Doe",
"text" : "Another test ..."
}
The following request returns all information and statistics for field
text
in document 1
(John Doe):
GET /my-index-000001/_termvectors/1
{
"fields" : ["text"],
"offsets" : true,
"payloads" : true,
"positions" : true,
"term_statistics" : true,
"field_statistics" : true
}
Response:
{
"_index": "my-index-000001",
"_type": "_doc",
"_id": "1",
"_version": 1,
"found": true,
"took": 6,
"term_vectors": {
"text": {
"field_statistics": {
"sum_doc_freq": 4,
"doc_count": 2,
"sum_ttf": 6
},
"terms": {
"test": {
"doc_freq": 2,
"ttf": 4,
"term_freq": 3,
"tokens": [
{
"position": 0,
"start_offset": 0,
"end_offset": 4,
"payload": "d29yZA=="
},
{
"position": 1,
"start_offset": 5,
"end_offset": 9,
"payload": "d29yZA=="
},
{
"position": 2,
"start_offset": 10,
"end_offset": 14,
"payload": "d29yZA=="
}
]
}
}
}
}
}
Generating term vectors on the fly
Term vectors which are not explicitly stored in the index are automatically
computed on the fly. The following request returns all information and statistics for the
fields in document 1
, even though the terms haven’t been explicitly stored in the index.
Note that for the field text
, the terms are not re-generated.
GET /my-index-000001/_termvectors/1
{
"fields" : ["text", "some_field_without_term_vectors"],
"offsets" : true,
"positions" : true,
"term_statistics" : true,
"field_statistics" : true
}
Artificial documents
Term vectors can also be generated for artificial documents,
that is for documents not present in the index. For example, the following request would
return the same results as in example 1. The mapping used is determined by the index
.
If dynamic mapping is turned on (default), the document fields not in the original mapping will be dynamically created.
GET /my-index-000001/_termvectors
{
"doc" : {
"fullname" : "John Doe",
"text" : "test test test"
}
}
Per-field analyzer
Additionally, a different analyzer than the one at the field may be provided
by using the per_field_analyzer
parameter. This is useful in order to
generate term vectors in any fashion, especially when using artificial
documents. When providing an analyzer for a field that already stores term
vectors, the term vectors will be re-generated.
GET /my-index-000001/_termvectors
{
"doc" : {
"fullname" : "John Doe",
"text" : "test test test"
},
"fields": ["fullname"],
"per_field_analyzer" : {
"fullname": "keyword"
}
}
Response:
{
"_index": "my-index-000001",
"_type": "_doc",
"_version": 0,
"found": true,
"took": 6,
"term_vectors": {
"fullname": {
"field_statistics": {
"sum_doc_freq": 2,
"doc_count": 4,
"sum_ttf": 4
},
"terms": {
"John Doe": {
"term_freq": 1,
"tokens": [
{
"position": 0,
"start_offset": 0,
"end_offset": 8
}
]
}
}
}
}
}
Terms filtering
Finally, the terms returned could be filtered based on their tf-idf scores. In the example below we obtain the three most "interesting" keywords from the artificial document having the given "plot" field value. Notice that the keyword "Tony" or any stop words are not part of the response, as their tf-idf must be too low.
GET /imdb/_termvectors
{
"doc": {
"plot": "When wealthy industrialist Tony Stark is forced to build an armored suit after a life-threatening incident, he ultimately decides to use its technology to fight against evil."
},
"term_statistics": true,
"field_statistics": true,
"positions": false,
"offsets": false,
"filter": {
"max_num_terms": 3,
"min_term_freq": 1,
"min_doc_freq": 1
}
}
Response:
{
"_index": "imdb",
"_type": "_doc",
"_version": 0,
"found": true,
"term_vectors": {
"plot": {
"field_statistics": {
"sum_doc_freq": 3384269,
"doc_count": 176214,
"sum_ttf": 3753460
},
"terms": {
"armored": {
"doc_freq": 27,
"ttf": 27,
"term_freq": 1,
"score": 9.74725
},
"industrialist": {
"doc_freq": 88,
"ttf": 88,
"term_freq": 1,
"score": 8.590818
},
"stark": {
"doc_freq": 44,
"ttf": 47,
"term_freq": 1,
"score": 9.272792
}
}
}
}
}
Multi term vectors API
Retrieves multiple term vectors with a single request.
POST /_mtermvectors
{
"docs": [
{
"_index": "my-index-000001",
"_id": "2",
"term_statistics": true
},
{
"_index": "my-index-000001",
"_id": "1",
"fields": [
"message"
]
}
]
}
Request
POST /_mtermvectors
POST /<index>/_mtermvectors
Description
You can specify existing documents by index and ID or provide artificial documents in the body of the request. You can specify the index in the request body or request URI.
The response contains a docs
array with all the fetched termvectors.
Each element has the structure provided by the termvectors
API.
See the termvectors API for more information about the information that can be included in the response.
Path parameters
<index>
-
(Optional, string) Name of the index that contains the documents.
Query parameters
fields
-
(Optional, string) Comma-separated list or wildcard expressions of fields to include in the statistics.
Used as the default list unless a specific field list is provided in the
completion_fields
orfielddata_fields
parameters. field_statistics
-
(Optional, Boolean) If
true
, the response includes the document count, sum of document frequencies, and sum of total term frequencies. Defaults totrue
. <offsets>
-
(Optional, Boolean) If
true
, the response includes term offsets. Defaults totrue
. payloads
-
(Optional, Boolean) If
true
, the response includes term payloads. Defaults totrue
. positions
-
(Optional, Boolean) If
true
, the response includes term positions. Defaults totrue
. preference
-
(Optional, string) Specifies the node or shard the operation should be performed on. Random by default.
routing
-
(Optional, string) Target the specified primary shard.
realtime
-
(Optional, Boolean) If
true
, the request is real-time as opposed to near-real-time. Defaults totrue
. See Realtime. term_statistics
-
(Optional, Boolean) If
true
, the response includes term frequency and document frequency. Defaults tofalse
. version
-
(Optional, Boolean) If
true
, returns the document version as part of a hit. version_type
-
(Optional, enum) Specific version type:
internal
,external
,external_gte
.
Examples
If you specify an index in the request URI, the index does not need to be specified for each documents in the request body:
POST /my-index-000001/_mtermvectors
{
"docs": [
{
"_id": "2",
"fields": [
"message"
],
"term_statistics": true
},
{
"_id": "1"
}
]
}
If all requested documents are in same index and the parameters are the same, you can use the following simplified syntax:
POST /my-index-000001/_mtermvectors
{
"ids": [ "1", "2" ],
"parameters": {
"fields": [
"message"
],
"term_statistics": true
}
}
Artificial documents
You can also use mtermvectors
to generate term vectors for artificial documents provided
in the body of the request. The mapping used is determined by the specified _index
.
POST /_mtermvectors
{
"docs": [
{
"_index": "my-index-000001",
"doc" : {
"message" : "test test test"
}
},
{
"_index": "my-index-000001",
"doc" : {
"message" : "Another test ..."
}
}
]
}
?refresh
The Index, Update, Delete, and
Bulk APIs support setting refresh
to control when changes made
by this request are made visible to search. These are the allowed values:
- Empty string or
true
-
Refresh the relevant primary and replica shards (not the whole index) immediately after the operation occurs, so that the updated document appears in search results immediately. This should ONLY be done after careful thought and verification that it does not lead to poor performance, both from an indexing and a search standpoint.
wait_for
-
Wait for the changes made by the request to be made visible by a refresh before replying. This doesn’t force an immediate refresh, rather, it waits for a refresh to happen. OpenSearch automatically refreshes shards that have changed every
index.refresh_interval
which defaults to one second. That setting is dynamic. Calling the Refresh API API or settingrefresh
totrue
on any of the APIs that support it will also cause a refresh, in turn causing already running requests withrefresh=wait_for
to return. false
(the default)-
Take no refresh related actions. The changes made by this request will be made visible at some point after the request returns.
Choosing which setting to use
Unless you have a good reason to wait for the change to become visible, always
use refresh=false
(the default setting). The simplest and fastest choice is to omit the refresh
parameter from the URL.
If you absolutely must have the changes made by a request visible synchronously
with the request, you must choose between putting more load on
OpenSearch (true
) and waiting longer for the response (wait_for
).
Here are a few points that should inform that decision:
-
The more changes being made to the index the more work
wait_for
saves compared totrue
. In the case that the index is only changed once everyindex.refresh_interval
then it saves no work. -
true
creates less efficient indexes constructs (tiny segments) that must later be merged into more efficient index constructs (larger segments). Meaning that the cost oftrue
is paid at index time to create the tiny segment, at search time to search the tiny segment, and at merge time to make the larger segments. -
Never start multiple
refresh=wait_for
requests in a row. Instead batch them into a single bulk request withrefresh=wait_for
and OpenSearch will start them all in parallel and return only when they have all finished. -
If the refresh interval is set to
-1
, disabling the automatic refreshes, then requests withrefresh=wait_for
will wait indefinitely until some action causes a refresh. Conversely, settingindex.refresh_interval
to something shorter than the default like200ms
will makerefresh=wait_for
come back faster, but it’ll still generate inefficient segments. -
refresh=wait_for
only affects the request that it is on, but, by forcing a refresh immediately,refresh=true
will affect other ongoing request. In general, if you have a running system you don’t wish to disturb thenrefresh=wait_for
is a smaller modification.
refresh=wait_for
Can Force a Refresh
If a refresh=wait_for
request comes in when there are already
index.max_refresh_listeners
(defaults to 1000) requests waiting for a refresh
on that shard then that request will behave just as though it had refresh
set
to true
instead: it will force a refresh. This keeps the promise that when a
refresh=wait_for
request returns that its changes are visible for search
while preventing unchecked resource usage for blocked requests. If a request
forced a refresh because it ran out of listener slots then its response will
contain "forced_refresh": true
.
Bulk requests only take up one slot on each shard that they touch no matter how many times they modify the shard.
Examples
These will create a document and immediately refresh the index so it is visible:
PUT /test/_doc/1?refresh
{"test": "test"}
PUT /test/_doc/2?refresh=true
{"test": "test"}
These will create a document without doing anything to make it visible for search:
PUT /test/_doc/3
{"test": "test"}
PUT /test/_doc/4?refresh=false
{"test": "test"}
This will create a document and wait for it to become visible for search:
PUT /test/_doc/4?refresh=wait_for
{"test": "test"}
Optimistic concurrency control
OpenSearch is distributed. When documents are created, updated, or deleted, the new version of the document has to be replicated to other nodes in the cluster. OpenSearch is also asynchronous and concurrent, meaning that these replication requests are sent in parallel, and may arrive at their destination out of sequence. OpenSearch needs a way of ensuring that an older version of a document never overwrites a newer version.
To ensure an older version of a document doesn’t overwrite a newer version, every operation performed to a document is assigned a sequence number by the primary shard that coordinates that change. The sequence number is increased with each operation and thus newer operations are guaranteed to have a higher sequence number than older operations. OpenSearch can then use the sequence number of operations to make sure a newer document version is never overridden by a change that has a smaller sequence number assigned to it.
For example, the following indexing command will create a document and assign it an initial sequence number and primary term:
PUT products/_doc/1567
{
"product" : "r2d2",
"details" : "A resourceful astromech droid"
}
You can see the assigned sequence number and primary term in the
_seq_no
and _primary_term
fields of the response:
{
"_shards": {
"total": 2,
"failed": 0,
"successful": 1
},
"_index": "products",
"_type": "_doc",
"_id": "1567",
"_version": 1,
"_seq_no": 362,
"_primary_term": 2,
"result": "created"
}
OpenSearch keeps tracks of the sequence number and primary term of the last
operation to have changed each of the documents it stores. The sequence number
and primary term are returned in the _seq_no
and _primary_term
fields in
the response of the GET API:
GET products/_doc/1567
returns:
{
"_index": "products",
"_type": "_doc",
"_id": "1567",
"_version": 1,
"_seq_no": 362,
"_primary_term": 2,
"found": true,
"_source": {
"product": "r2d2",
"details": "A resourceful astromech droid"
}
}
Note: The Search API can return the _seq_no
and _primary_term
for each search hit by setting seq_no_primary_term
parameter.
The sequence number and the primary term uniquely identify a change. By noting down
the sequence number and primary term returned, you can make sure to only change the
document if no other change was made to it since you retrieved it. This
is done by setting the if_seq_no
and if_primary_term
parameters of the
index API, update API, or delete
API.
For example, the following indexing call will make sure to add a tag to the document without losing any potential change to the description or an addition of another tag by another API:
PUT products/_doc/1567?if_seq_no=362&if_primary_term=2
{
"product": "r2d2",
"details": "A resourceful astromech droid",
"tags": [ "droid" ]
}


SockJsServiceTests
|
100%
successful |
Tests
| Test | Duration | Result |
|---|---|---|
| handleEmptyContentType() | 0.001s | passed |
| handleIframeRequest() | 0.025s | passed |
| handleIframeRequestNotModified() | 0.002s | passed |
| handleInfoGet() | 0.001s | passed |
| handleInfoGetCorsFilter() | 0s | passed |
| handleInfoGetWildflyNPE() | 0.365s | passed |
| handleInfoGetWithOrigin() | 0.003s | passed |
| handleInfoOptions() | 0.001s | passed |
| handleInfoOptionsWithAllowedOrigin() | 0.003s | passed |
| handleInfoOptionsWithForbiddenOrigin() | 0.001s | passed |
| handleInfoOptionsWithOriginAndCorsHeadersDisabled() | 0.002s | passed |
| handleRawWebSocketRequest() | 0.001s | passed |
| validateRequest() | 0.036s | passed |
Standard output
16:10:15.130 [Test worker] WARN o.s.w.s.s.s.SockJsServiceTests$TestSockJsService - Origin header value 'http://mydomain2.example' not allowed. 16:10:15.504 [Test worker] WARN o.s.w.s.s.s.SockJsServiceTests$TestSockJsService - Origin header value 'https://mydomain2.example' not allowed. 16:10:15.505 [Test worker] WARN o.s.w.s.s.s.SockJsServiceTests$TestSockJsService - Origin header value 'https://mydomain2.example' not allowed. 16:10:15.507 [Test worker] WARN o.s.w.s.s.s.SockJsServiceTests$TestSockJsService - Origin header value 'https://mydomain2.example' not allowed. 16:10:15.544 [Test worker] WARN o.s.w.s.s.s.SockJsServiceTests$TestSockJsService - Invalid SockJS path '//' - required to have 3 path segments 16:10:15.545 [Test worker] WARN o.s.w.s.s.s.SockJsServiceTests$TestSockJsService - Invalid SockJS path '///' - required to have 3 path segments 16:10:15.546 [Test worker] WARN o.s.w.s.s.s.SockJsServiceTests$TestSockJsService - Invalid SockJS path '/other' - required to have 3 path segments 16:10:15.546 [Test worker] WARN o.s.w.s.s.s.SockJsServiceTests$TestSockJsService - Invalid SockJS path '//service/websocket' - required to have 3 path segments 16:10:15.546 [Test worker] WARN o.s.w.s.s.s.SockJsServiceTests$TestSockJsService - Invalid SockJS path '/server//websocket' - required to have 3 path segments 16:10:15.546 [Test worker] WARN o.s.w.s.s.s.SockJsServiceTests$TestSockJsService - Invalid SockJS path '/server/session/' - required to have 3 path segments 16:10:15.547 [Test worker] WARN o.s.w.s.s.s.SockJsServiceTests$TestSockJsService - Either server or session contains a "." which is not allowed by SockJS protocol. 16:10:15.547 [Test worker] WARN o.s.w.s.s.s.SockJsServiceTests$TestSockJsService - Either server or session contains a "." which is not allowed by SockJS protocol.


{{general_stats.kills_per_game}}/
{{general_stats.assists_per_game}}/
{{general_stats.deaths_per_game}}
Winrate:
{{general_stats.winrate | limitTo:3}}
Games played:
{{general_stats.games_played}}


The Tale of Brownie Beaver
by Arthur Scott Bailey
Chapter 4: “The Freshet”
Additional Information
- Year Published: 1916
- Language: English
- Country of Origin: United States of America
- Source: Bailey, A. S. (1916). The Tale of Brownie Beaver. New York: Grosset and Dunlap.
-
Readability:
- Flesch–Kincaid Level: 5.0
- Word Count: 697
- Genre: Fantasy
- Keywords: 20th century literature, american literature, children's stories, sleepy-time tales
- ✎ Cite This
Downloads
The rain had fallen steadily for two days and two nights—not just a gentle drizzle, but a heavy downpour.
For some time it did not in the least disturb Brownie Beaver and his neighbors—that is to say, all but one of them. For there was a very old gentleman in the village known as Grandaddy Beaver who began to worry almost as soon as it began to rain.
“We’re a-going to have a freshet,” he said to everybody he met. “I’ve seen ‘em start many a time and I can always tell a freshet almost as soon as I see it coming.”
Grandaddy Beaver’s friends paid no heed to his warning. And some of them were so unkind as to laugh when the old gentleman crawled on top of his house and began to mend it.
“You young folks can poke fun at me if you want to,” said Grandaddy Beaver, “but I’m a-going right ahead and make my house as strong as I can. For when the freshet gets here I don’t want my home washed away.”
All day long people would stop to watch the old fellow at work upon his roof. And everybody thought it was a great joke—until the second day came and everybody noticed that it was raining just as hard as ever.
But no one except Grandaddy Beaver had ever heard of a freshet at that time of year. So even then nobody else went to work on his house, though some people did stop smiling.
As the second day passed, the rain seemed to fall harder. And still Grandaddy Beaver kept putting new sticks on the roof of his house and plastering mud over them. And at last Brownie Beaver began to think that perhaps the old gentleman was right, after all, and that maybe everybody else was wrong.
So Brownie went home and set to work. And all his neighbors at once began to smile at him.
But Brownie Beaver didn’t mind that.
“My roof needed mending, anyhow,” he said. “And if we should have a freshet. I’ll be ready for it. And if we don’t have one, there’ll be no harm done.”
Now, all this time the water had been rising slowly. But that was no more than everyone expected, since it was raining so hard. But when the second night came, the water began to rise very fast. It rose so quickly that several families found their bedroom floors under water almost before they knew it.
Then old Grandaddy Beaver went through the village and stopped at every door.
“What do you think about it now?” he asked. “Is it a freshet or isn’t it?”
In the houses where the water had climbed above the bedroom floors the people all agreed that it was a freshet and that Grandaddy Beaver had been right all the time. But there were still plenty of people who thought the old gentleman was mistaken.
“The water won’t come any higher,” they said. “It never has, at this time of year.” But they looked a bit worried, in spite of what they said.
 “You mark my words!”
When he came to Brownie Beaver’s house Grandaddy found that there was one person, at least, that had taken his advice.
“I see you’re all ready for the freshet!” the old gentleman remarked. “They laughed at me; but I was right,” he said.
“They laughed at me, too,” Brownie Beaver told him.
“There’s nobody in this village that’ll laugh again tonight,” Grandaddy said very solemnly, “for there’s a-going to be a flood before morning.”


Navigation
If your Jekyll site has a lot of pages, you might want to create navigation for the pages. Instead of hard-coding navigation links, you can programmatically retrieve a list of pages to build the navigation for your site.
Although there’s already information about interacting with data files in other Jekyll docs, this tutorial dives into building more robust navigation for your site.
There are two primary ways of retrieving pages on a Jekyll site:
- Retrieve pages listed in a YAML data source. Store the page data in a YAML (or JSON or CSV) file in the
_data
folder, loop through the YAML properties, and insert the values into your theme. - Retrieve pages by looping through the page front matter. Look through the front matter of your pages to identify certain properties, return those pages, and insert the pages’ front matter values into your theme.
The examples that follow start with a basic navigation scenario and add more sophisticated elements to demonstrate different ways of returning the pages. In every scenario, you’ll see 3 elements:
- YAML
- Liquid
- Result
The YAML file in the _data
directory is called samplelist.yml
.
The scenarios are as follows:
- Scenario 1: Basic List
- Scenario 2: Sorted list
- Scenario 3: Two-level navigation list
- Scenario 4: Three-level navigation list
- Scenario 5: Using a page variable to select the YAML list
- Scenario 6: Applying the active class for the current page
- Scenario 7: Including items conditionally
- Scenario 8: Retrieving items based on front matter properties
Scenario 1: Basic List
You want to return a basic list of pages.
YAML
docs_list_title: ACME Documentation
docs:
- title: Introduction
url: introduction.html
- title: Configuration
url: configuration.html
- title: Deployment
url: deployment.html
Liquid

{{ site.data.samplelist.docs_list_title }}

{% for item in site.data.samplelist.docs %}

{{ item.title }}

{% endfor %}

Result
ACME Documentation
For the results in these fictitious samples, #
is manually substituted for the actual link value to avoid 404 errors.)
When you use a for
loop, you choose how you want to refer to the items you’re looping through. The variable you choose (in this case, item
) becomes how you access the properties of each item in the list. Dot notation is used to get a property of the item (for example, item.url
).
The YAML content has two main types of formats that are relevant here:
- mapping
- list
docs_list_title: ACME Documentation
is a mapping. You access the value with site.data.samplelist.docs_list_title
.
docs:
is a list. The list begins each item with a hyphen. Unlike with mappings, you usually don’t access list properties directly as you do with mappings. If you want to access a specific item in the list, you must identify the position in the list you want, following typical array notation. For example, site.data.samplelist.docs[0]
would access the first item in the list. However, this is rarely done.
With lists, you usually use for
loops to cycle through the list of items and do something with each item. With navigation menus, you usually insert each list item into li
tags based on the navigation structure you’re using in your HTML theme.
Each hyphen (-
) indicates another item in the list. This example just has two properties with each list item: title
and url
. You can include as many properties as you want for each item. The order of properties at each position in the list doesn’t matter.
Scenario 2: Sorted list
Suppose you wanted to sort the list by the title
. To do this, convert the reference to the docs
collection to a variable, and then apply Liquid’s sort
filter to the variable:
Liquid
{% assign doclist = site.data.samplelist.docs | sort: 'title' %}

{% for item in doclist %}

{{ item.title }}

{% endfor %}

Result
The items now appear in alphabetical order. The sort
property in the Liquid filter applies to the title
, which is an actual property in the list. If title
weren’t a property, we would need to sort by another property.
See the Liquid array filter for more filter options. Note that you can’t simply use this syntax:
{% for item in site.data.samplelist.docs | sort: "title" %}{% endfor %}
You have to convert site.data.samplelist.docs
to a variable first using either assign
or capture
tags.
Scenario 3: Two-level navigation list
Suppose you want a more robust list that incorporates multiple sections of heading titles and subitems. To do this, add an additional level to each list item to store this information:
YAML
toc:
- title: Group 1
subfolderitems:
- page: Thing 1
url: /thing1.html
- page: Thing 2
url: /thing2.html
- page: Thing 3
url: /thing3.html
- title: Group 2
subfolderitems:
- page: Piece 1
url: /piece1.html
- page: Piece 2
url: /piece2.html
- page: Piece 3
url: /piece3.html
- title: Group 3
subfolderitems:
- page: Widget 1
url: /widget1.html
- page: Widget 2
url: /widget2.html
- page: Widget 3
url: /widget3.html
Liquid
{% for item in site.data.samplelist.toc %}

{{ item.title }}

{% for entry in item.subfolderitems %}

{{ entry.page }}

{% endfor %}

{% endfor %}
Result
In this example, Group 1
is the first list item. Within that list item, its subpages are included as a property that itself contains a list (subfolderitems
).
The Liquid code looks through the first level with for item in site.data.samplelist.toc
, and then looks through the second-level property with for entry in item.subfolderitems
. Just as item
is an arbitrary name for the items we’re looping through, so is entry
.
Scenario 4: Three-level navigation list
Building on the previous section, let’s add one more level of depth (subsubfolderitems
) to the list. The formatting will get more complex here, but the principles are the same.
YAML
toc2:
- title: Group 1
subfolderitems:
- page: Thing 1
url: /thing1.html
- page: Thing 2
url: /thing2.html
subsubfolderitems:
- page: Subthing 1
url: /subthing1.html
- page: Subthing 2
url: /subthing2.html
- page: Thing 3
url: /thing3.html
- title: Group 2
subfolderitems:
- page: Piece 1
url: /piece1.html
- page: Piece 2
url: /piece2.html
- page: Piece 3
url: /piece3.html
subsubfolderitems:
- page: Subpiece 1
url: /subpiece1.html
- page: Subpiece2
url: /subpiece2.html
- title: Group 3
subfolderitems:
- page: Widget 1
url: /widget1.html
subsubfolderitems:
- page: Subwidget 1
url: /subwidget1.html
- page: Subwidget 2
url: /subwidget2.html
- page: Widget 2
url: /widget2.html
- page: Widget 3
url: /widget3.html
Liquid

{% if site.data.samplelist.toc2[0] %}
{% for item in site.data.samplelist.toc2 %}

{{ item.title }}

{% if item.subfolderitems[0] %}

{% for entry in item.subfolderitems %}

{{ entry.page }}
{% if entry.subsubfolderitems[0] %}

{% for subentry in entry.subsubfolderitems %}

{{ subentry.page }}

{% endfor %}

{% endif %}

{% endfor %}

{% endif %}
{% endfor %}
{% endif %}

Result
Group 1
Group 2
Group 3
In this example, if site.data.samplelist.toc2[0]
is used to ensure that the YAML level actually contains items. If there isn’t anything at the [0]
position, we can skip looking in this level.
ProTip: Line up for
loops and if
statements
To keep the code clear, line up the beginning and ending Liquid tags, such as the for
loops and if
statements. This way you know when the open tags have been closed. If the code will appear in a Markdown page, keep the opening and closing HTML tags flush against the left edge so that the Markdown filter won't treat the content as a code sample. If necessary, you can wrap the entire code sample in a div
tag to ensure the code has HTML tags that bookend the code.
Scenario 5: Using a page variable to select the YAML list
Suppose your sidebar will differ based on various documentation sets. You might have 3 different products on your site, and so you want 3 different sidebars — each unique for that product.
You can store the name of the sidebar list in your page front matter and then pass that value into the list dynamically.
Page front matter
---
title: My page
sidebar: toc
---
Liquid

{% for item in site.data.samplelist[page.sidebar] %}

{{ item.title }}

{% endfor %}

Result
In this scenario, we want to pass values from the page’s front matter into a for
loop that contains a variable. When the assigned variable isn’t a string but rather a data reference, you must use brackets (instead of curly braces) to refer to the front matter’s value.
For more information, see Expressions and Variables in Liquid’s documentation. Brackets are used in places where dot notation can’t be used. You can also read more details in this Stack Overflow answer.
Scenario 6: Applying the active class for the current page
In addition to inserting items from the YAML data file into your list, you also usually want to highlight the current link if the user is viewing that page. You do this by inserting an active
class for items that match the current page URL.
CSS
.result li.active a {
color: lightgray;
cursor: default;
}
Liquid
{% for item in site.data.samplelist.docs %}

{{ item.title }}

{% endfor %}
Result
In this case, assume Deployment
is the current page.
To make sure the item.url
(stored in the YAML file) matches the page.url
, it can be helpful to print the {{ page.url }}
to the page.
Scenario 7: Including items conditionally
You might want to include items conditionally in your list. For example, maybe you have multiple site outputs and only want to include the sidebar item for certain outputs. You can add properties in each list item and then use those properties to conditionally include the content.
YAML
docs2_list_title: ACME Documentation
docs2:
- title: Introduction
url: introduction.html
version: 1
- title: Configuration
url: configuration.html
version: 1
- title: Deployment
url: deployment.html
version: 2
Liquid

{% for item in site.data.samplelist.docs2 %}
{% if item.version == 1 %}

{{ item.title }}

{% endif %}
{% endfor %}

Result
The Deployment
page is excluded because its version
is 2
.
Scenario 8: Retrieving items based on front matter properties
If you don’t want to store your navigation items in a YAML file in your _data
folder, you can use for
loops to look through the YAML front matter of each page or collection and get the content based on properties in the front matter.
In this scenario, suppose we have a collection called _docs
. Collections are often better than pages because they allow you to narrow the list of what you’re looping through. (Try to avoid scenarios where you loop through large numbers of items, since it will increase your build time. Collections help you narrow the scope.)
In our scenario, there are 6 docs in the docs
collection: Sample 1, Sample 2, Topic 1, Topic 2, Widget 1, and Widget 2.
Each doc in the collection contains at least 3 properties in the front matter:
title
category
order
The front matter for each page is as follows (consolidated here for brevity):
---
Title: Sample 1
category: getting-started
order: 1
---
---
Title: Sample 2
category: getting-started
order: 2
---
---
Title: Topic 1
category: configuration
order: 1
---
---
Title: Topic 2
category: configuration
order: 2
---
---
Title: Widget 1
category: deployment
order: 1
---
---
Title: Widget 2
category: deployment
order: 2
---
Note that even though category
is used in the doc front matter, category
is not a built-in variable like it is with posts. In other words, you cannot look directly inside category
with site.docs.category
.
If you wanted to simply get all docs in the collection for a specific category, you could use a for
loop with an if
condition to check for a specific category:

Getting Started

{% for doc in site.docs %}
{% if doc.category == "getting-started" %}

{{ doc.title }}

{% endif %}
{% endfor %}

The result would be as follows:
This might be useful if you’re setting up a knowledge base and have dozens of topics in each category, with each category displaying on its own page.
But let’s say you want to sort the items by category and group them under the category name, without hard-coding the category names. To achieve this, you could use two filters:
group_by
sort
Here’s the code for getting lists of pages grouped under their corresponding category headers:
Liquid
{% assign mydocs = site.docs | group_by: 'category' %}
{% for cat in mydocs %}

{{ cat.name | capitalize }}

{% assign items = cat.items | sort: 'order' %}
{% for item in items %}

{{ item.title }}

{% endfor %}

{% endfor %}
Result
Let’s walk through the code. First, we assign a variable (mydocs
) to the collection content (site.docs
).
The group_by
filter groups the collection content by category
. More specifically, the group_by
filter converts mydocs
into an array with name
, items
, and size
properties, somewhat like this:
[
{"name": "getting-started", "items": [Sample 1, Sample 2],"size": 2},
{"name": "configuration", "items": [Topic 1, Topic 2], "size": 2},
{"name": "deployment", "items": [Widget 1, Widget 2, "size": 2}
]
Using for cat in mydocs
, we look through each item in the mydocs
array and print the category name
.
After getting the category name, we assign the variable items
for the docs and use the sort
filter to arrange the docs by their order
property. The dot notation cat.items
is used because we’re accessing the content in the items
array. The sort
filter orders the items by their numbers in ascending order.
The for item in items
loop looks through each item
and gets the title
and url
to form the list item link.
For more details on the group_by
filter, see Jekyll’s Templates documentation as well as this Siteleaf tutorial. For more details on the sort
filter, see sort in Liquid’s documentation.
Whether you use properties in your doc’s front matter to retrieve your pages or a YAML data file, in both cases you can programmatically build a more robust navigation for your site.


jQuery Events
jQuery Events
jQuery Events
Click Me Fade
Click Me Slide
Seriously Don't Click Me
This is your last warning!
Please don't fade me!
I'm begging you, please!
Help help help!!


Patient Profile
General Details
Firstname:
Lastname:
Gender:
Date Of Birth:
Contact Number:
Medical Details
Blood Group:
Medical History:
Reason of admitants:
Allergies:


Ready to get started? Call or send me an email, and I will reach out as soon as possible!
1-310-497-7157
ejglickmanmedia@gmail.com


Beautifully designed HTML5 & CSS3 Themes & Templates. Responsive & Bootstrap based.
All themes are based on Bootstrap & supports all its features.
Made using well known Web Tools. No more slicing of PSD UI Kits.
All Themes works great on PCs, Tablets and Phones. 100% Responsive.
Some themes supports LESS. All future themes supports LESS.
You no need to pay a penny. Free for personal and commercial use.
100% Free for personal & commercial use. No link back necessary.
Released under MIT License. You are Free to Copy, Redistribute, Transform, Build upon. Free for Personal & Commercial use. No need to give any credits or link back.
If you have any design Ideas or Comments - Tweet @ashobiz


In this chapter you may find some interesting information about using the mail logging writer. But before continue reading please note, that sending of each logging message e–mail is done in its own thread.
Below can be found a fully qualified example of how to use the mail logger settings.
using Plexdata.LogWriter.Abstraction;
using Plexdata.LogWriter.Extensions;
using Plexdata.LogWriter.Logging;
using Plexdata.LogWriter.Settings;
using System;
using System.Collections.Generic;
using System.Text;
namespace MailLoggerExample
{
class Program
{
static void Main(String[] args)
{
IMailLoggerSettings settings = new MailLoggerSettings()
{
LogLevel = LogLevel.Trace,
Address =<EMAIL_ADDRESS>Username = "username",
Password = "password",
SmtpHost = "mail.example.org",
SmtpPort = 587,
UseSsl = true,
Encoding = Encoding.UTF8,
Subject = "Logger Mail",
Receivers = new List<String>() {
<EMAIL_ADDRESS><EMAIL_ADDRESS>},
ClearCopies = new List<String>() {
<EMAIL_ADDRESS><EMAIL_ADDRESS>},
BlindCopies = new List<String>() {
<EMAIL_ADDRESS><EMAIL_ADDRESS>}
};
IMailLogger logger = new MailLogger(settings);
logger.Trace("This is a Trace logging entry.");
logger.Debug("This is a Debug logging entry.");
logger.Verbose("This is a Verbose logging entry.");
logger.Message("This is a Message logging entry.");
logger.Warning("This is a Warning logging entry.");
logger.Error("This is a Error logging entry.");
logger.Fatal("This is a Fatal logging entry.");
logger.Critical("This is a Critical logging entry.");
}
}
}
With the above settings in mind each logging message is sent by e–mail to all in all six recipients.
The dependency injection of the mail logger works pretty much the same way as it works for the console logger. Thus, an explicit explanation does not really be useful right here.
Last but not least, a fully qualified configuration example as JSON can be seen here.
{
"Plexdata": {
"LogWriter": {
"Settings": {
"LogLevel": "Trace",
"LogTime": "Utc",
"LogType": "Raw",
"ShowTime": true,
"PartSplit": ";",
"TimeFormat": "s",
"FullName": false,
"Culture": "en-US",
"Address"<EMAIL_ADDRESS>"Username": "username",
"Password": "password",
"SmtpHost": "mail.example.org",
"SmtpPort": 587,
"UseSsl": true,
"Encoding": "utf-8",
"Subject": "Logger Mail",
"Receivers": [
<EMAIL_ADDRESS><EMAIL_ADDRESS>],
"ClearCopies": [
<EMAIL_ADDRESS><EMAIL_ADDRESS>],
"BlindCopies": [
<EMAIL_ADDRESS><EMAIL_ADDRESS>]
}
}
}
}


We create cards with the latest technology i.e RFID. This technology is used when you want to store some sort of information in the identity cards. This information can be used to authenticate particular student, employee etc.
Schools, colleges and universities utilize secure ID cards to foster a safe learning environment, often combining access control, identification and transactional applications into one card for flexibility and convenience. Shyam Sharnam Cards:- school ID systems make it easy and affordable to integrate new ID card technologies that make campus life more efficient for everyone.


For a thorough explanation of these examples, see the Lost Decade Games blog.
Play Loop
View source
Play Pause Stop
Current time: 0
Set
Volume: Set


The 'Access Record - Structured' capability is not available in version 1.1.1 of the GP Connect specification.
'Access Record - Structured' will be implemented in an upcoming release.


Platform radio buttons created with given list of string values and have validation error
Selected value: {{ form1.controls.radiol1.value }}
Platform radio button with None (No selection) value created as an Option
Selected value: {{ form2.controls.radiol2.value }}
Radio group using FormGroup and FormControl
Selected value: {{ form3.controls.month.value }}
Creating platform radio button with list of string values also pre-selection based on control value
Selected value: {{ favoriteOption }}
Creating platform radio button with given list of string values
Selected value: {{ favoriteOption2 }}


To measure success in a way that we can compare one to another, we must have a common understanding about what we mean by success and what we mean by measurement. Some key requirements of achieving success are not overtly teachable, measurable, or relevant for everyone. Determining what success looks like is difficult, as the qualities of a successful student can be different in given contexts. Therefore, to have a universal measurement system that works to any degree of accuracy often means that objective and quantifiable metrics are chosen over subjective and qualitative metrics – and the former of which may be poor indicators of success for a multifaceted design program. In other words, the nature of real learning limits what we can reasonably measure.
In many educational institutions, the grade point average (GPA) measures a student's ability to meet the success metrics as set by an instructor or governing assessment entity. There may be some correlation between GPA and success post graduation, but a high GPA does not guarantee a person will get a job or start a business, become well-rounded, or be prepared for the unexpected challenges ahead. A student's attitude and grit are the best indications of success after graduation.
I have assembled a list that attempts to describe the attitudes and attributes that are likely to indicate success:


--- layout: snippet title: "Jumbotron example" permalink: /examples/jumbotron/basic/ sitemap: false ---
This is a simple hero unit, a simple jumbotron-style component for calling extra attention to featured content or information.
It uses utility classes for typography and spacing to space content out within the larger container.


Apple Software is like Windows Hardware
I’ve recently been on a committee at work to select a Windows touchscreen laptop. We’ve tested a number of machines, and it’s only served to reinforce what I already knew to be true: most mainstream Windows hardware is trash.
No. That’s a bit too harsh.
Overall, Windows hardware can be ok, but it never feels cohesive. There’s always something that feels janky at best and downright awful more often than not. Why?
Any piece of Windows hardware comes from multiple vendors (as does Apple’s, but there’s a different level of quality control happening there): the trackpad feels disconnected from the UI or has flimsy buttons or strange scrolling behavior or unreliable tap and drag functionality or sketchy multi-finger gestures.
The same can be said for touchscreen materials and behaviors, keyboards (including key layouts!), fingerprint readers, charging solutions, hinges, speakers, and so on. On every machine, there’s at least one (usually a couple) that come from a subcontractor and more importantly feel like they do.
The truth is that these machines are a hodgepodge of commodity components slapped together into a box cheap enough that customers will buy it based on one of its better qualities.
Alright, enough bashing of Windows machines. Let’s get to the point.
In recent years Apple software seems to have the reputation of being in decline. I’m not here to say one way or another, but I have noticed that Apple software has become increasingly like the Windows hardware described above—a hodgepodge of components that against all odds seems to work most of the time (less and less often as time goes by).
I understand that software in general is a clever illusion built atop a cacophony of Rube Goldberg machines.
In Apple’s case the poster child for this theory is Siri. Each of its features, while intriguing and even impressive in some cases when they work, don’t function as a coherent whole. Context works, sometimes. But not when referring to certain topics. Trivia works, in a few particular domains. Apps can use Siri, but only specific types, and even then with bizarre results and incoherent behaviors.
Thing is, it’s not only Siri.
MacOS has slowly been working its way toward the same state: tags, tabs, back to the Mac visuals and their removal, iOS influenced app designs, apps that live mostly in the Menu Bar, Save As, and so on.
WatchOS for sure has the problem, with its first gen apps versus newer versions versus companies discontinuing their WatchOS apps altogether, the honeycomb launcher, differing notification types, and a somewhat confused mixed interaction model (touch, force-press, crown).
Even iOS has come to this with different behaviors on different phone models (and iPad models) and legacy apps that haven’t been updated for recent hardware like the iPhone X.
Meanwhile Apple’s hardware has none of these problems. Oh, it has problems of course (I’m looking at you, ever worsening butterfly key switch situation) but even when it does, the user never gets the sense that it is because the components aren’t from the same company. At least on hardware, users get the sense that it’s all from Apple, and any issue is due to a mistake in the design rather than assuming that the keyboard sucks because they cheaped out and bought a component from a lesser subcontractor.
Unfortunately with software it increasingly feels as if there are at best multiple Apple software companies that all do things a little differently from one another, and at worst that even under the umbrella of one product, the components of that software are made by entirely different companies with different priorities, and severely differing quality levels.
When this is the case, the whole product suffers and likely gives the user a lackluster experience when things go right, and a broken, miserable experience when they don’t.


In this post, all the available lexical resources, particularly dictionaries, for the Kurdish language are listed. This is the result of a recent work where we carried out a comprehensive study on the existing resources. Find out more about this work at https://sinaahmadi.github.io/resources/kurdishlex.html.
Please note that all the tables are sortable (by clicking on the name of the column) and only 10 rows are shown by default. You can search in the table or change the number of the rows.
This post is being constantly updated. If you are aware of a resource which is not mentioned, please ping me by email.
[March 2023] The post is updated with more resources in Zazaki thanks to the suggestions of Bilal Zilan.
| # | Name | Link | Type | Source | Target | Orthography |
|---|---|---|---|---|---|---|
| 1 | Dicts.info | link | Bilingual | Sorani/Kurmanji | 70 languages | Persian-Arabic/Latin |
| 2 | Wiktionary | link | Multilingual | All dialects | All languages | Persian-Arabic/Latin |
| 3 | Henbana Borîne (via Vejinbooks) | link | Bilingual/Monolingual | Sorani | Persian | Persian-Arabic |
| 4 | Xal (via Vejinbooks) | link | Monolingual | Sorani | Sorani | Persian-Arabic |
| 5 | Wişename (via Vejinbooks) | link | Cross-dialectal | Hawrami | Sorani | Persian-Arabic |
| 6 | Endêk (via Vejinbooks) | link | Bilingual | English | Sorani | Persian-Arabic |
| 7 | Kanî (via Vejinbooks) | link | Cross-dialectal | Kurmanji | Sorani | Persian-Arabic |
| 8 | Dictio | link | Bilingual | Sorani | English | Persian-Arabic |
| 9 | Enahita | link | Monolingual/Bilingual | All dialects | English | Persian-Arabic/Latin |
| 10 | Ferheng.org (=FreeDict) | link | Multilingual | Kurmanji | Turkish/German/English | Latin |
| 11 | Kawa | link | Bilingual | Sorani | Persian | Persian-Arabic |
| 12 | The Kurdish dictionary | link | Multilingual | Sorani/Kurmanji | Turkish/Spanish/Persian/Arabic/Swedish | Persian-Arabic/Latin |
| 13 | Hakkarim.net | link | Bilingual | Kurmanji | Turkish | Latin |
| 14 | Ferheng.com (Scientific Terms) | link | Multilingual | Sorani | English/Arabic | Persian-Arabic |
| 15 | tirsik.net | link | Multidialectal | Kurmanji | Many languages | Latin |
| 16 | Grûba Xebate ya Vateyî | link | Bilingual | Zazaki | Turkish | Latin |
The following table contains all the printed dictionaries dealing with the Kurdish language. The following information are provided for each resource:
| # | Author | Type | Year | Source | Target | # Entries | Script | Content |
|---|---|---|---|---|---|---|---|---|
| 1 | Garzoni | bilingual | 1787 | Italian | Kurmanji | 5250* | ~Latin | translation |
| 2 | Jaba | bilingual | 1879 | Kurmanji | French | 14340* | ~Persian-Arabic and ~Latin | translation, example sentences |
| 3 | Mokri | bilingual | 1892 | Kurmanji | Arabic | 7200* | ~Persian-Arabic | translations, present stem of verbs |
| 4 | Mukryani | bilingual | 1950 | Arabic | Sorani | 15000 | Persian-Arabic | translations |
| 5 | Bakaev | bilingual | 1957 | Kurmanji | Russian | 14000 | Cyrillic | translations, gender, expressions, variant forms |
| 6 | Farizov | bilingual | 1957 | Russian | Kurmanji | 30000 | Latin | translations, gender, expressions, variant forms |
| 7 | Siabandov & Châchân | bilingual | 1957 | Armenian | Kurmanji | 23000 | Cyrillic | translation |
| 8 | Kurdoev | bilingual | 1960 | Kurmanji | Russian | 34,000 | Cyrillic | detailed translations with polysemy, gender, expressions, variant forms |
| 9 | Xal | monolingual | 1960 | Sorani | Sorani | 22000* | Persian-Arabic | definition, synonyms |
| 10 | Mukryani | bilingual | 1961 | Sorani | Arabic | 30000 | Persian-Arabic | translations |
| 11 | Bedirxan & Keskin | monolingual | 1962 | Kurmanji | Kurmanji | 15000* | Latin | synonyms |
| 12 | Blau | multilingual | 1965 | Kurmanji | (French-English) | 6000* | Latin | translations, gender, present stem of verbs, limited POS |
| 13 | Wahby & Edmonds | bilingual | 1966 | Sorani | English | 6500* | ~Latin, Persian-Arabic | POS, synonyms and variant forms, rich description |
| 14 | Mukryani | multilingual | 1966 | Sorani | (Persian-Arabic-English-French) | 4000* | Persian-Arabic | translations |
| 15 | MacKenzie | bilingual | 1966 | Hawrami | English | 1000 | ~Latin | translation, POS, gender, idioms, example sentences, variant forms |
| 16 | Anter | bilingual | 1967 | Kurmanji | Turkish | ? | Latin | simple translations |
| 17 | Blau | bilingual | 1975 | (Kurmanji-Sorani) | French and English | 2000* | Latin | translation, gender, POS |
| 18 | Gharib | multilingual | 1975 | Arabic | Sorani and English, | 1000* | Persian-Arabic and Latin | illustrations |
| 19 | Keidane et al. | bilingual | 1977 | Sorani | Russian | 2100 | Persian-Arabic | translation |
| 20 | Paşa & Bozarslan | bilingual | 1978 | Kurmanji | Turkish | 7200* | Latin | simple translations, present stem of verbs |
| 21 | Izad-panah | multilingual | 1978 | (Lori- Laki) | * (Sorani-Persian) | 4800* | Persian-Arabic | translations |
| 22 | Kurdoev & Yusupova | bilingual | 1983 | Sorani | Russian | 25000 | Persian-Arabic | translations, POS, gender, expressions, variant forms |
| 23 | Gewranî | bilingual | 1985 | Kurmanji | Turkish | 25000* | Latin | translations |
| 24 | Zîlan | bilingual | 1989 | Swedish | Kurmanji | 5000 | Latin | translations, synonyms, illustrations |
| 25 | Sharafkandi | multilingual | 1991 | Sorani | (Sorani-Persian) | 60000 | ~Persian-Arabic | translations, synonyms |
| 26 | Izoli | bilingual | 1992 | Turkish | Kurmanji | 25000-30000 | Latin | translations, definitions, gender, POS |
| 27 | Rizgar | bilingual | 1993 | Kurmanji | English | 15000 | Latin | translations, POS, gender, synonyms, expressions, variant forms |
| 28 | Darvishian | bilingual | 1997 | Southern Kurdish | Persian | ? | Persian-Arabic | translation, pronunciation |
| 29 | Özcan | bilingual | 1997 | Zaza | Turkish | Latin | ||
| 30 | Saadalla | bilingual | 1998 | English | Kurmanji | 72000 | Persian-Arabic | translation, gender |
| 31 | Qazzaz | bilingual | 2000 | Sorani | English | 10000* | Persian-Arabic/Latin | translation, synonyms, POS, idioms, proverbs |
| 32 | Saadalla | bilingual | 2000 | English | Kurmanji | 72000 | Latin | translation, POS |
| 33 | Turgut | bilingual | 2001 | Zaza | Turkish | ? | Latin | ? |
| 34 | Khalidgul | bilingual | 2002 | Persian | Kurmanji | 4000 | Persian-Arabic | translations |
| 35 | Chyet & Schwartz | bilingual | 2003 | Kurmanji | English | 59360* | Persian-Arabic/Latin | translations, POS, gender, expressions, synonyms, variant forms, etymology, example sentence |
| 36 | Demîrhan | monolingual | 2003 | Kurmanji | Kurmanji | 19680* | Latin | ? |
| 37 | Nizameddin | bilingual | 2003 | Sorani | Arabic | 13650* | Persian-Arabic | translations, synonyms |
| 38 | M. Amin | multilingual | 2003 | English | (Sorani-P-A) | 35000* | Persian-Arabic | translation |
| 39 | Mukryani | bilingual | 2005 | Arabic | Sorani | 25000 | Persian-Arabic | translations |
| 40 | Nanwazade | monolingual | 2005 | Sorani | Sorani | 10000* | Persian-Arabic | definitions, etymology, idioms |
| 41 | Botî | monolingual | 2006 | Kurmanji | Kurmanji | 15000* | Latin | gender, definition, synonyms |
| 42 | Arif | bilingual | 2006 | Persian | Sorani | 36300 | Persian-Arabic/Latin | translations |
| 43 | Selma Abdallah | bilingual | 2006 | Sorani | English | 3300* | Persian-Arabic/Latin | translations |
| 44 | Karadaghi | bilingual | 2006 | English | Sorani | 44000 | L and P-A | translations |
| 45 | Mukryani | monolingual | 2007 | Sorani | Sorani | 3000* | Persian-Arabic | ? |
| 46 | Abdollahpour | bilingual | 2008 | Persian | Sorani | 28000 | Persian-Arabic | translations, synonyms |
| 47 | Ebrahimpour | bilingual | 2008 | Sorani | English | 40800* | Persian-Arabic/Latin | translation |
| 48 | Turgut | bilingual | 2008 | Turkish | Zaza | ? | Latin | ? |
| 49 | Jalilian | multilingual | 2009 | Southern Kurdish | (Sorani-Persian) | 31600 | Persian-Arabic/Latin | translations, example sentences |
| 50 | Habiballah | monolingual | 2009 | Hawrami | Sorani | 56000* | Persian-Arabic | synonyms |
| 51 | Mayi | bilingual | 2009 | Kurmanji | Arabic | 20700* | Persian-Arabic/Latin | translation, definitions |
| 52 | Shawkat | bilingual | 2009 | Sorani | English | 35000* | Persian-Arabic/Latin | Synonyms, POS, pronunciation |
| 53 | Kiani Kolivand | bilingual | 2011 | Laki | Persian | 30000 | ? | translations, etymology |
| 54 | Nahid | multilingual | 2011 | Sorani | (Sorani-Persian) | 21000* | Persian-Arabic | translation |
| 55 | Hakem | bilingual | 2012 | Sorani | French | ? | Persian-Arabic | ? |
| 56 | Nawkhosh | bilingual | 2012 | Sorani | Arabic and English | 3000* | Persian-Arabic/Latin | synonyms |
| 57 | M. Rohani | bilingual | 2012 | Persian | Sorani | 18500 | Persian-Arabic | translation, pronunciation, POS, idioms, example sentences, variant forms, synonyms |
| 58 | Sohrabi & Sreshabadi | multilingual | 2012 | Garusi | (Sorani-Persian) | 8000 | Persian-Arabic | translation, pronunciation |
| 59 | Ulumaskan | bilingual | 2016 | Kurmanji | German | 25000 | Latin | ? |
| 60 | M. Rohani | multilingual | 2018 | Sorani | (Sorani-Persian) | 93000 | Persian-Arabic | translation, POS, idioms, example sentences, variant forms |
| 61 | Chyet | Bilingual | 2020 | Kurmanji | English | ? | Persian-Arabic and Latin | translation, POS, idioms, example sentences, variant spellings, synonyms, regional usage, etymologies |
| 62 | Chyet | Bilingual | 2020 | English | Kurmanji | ? | Persian-Arabic and Latin | translation, POS, idioms, example sentences, variant spellings, synonyms, regional usage, etymologies |
| 63 | Malmîsanij | Bilingual | 1992 | Zazaki | Turkish | ? | Latin | translation, POS, idioms, example sentences |
| 64 | Munzur Çem | Bilingual | 1994 | Zazaki | Turkish | ? | Latin | translation, POS, idioms, example sentences |
| 65 | Çeko Kocadag | Bilingual | 2010 | Zazaki | Kurmanji | ? | Latin | translation, POS, idioms, example sentences |
| 66 | Roşan Lezgîn | Bilingual | 2013 | Zazaki | Turkish | ? | Latin | translation, POS, idioms, example sentences |
| # | Author | Name | Link | Year | # Entries | Resource language | Script |
|---|---|---|---|---|---|---|---|
| 1 | Dr. Abdullah Ibrahimsadeh | Raman Dictionary of Kurdish etymology | link (Vol. 1, Vol. 2) | 2014 | ~1200 pages | Sorani Kurdish | Persian-Arabic/Latin |
| 2 | Ali Nanvazadeh | The Kurdish etymological dictionary | - | 2017- | - | Sorani Kurdish | Persian-Arabic/Latin |
| 3 | Ali Husein Kerim | The Kurdish etymological dictionary (comparative) | link (sample) | 2019 | ~640 pages | Turkish | Turkish |
| 4 | R. L. Tsabolov | Etymological Dictionary of Kurdish | link | 689 pages | 2001 | Russian | Cyrillic |
If you are using these data in your research, please don't forget to cite the paper:
@inproceedings{ahmadi2019kurdishlex,
title = "Towards Electronic Lexicography for the {K}urdish Language",
author = "Ahmadi, Sina and Hassani, Hossein and McCrae, John P.",
booktitle = "Proceedings of the sixth biennial conference on electronic lexicography (eLex)",
month = "10",
year = "2019",
address = "Sintra, Portugal",
url = "https://elex.link/elex2019/wp-content/uploads/2019/09/eLex_2019_50.pdf",
pages = "881--906",
address= "Sintra, Portugal"
}
Last updated on 19 March 2020.


Question 1: What is the difference between following 2 functions if any? function checkAge(age) { if (age > 18) { return true; } else { return confirm('Did parents allow you?'); } } function checkAge(age) { if (age > 18) { return true; } return confirm('Did parents allow you?'); }
Both functions do the same thing: they shoot a question if user is under 18.
But the second example is something called as guard clause.
Here we are basically checking for a condition, i.e. if the user is already 18 years old.
If he is, then we don't need to proceed ahead.
Unnecessary nesting is avoided using guard clauses.
Question 2: Rewrite above function using ternary operator
This won't work, it throws an error "Unexpected token return"
The ternary operator isn't meant to execute an action but rather to yield a value.
return is a statement. It does not evaluate to anything. We are using a ternary operator, which has the syntax - condition ? expression1 : expression2
and evaluates to expression1 if the condition holds, and expression2 otherwise. This implies that expression1 and expression2 must themselves evaluate to something, and cannot be statements.
Question 3: WAF to find min value from 2 numbers using ternary operators
function minValue(a,b){
var min;
(a < b) ? min = a : min = b
document.write("Minimum value is:"+""+min);
}
minValue(60, 40);
Question 4: WAF to find prime numbers from 1-100
function printPrime(){
for (var counter = 2; counter <= 100; counter++) { //prime nos start from 2
document.write("Prime numbers between 1 and 100 are:"+"
");
var notPrime = false; //set flag
for (var i = 2; i <= counter; i++) {
if (counter%i=0 && i!=counter) { // prime num is num div by 1 and itself. check if it is divisible by any other number and set flag true if it is.
notPrime = true;
}
}
if (notPrime === false ) { // for all prime nums, print them
document.write(counter + "
");
}
}
}
printPrime();
Question 5: Implement IIFE
(function(){
var x= 5 , y= 6;
document.write(x+"
"+y);
})();
document.write(x); //x is not defined error, since x, y become private to the iife
Question 6: Demonstrate difference between function declaration and expression
The difference lies in how the browser loads them into the execution context.
Function declarations load before any code is executed(since they get hoisted).
Function expressions load only when the interpreter reaches that line of code.
So if you try to call a function expression before it's loaded, you'll get an error.
If you call a function declaration instead, it'll always work, because no code can be called until all declarations are loaded.
Function expression:
alert(exprTest()); // ERROR! exprTest is not a function
var exprTest = function() { return 5; }
Function declaration:
alert(decTest()); // Alerts 5. Declarations are loaded before any code can run.
function decTest() { return 5; }
Question 7: WAF to multi 2/multiple numbers. (use function parameters/arguments)
function multiply(a,b){
return(a*b);
}
document.write(multiply(3,4));
Question 8: Implement previous assignments (Take any 5 examples.) using functions e.g.: get todays day, change bg, check age, etc. try to use pure functions.
1. Display the sum of 5 + 10, using two variables x and y.
function addNum(x,y){
var addition = x+y;
document.write(addition);
}
addNum(5,10);
2. Find greatest among 4 numbers
function greatest(){
var n1 = Number(prompt("Enter first number"));
var n2 = Number(prompt("Enter second number"));
var n3 = Number(prompt("Enter third number"));
var n4 = Number(prompt("Enter fourth number"));
var greatest;
if(n1>n2 && n1>n3 && n1>n4){
greatest = n1;
}
else if(n2>n1 && n2>n3 && n2>n4){
greatest = n2;
}
else if(n3>n1 && n3>n2 && n3>n4){
greatest = n3;
}
else{
greatest = n4;
}
alert("greatest number from entered numbers is"+" "+greatest );
}
3. Print/alert todays Day using switch & if-else. Also print a message saying "It is a weekend" if Saturday or Sunday! or be creative.
var day = new Date();
var today = day.getDay();
if(today == 0){
alert("It is Sunday. yes, tomorrow is Monday :p");
}else if(today == 1){
alert("It is Monday");
}else if(today == 2){
alert("It is Tuesday");
}else if(today == 3){
alert("It is Wednesday");
}else if(today == 4){
alert("It is Thursday");
}else if(today == 5){
alert("It is Friday");
}else{
alert("The weekend is here. it's Saturday! Yayyy");
}
4. Set the color (yellow:morning, blue:evening, black:night) of body tag based on your system time. showcase your creativity.
function changeColor(){
var d = new Date();
var time = d.getHours();
if(time >= 6 && time <=16){
document.body.style.backgroundColor = "yellow";
}
else if(time > 16 && time <20){
document.body.style.backgroundColor = "blue";
}
else if(time >=20 && time < 6){
document.body.style.backgroundColor = "black";
}
else{
alert("enter proper time");
}
}
changeColor();
5. Write a condition to check if the given age is of a teenager or no.
fucntion checkTeenager(){
var result, age = +prompt('age?', '');
(age <= 19 && age >= 13) ? result = 'teenager' : result = 'Not a teenager';
alert(result);
}
checkTeenager();
Question 9: WAF: To check if palindrome
function palindrome(str) { // declaring a function palindrome with argument str
var len = str.length; //check length of the string passed
for ( var i = 0; i < Math.floor(len/2); i++ ) { // in palindrome, apart from center letter(if present), other letters are exactly same at their particlular position, hence we only need to loop through half the length of the string
if (str[i] !== str[len - 1 - i]) { // here we check if the ith index matches with the same index from the other end, eg, in malayalam, we check if m matches with len-i-1 = 9-0-1 = 8 = m
return false; // if it does not match, it is not palindrome so we return false
}
}
document.write("palindrome"); // if it does not satisfy if statement, it implies that it is a palindrome. note that all letters are checked in the if condition since the if is within a for loop.
}
palindrome("malayalam"); //output: palindrome
Question 10:WAF: To generate fibonacci series upto user entered number eg: if user enters 6. output: 1 1 2 3 5 8
function generateFibo(){
var i, j = prompt("Enter in digits how many fibonacci numbers to generate: ","");
var fib = []; // Initialize array
fib[0] = 0;// every number in fibo series is a sum of prev 2 numbers. to start we initially need to declare 0 and 1, since their addition will kickstart the fibo sequence
fib[1] = 1;
document.write(fib[1]); // printing 1
for(i=2; i<=j; i++)
{
// Next fibonacci number = previous + one before previous
fib[i] = fib[i-2] + fib[i-1];
document.write(fib[i]);
}
}
generateFibo();
Question 11: create 3 pure functions
* to get the maximum value from the given array.
* to get the minimum value from the given array.
* get query parameter value from the url provided.
Get max value from array
function max(arr){
var max = arr[0]; //max variable is set to the first item in the array.
for(var i=1; i
max = arr[i]; //So, first time around it checks if arr[1] is greater then max. If yes, max is set to arr[1] First loop checks if (12 > 4) it is so max = 12
Second time around it checks if arr[2] is greater than max. Second loop checks if(3 > 12) it is not so max = 12
Third time around it checks if arr[3] is greater then max. Third loop checks if (8 > 12) it is not so max = 12
Fourth time around it checks if arr[4] is greater then max. Fourth loop checks if (0 > 12) it is not so max = 12
Fifth time around it checks if arr[5] is greater then max. Fifth loop checks if (22 > 12) it is so max = 22
Sixth time around it checks if arr[6] is greater then max. Sixth loop checks if (56 > 22) it is so max = 56
}
}
document.write(max); //The loop has finished and max is returned. max is 56
}
max([4,12,3,8,0,22,56]);
Get min value from array
function min(arr){
var min = arr[0];
for(var i=1; i
min = arr[i];
}
}
document.write(min);
}
min([4,12,3,8,0,22,56]);
Exactly similar to the max function, but here we set a min value and change it when arr[i] is less than min
Get query parameters
function getPara(){
//http://ruchira.com/index.php?type=product&id=1234
var queryString = location.search; // ?type=product&id=1234
var urlParams = new URLSearchParams(location.search);
urlParams.has('type'); // true
urlParams.get('id'); // 1234
urlParams.getAll('id'); // ["1234"]
urlParams.toString(); // type=product&id=1234
}
Question 12: make a header with navigation bar at 200px from the top of the screen, make the header sticky once you scroll past it.
See the Pen sticky header by Ruchira Prabhudesai (@ruchirap91) on CodePen.
Question 13: make 3 level navigation menu, using javascript. use hover/click to show child level menus
Question 14: implement tab switch functionality / name of tab and content should come from an object
See the Pen tabs by Ruchira Prabhudesai (@ruchirap91) on CodePen.


Enables diagnostic mode for the test platform and writes diagnostic messages to the specified file and to files next to it. The
process that is logging the messages determines which files are created, such as *.host_<date>.txt
for the test
host log, and *.datacollector_<date>.txt
for the data collector log.


The getResponseHeader() function is used to return specific header information from a resource, like length, server-type, content-type, last-modified, etc:
Url Requested:
Content-Type:
Length:
Last-Modified:
Server-Type:


Robots in the browser. Just like node-serialport but for browser apps.
Nodebots are awesome but HTML5 apps have access to a lot of APIs that make sense for robotics like the GamepadAPI, WebRTC Video and Data, Web Speech API, etc. Also you get a nice GUI and its easier to run. I have also made a fork of Johnny-Five to work with Browserify as well by modifying it's dependancy Firmata to use browser-serialport.
You will not be able to add this to your normal website.
This library only works in a Chrome Packaged App as this is the only way to get access to the serial ports API in the browser.
If you want help making your first Chrome App, read the "Create Your First App" tutorial.
There is currently no Firefox extension support but that might come soon if possible.
npm install browser-serialport
Opening a serial port:
var SerialPort = require("browser-serialport").SerialPort
var serialPort = new SerialPort("/dev/tty-usbserial1", {
baudrate: 57600
});
When opening a serial port, you can specify (in this order).
The options object allows you to pass named options to the serial port during initialization. The valid attributes for the options object are the following:
Note, we have added support for either all lowercase OR camelcase of the options (thanks @jagautier), use whichever style you prefer.
You MUST wait for the open event to be emitted before reading/writing to the serial port. The open happens asynchronously so installing 'data' listeners and writing before the open event might result in... nothing at all.
Assuming you are connected to a serial console, you would for example:
serialPort.on("open", function () {
console.log('open');
serialPort.on('data', function(data) {
console.log('data received: ' + data);
});
serialPort.write("ls\n", function(err, results) {
console.log('err ' + err);
console.log('results ' + results);
});
});
You can also call the open function, in this case instanciate the serialport with an additional flag.
var SerialPort = require("browser-serialport").SerialPort
var serialPort = new SerialPort("/dev/tty-usbserial1", {
baudrate: 57600
}, false); // this is the openImmediately flag [default is true]
serialPort.open(function (error) {
if ( error ) {
console.log('failed to open: '+error);
} else {
console.log('open');
serialPort.on('data', function(data) {
console.log('data received: ' + data);
});
serialPort.write("ls\n", function(err, results) {
console.log('err ' + err);
console.log('results ' + results);
});
}
});
You can also list the ports along with some metadata as well.
var serialPort = require("browser-serialport");
serialPort.list(function (err, ports) {
ports.forEach(function(port) {
console.log(port.comName);
console.log(port.pnpId);
console.log(port.manufacturer);
});
});
Browser-serialport doesn't as of 2.0.0 support parsers.
You can get updates of new data from the Serial Port as follows:
serialPort.on("data", function (data) {
sys.puts("here: "+data);
});
You can write to the serial port by sending a string or buffer to the write method as follows:
serialPort.write("OMG IT WORKS\r");
Enjoy and do cool things with this code.


source pages/_include/downloads.md file
Validator Pack and Definitions:
The following file contains all the value sets, profiles, extensions, list of pages and urls in the IG, etc defined as part of the this Implementation Guides.:
In addition there are format specific definitions files.
These files should be the first choice whenever generating any implementation artifacts since they contain all of the rules about what makes these US-Core profiles valid. Implementers will still need to be familiar with the content of the specification and profiles that apply in order to make a conformant implementation. See the overview on validating FHIR profiles and resources
Schematrons are also available and listed below:
Examples: all the examples that are used in this Implementation Guide available for download: