Overview
KB
Technical FAQ
PHP Manual
CSS2 Manual
HTML Manual
JS Guide
JS Reference
PhpDock Manual
Nu-Coder Manual
PhpExpress Manual
PHP Joomla
Development
Learn PHP
 
<SplDoublyLinkedList::shiftSplDoublyLinkedList::unserialize>
^SplDoublyLinkedListLast updated: Mon, 26 Oct 2026

SplDoublyLinkedList::top

(PHP 5 >= 5.3.0, PHP 7, PHP 8)

SplDoublyLinkedList::top — Peeks at the node from the end of the doubly linked list

Description

public function SplDoublyLinkedList::top(): mixed

Parameters

This function has no parameters.

Return Values

The value of the last node.

Errors/Exceptions

Throws RuntimeException when the data-structure is empty.


<SplDoublyLinkedList::shiftSplDoublyLinkedList::unserialize>
^SplDoublyLinkedListLast updated: Mon, 26 Oct 2026