محفوظات النافذة
كائن تاريخ النافذة
يحتوي كائن السجل على عناوين URL التي زارها المستخدم (في نافذة المتصفح).
كائن المحفوظات هو خاصية لكائن النافذة .
يتم الوصول إلى كائن المحفوظات باستخدام:
window.history
أو فقط history
:
أمثلة
let length = window.history.length;
let length = history.length;
خصائص كائن التاريخ
Property | Description |
---|---|
length | Returns the number of URLs (pages) in the history list |
طرق كائن التاريخ
Method | Description |
---|---|
back() | Loads the previous URL (page) in the history list |
forward() | Loads the next URL (page) in the history list |
go() | Loads a specific URL (page) from the history list |