_local_storage_notice

函数
_local_storage_notice ( No parameters )

_local_storage_notice。如果用户的浏览器不支持本地存储,这个函数会向用户输出一个通知,这被一些WordPress的功能所使用。

输出用于从DOM存储中恢复文章数据的HTML。

function _local_storage_notice() {
	?>
	<div id="local-storage-notice" class="hidden notice is-dismissible">
	<p class="local-restore">
		<?php _e( 'The backup of this post in your browser is different from the version below.' ); ?>
		<button type="button" class="button restore-backup"><?php _e( 'Restore the backup' ); ?></button>
	</p>
	<p class="help">
		<?php _e( 'This will replace the current editor content with the last backup version. You can use undo and redo in the editor to get the old content back or to return to the restored version.' ); ?>
	</p>
	</div>
	<?php
}

常见问题

FAQs
查看更多 >