| @@ 454-465 (lines=12) @@ | ||
| 451 | } else { |
|
| 452 | if (api_get_user_id() && !api_is_anonymous()) { |
|
| 453 | $list = explode("\n", $openMenuTabsLoggedIn); |
|
| 454 | foreach ($list as $link) { |
|
| 455 | $matches = array(); |
|
| 456 | $match = preg_match('$href="([^"]*)" target="([^"]*)">([^<]*)</a>$', $link, $matches); |
|
| 457 | if ($match) { |
|
| 458 | $mainNavigation['navigation'][$matches[3]] = array( |
|
| 459 | 'url' => $matches[1], |
|
| 460 | 'target' => $matches[2], |
|
| 461 | 'title' => $matches[3], |
|
| 462 | 'key' => 'page-' . str_replace(' ', '-', strtolower($matches[3])) |
|
| 463 | ); |
|
| 464 | } |
|
| 465 | } |
|
| 466 | } else { |
|
| 467 | $list = explode("\n", $open); |
|
| 468 | foreach ($list as $link) { |
|
| @@ 468-479 (lines=12) @@ | ||
| 465 | } |
|
| 466 | } else { |
|
| 467 | $list = explode("\n", $open); |
|
| 468 | foreach ($list as $link) { |
|
| 469 | $matches = array(); |
|
| 470 | $match = preg_match('$href="([^"]*)" target="([^"]*)">([^<]*)</a>$', $link, $matches); |
|
| 471 | if ($match) { |
|
| 472 | $mainNavigation['navigation'][$matches[3]] = array( |
|
| 473 | 'url' => $matches[1], |
|
| 474 | 'target' => $matches[2], |
|
| 475 | 'title' => $matches[3], |
|
| 476 | 'key' => 'page-' . str_replace(' ', '-', strtolower($matches[3])) |
|
| 477 | ); |
|
| 478 | } |
|
| 479 | } |
|
| 480 | } |
|
| 481 | } |
|
| 482 | } |
|