|
@@ 146-149 (lines=4) @@
|
| 143 |
|
$table_name = $this->wpdb->prefix . 'timeshift_' . $post_type; |
| 144 |
|
$sql = "select * from $table_name where id=" . intval($_GET['timeshift']); |
| 145 |
|
$r = $this->wpdb->get_results($sql); |
| 146 |
|
if ($r && count($r) == 1) { |
| 147 |
|
$payload = unserialize($r[0]->post_payload); |
| 148 |
|
$this->timeshift_cached_meta = $payload->meta; |
| 149 |
|
} |
| 150 |
|
} |
| 151 |
|
if ($this->timeshift_cached_meta && isset($this->timeshift_cached_meta[$key])) { |
| 152 |
|
return $this->timeshift_cached_meta[$key]; |
|
@@ 171-174 (lines=4) @@
|
| 168 |
|
$table_name = $this->wpdb->prefix . 'timeshift_' . $post->post_type; |
| 169 |
|
$sql = "select * from $table_name where id=" . intval($_GET['timeshift']); |
| 170 |
|
$r = $this->wpdb->get_results($sql); |
| 171 |
|
if ($r && count($r) == 1) { |
| 172 |
|
$payload = unserialize($r[0]->post_payload); |
| 173 |
|
$post = $payload->post; |
| 174 |
|
} |
| 175 |
|
} |
| 176 |
|
|
| 177 |
|
public function add_actions() |