You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -10,6 +10,21 @@ Breinify's DigitalDNA API puts dynamic behavior-based, people-driven data right
10
10
11
11
The library provides several attributes, methods, and objects to simplify the usage of the Breinify API. Besides methods to actually send or retrieve data, it also includes general information (e.g., about the version and used configuration), as well as utilities. Thus, the following documentation is organized in three sections: *General Information*, *API*, and *Utilities (UTL)*.
Retrieves a lookup result from the engine. The function needs a valid API-key to be configured to succeed.
110
125
111
126
**Parameters**:
112
127
@@ -135,8 +150,57 @@ The library provides several attributes, methods, and objects to simplify the us
135
150
136
151
The utility library provides general functionality, which makes it easy to retrieve values from, e.g., the url or cookies. In addition, it simplifies the retrieval of values from the DOM-tree or the handling of events.
137
152
153
+
##### Breinify.UTL (general functions)
154
+
155
+
156
+
157
+
texts: function() { return []; },
158
+
text: function() { return null; },
159
+
md5: function () { return null; },
160
+
isEmpty: function() { return false; }
161
+
162
+
##### Breinify.UTL.events
163
+
164
+
For simplicity the library provides the possibility to handle/react to specific events triggered by the DOM-tree. Currently, two events are supported, i.e., *click* and *pageloaded*.
Gets all the cookies currently defined and accessible.
168
+
169
+
**Parameters**:
170
+
171
+
{string} **selector**: The CSS-selector to specify the element(s) to listen for click-events (see [jQuery Selectors](https://api.jquery.com/category/selectors/) for a detailled overview of available selectors).
172
+
173
+
{function} **func**: The function to execute when the event is captured. The function retrieves an *event* object which can be used to control the further processing. In addition, the handling function also has access to the DOM-element that the handler was bound to using *this*. For further details, have a look at [jQuery Event Handling](https://learn.jquery.com/events/inside-event-handling-function/).
174
+
175
+
{boolean} **onlyOnce**: Specify if the event should only be trigger at most once.
176
+
177
+
**Example Usage**:
178
+
```javascript
179
+
Breinify.UTL.events.click('body', function () {
180
+
window.alert('You clicked the document.');
181
+
});
182
+
```
183
+
<br/>
184
+
185
+
***Breinify.UTL.events.pageloaded(func)**:<br/>
186
+
Gets all the cookies currently defined and accessible.
187
+
188
+
**Parameters**:
189
+
190
+
{function} **func**: The function to execute when the event is captured. The function retrieves an *event* object which can be used to control the further processing. In addition, the handling function also has access to the DOM-element that the handler was bound to using *this*. For further details, have a look at [jQuery Event Handling](https://learn.jquery.com/events/inside-event-handling-function/).
191
+
192
+
**Example Usage**:
193
+
```javascript
194
+
Breinify.UTL.events.click('body', function () {
195
+
window.alert('The document is loaded.');
196
+
});
197
+
```
198
+
<br/>
199
+
138
200
##### Breinify.UTL.loc
139
201
202
+
The location part of the utilities contains functions to validate, match, or retrieve information from the url or parameters specified within.
0 commit comments