Add bookmark exports and sharing + various fixes

This commit is contained in:
Joey Kimsey
2024-12-15 17:20:57 -05:00
parent 3ef97138a2
commit ab2f009e5b
26 changed files with 975 additions and 297 deletions

View File

@ -26,6 +26,7 @@ class BookmarksForms extends Forms {
self::addHandler( 'editBookmark', __CLASS__, 'editBookmark' );
self::addHandler( 'editFolder', __CLASS__, 'editFolder' );
self::addHandler( 'importBookmarks', __CLASS__, 'importBookmarks' );
self::addHandler( 'exportBookmarks', __CLASS__, 'exportBookmarks' );
}
public static function createBookmark() {
@ -141,6 +142,32 @@ class BookmarksForms extends Forms {
// }
return true;
}
public static function exportBookmarks() {
if ( ! Input::exists( 'submit' ) ) {
return false;
}
if ( ! Input::exists( 'BF_' ) ) {
return false;
}
// if ( ! Input::exists( 'title' ) ) {
// Check::addUserError( 'You must include a title.' );
// return false;
// }
// if ( ! Input::exists( 'color' ) ) {
// Check::addUserError( 'You must include a color.' );
// return false;
// }
// if ( ! Input::exists( 'privacy' ) ) {
// Check::addUserError( 'You must include a privacy.' );
// return false;
// }
// if ( !self::token() ) {
// Check::addUserError( 'token - comment out later.' );
// return false;
// }
return true;
}
}
new BookmarksForms;