Exemplo n.º 1
0
 public function event($atts)
 {
     require_once WT_PLUGIN_PATH . 'admin/template.php';
     require_once WT_PLUGIN_PATH . 'admin/handlers.php';
     require_once WT_PLUGIN_PATH . 'dwoo/dwooAutoload.php';
     $dwoo = new Dwoo();
     if ($atts["id"]) {
         $event = new WT_Event($atts["id"]);
         $event->retrieve();
         if ($event->data) {
             $theme = new WT_Theme();
             return $theme->post_event($event->template(), false);
         }
     }
     return "";
 }
Exemplo n.º 2
0
        $genre = ucwords($genre);
        echo "<a class='ui-selectee' href='#'><strong>{$genre}</strong></a>";
    }
    ?>
	</div>	
	
<?php 
}
if ($_GET["page"] == "twitter") {
    $event = new WT_Event($_GET["event_id"]);
    $data = $event->retrieve();
    $event_id = $_GET["event_id"];
    $nonce = wp_create_nonce(WT_SOCIAL::NONCE_INSERT);
    if ($options["twitter_template"]) {
        $tpl = array();
        foreach ($event->template($data) as $key => $value) {
            $tpl["%" . $key . "%"] = $value;
        }
        $status = strtr($options["twitter_template"], $tpl);
    }
    ?>
<form>
	<div id="dialog-alert" class='wordtour-alert'></div>
	<input type="hidden" name="_twitter_nonce" value="<?php 
    echo $nonce;
    ?>
"></input>
	<input type="hidden" name="twitter_event_id" value="<?php 
    echo $event_id;
    ?>
"></input>