Plugin Directory

source: wp-songbook/tags/2.0.11/inc/class.ajax.php

Last change on this file was 1473597, checked in by sjiamnocna, 9 years ago

2.0.11

File size: 572 bytes
Line 
1<?php
2
3/**
4 * Songbook AJAX
5 *
6 * Uses WP AJAX to get data through Javascript
7 *
8 * @since       v. 2.0.
9 * @version     1.0
10 * @author      Sjiamnocna
11 * @copyright   (c) 2015 Sjiamnocna
12 *
13 */
14
15class songbook_ajax extends songbook_functions {
16
17    public function __construct() {
18        add_action('wp_ajax_gdocstitle', array($this, 'gdocstitle'));
19    }
20
21    function gdocstitle($url = false) {
22        $toret = $this->gettitle($url);
23
24
25        if (!$toret)
26            return $toret;
27        else
28            echo $toret;
29    }
30
31}
32
33$wpsb_ajax = new songbook_ajax();
Note: See TracBrowser for help on using the repository browser.