| @@ 520-538 (lines=19) @@ | ||
| 517 | * } |
|
| 518 | * @return string Login box HTML. |
|
| 519 | */ |
|
| 520 | function geodir_sc_login_box($atts) |
|
| 521 | { |
|
| 522 | ob_start(); |
|
| 523 | ||
| 524 | $defaults = array( |
|
| 525 | 'before_widget' => '', |
|
| 526 | 'after_widget' => '', |
|
| 527 | 'before_title' => '', |
|
| 528 | 'after_title' => '', |
|
| 529 | ); |
|
| 530 | ||
| 531 | geodir_loginwidget_output($defaults, $defaults); |
|
| 532 | ||
| 533 | $output = ob_get_contents(); |
|
| 534 | ||
| 535 | ob_end_clean(); |
|
| 536 | ||
| 537 | return $output; |
|
| 538 | } |
|
| 539 | ||
| 540 | add_shortcode('gd_popular_post_category', 'geodir_sc_popular_post_category'); |
|
| 541 | /** |
|
| @@ 101-113 (lines=13) @@ | ||
| 98 | ||
| 99 | } |
|
| 100 | ||
| 101 | public function testPopPostWidget() { |
|
| 102 | $args = array( |
|
| 103 | 'before_widget' => '<ul>', |
|
| 104 | 'after_widget' => '<ul>', |
|
| 105 | 'before_title' => '<ul>', |
|
| 106 | 'after_title' => '<ul>' |
|
| 107 | ); |
|
| 108 | ob_start(); |
|
| 109 | geodir_popular_post_category_output($args); |
|
| 110 | $output = ob_get_contents(); |
|
| 111 | ob_end_clean(); |
|
| 112 | $this->assertContains('Popular Categories', $output); |
|
| 113 | } |
|
| 114 | ||
| 115 | public function texstBestOfWidget() { |
|
| 116 | // $args = array( |
|