Commit 2d55aff950a05083ce01729a03c2c4aa775a589a
- Diff rendering mode:
- inline
- side by side
entry.class.php
(37 / 5)
|   | |||
| 70 | 70 | function getNeutralTitle(){ | |
| 71 | 71 | return $this->title; | |
| 72 | 72 | } | |
| 73 | |||
| 74 | function getAuthor(){ | ||
| 75 | $author = $this->author; | ||
| 76 | |||
| 77 | #TODO: move this to config file or something | ||
| 78 | $author = str_replace('balleyne', 'Blaise', $author); | ||
| 79 | |||
| 80 | return $author; | ||
| 81 | } | ||
| 73 | 82 | ||
| 74 | 83 | function getSingleDescription(){ | |
| 75 | 84 | return $this->summary ? '<p>'.$this->summary.'</p>' : ''; | |
| … | … | ||
| 105 | 105 | function getSingleTitle(){ | |
| 106 | 106 | return 'New Blog Post: ' . parent::getSingleTitle(); | |
| 107 | 107 | } | |
| 108 | |||
| 109 | function getSingleDescription(){ | ||
| 110 | return htmlspecialchars_decode(parent::getSingleDescription()); | ||
| 111 | } | ||
| 108 | 112 | } | |
| 109 | 113 | ||
| 110 | 114 | class Comments extends Entry{ | |
| … | … | ||
| 195 | 195 | ||
| 196 | 196 | function getSingleTitle(){ | |
| 197 | 197 | #TODO: hardcoded. Can I use author? Is it not consistent enough? | |
| 198 | return "Blaise $this->action " . parent::getSingleTitle(); | ||
| 198 | return $this->getAuthor()." $this->action " . parent::getSingleTitle(); | ||
| 199 | 199 | } | |
| 200 | |||
| 200 | 201 | function getMultipleTitle(){ | |
| 201 | 202 | return parent::getSingleTitle(); | |
| 202 | 203 | } | |
| … | … | ||
| 223 | 223 | ||
| 224 | 224 | $date = $this->timeSince(); //calculates date for most recent entry | |
| 225 | 225 | ||
| 226 | #TODO: hardcoded author | ||
| 227 | return "$icon Blaise $this->action $number $this->items: $list"; | ||
| 226 | return "$icon ".$this->getAuthor()." $this->action $number $this->items: $list"; | ||
| 228 | 227 | } | |
| 229 | 228 | } | |
| 230 | 229 | ||
| … | … | ||
| 239 | 239 | return get_parent_class($this) == get_parent_class($other); | |
| 240 | 240 | } | |
| 241 | 241 | ||
| 242 | function getAuthor(){ | ||
| 243 | return 'Blaise'; #TODO: hardcoded author | ||
| 244 | } | ||
| 245 | |||
| 242 | 246 | function getSingleTitle(){ | |
| 243 | 247 | $title = parent::getSingleTitle(); | |
| 244 | 248 | if($this->play_count>1) | |
| … | … | ||
| 299 | 299 | ||
| 300 | 300 | $date = $this->timeSince(); //calculates date for most recent entry | |
| 301 | 301 | ||
| 302 | #TODO: hardcoded author | ||
| 302 | |||
| 303 | 303 | $icon = $example->getIcon();//$multinlist ? '<img src="http://blaise.ca/images/icons/music-notes.png"/>' : $example->getIcon(); | |
| 304 | return "$icon Blaise $this->action $number $this->items: $list"; | ||
| 304 | return "$icon ".$this->getAuthor()." $this->action $number $this->items: $list"; | ||
| 305 | 305 | } | |
| 306 | 306 | ||
| 307 | 307 | /** | |
| … | … | ||
| 483 | 483 | function getSingleTitle(){ | |
| 484 | 484 | return parent::getSingleTitle().' by '.$this->author; | |
| 485 | 485 | } | |
| 486 | function getAuthor(){ | ||
| 487 | return 'Blaise'; #TODO: hardcoded author... | ||
| 488 | } | ||
| 486 | 489 | function getMultipleTitle(){ | |
| 487 | 490 | return Entry::getSingleTitle().' by '.$this->author; | |
| 488 | 491 | } | |
| … | … | ||
| 517 | 517 | function getSingleDescription(){ | |
| 518 | 518 | return ''; | |
| 519 | 519 | } | |
| 520 | |||
| 521 | function getAuthor(){ | ||
| 522 | return 'Blaise'; #TODO: hardcoded author | ||
| 523 | } | ||
| 520 | 524 | } | |
| 521 | 525 | ||
| 522 | 526 | #TODO: Since LastFM doesn't guarantee unique items, it should check to see | |
| … | … | ||
| 552 | 552 | function getSingleDescription(){ | |
| 553 | 553 | return ''; | |
| 554 | 554 | } | |
| 555 | |||
| 556 | function getAuthor(){ | ||
| 557 | return 'Blaise'; #TODO: harcoded author | ||
| 558 | } | ||
| 555 | 559 | } | |
| 556 | 560 | ||
| 557 | 561 | class WordPress extends Blog{} | |
| … | … | ||
| 568 | 568 | $summary = "<p>$summary</p>"; | |
| 569 | 569 | return $summary; | |
| 570 | 570 | } | |
| 571 | } | ||
| 572 | |||
| 573 | class YouTubeFavorites extends Favorites{ | ||
| 574 | var $img = 'http://www.youtube.com/favicon.ico'; | ||
| 571 | 575 | } | |
| 572 | 576 | ||
| 573 | 577 | ?> |

