-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathflexslider.api.php
42 lines (38 loc) · 1.2 KB
/
flexslider.api.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
<?php
/**
* @file
* API documentation for FlexSlider.
*
* By design, FlexSlider should be entirely configurable from the web interface.
* However some implementations may require to access the FlexSlider library
* directly by using flexslider_add(). This will return an attached array that
* you may add to a render array.
*
* Here are some sample uses of flexslider_add().
*/
/**
* Attach flexslider to an element using the specified option set.
*
* This call will look for an HTML element with id attribute of "my_image_list"
* and return the JS settings to initialize FlexSlider on it using the option
* set named "default".
*/
$attached = flexslider_add('my_image_list', 'default');
/**
* Attach flexslider to an element using the library defaults.
*
* You also have the option of skipping the option set parameter if you want
* to run with the library defaults.
*/
$attached = flexslider_add('my_image_list');
/**
* Attach the flexslider library.
*
* Finally, you can simply attach the library.
* This method would assume you would take care of
* initializing a FlexSlider instance in your theme or custom javascript
* file.
*
* Ex: $('#slider').flexslider();
*/
$attached = flexslider_add();