converted tabs to spaces in all xml and css files and all perl tools
git-svn-id: http://yolanda.mister-muffin.de/svn@241 7eef14d0-6ed0-489d-bf55-20463b2d70db
This commit is contained in:
parent
e59c37e102
commit
46e7fc71b3
7 changed files with 685 additions and 686 deletions
|
@ -3,202 +3,202 @@
|
|||
|
||||
<strings>
|
||||
|
||||
<string id="separator"> | </string>
|
||||
<string id="separator"> | </string>
|
||||
|
||||
<!-- header -->
|
||||
<string id="header_login-to-upload">to upload videos, log in first.</string>
|
||||
<!-- header -->
|
||||
<string id="header_login-to-upload">to upload videos, log in first.</string>
|
||||
|
||||
<string id="register">register</string>
|
||||
<string id="login">login</string>
|
||||
<string id="login_openid">login with OpenID</string>
|
||||
<string id="register">register</string>
|
||||
<string id="login">login</string>
|
||||
<string id="login_openid">login with OpenID</string>
|
||||
|
||||
<string id="header_upload-video">upload video</string>
|
||||
<string id="settings_details">settings details</string>
|
||||
<string id="header_upload-video">upload video</string>
|
||||
<string id="settings_details">settings details</string>
|
||||
|
||||
<string id="logged_in_as">logged in as </string>
|
||||
<string id="logout">logout</string>
|
||||
<string id="logged_in_as">logged in as </string>
|
||||
<string id="logout">logout</string>
|
||||
|
||||
<!-- footer -->
|
||||
<string id="footer_copyright">© 2007 - 2008 Yolanda Team</string>
|
||||
<string id="footer_warranty">
|
||||
This software comes WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
<!-- footer -->
|
||||
<string id="footer_copyright">© 2007 - 2008 Yolanda Team</string>
|
||||
<string id="footer_warranty">
|
||||
This software comes WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the license for details.
|
||||
</string>
|
||||
<string id="footer_license">view license</string>
|
||||
<string id="footer_source_code">get source code</string>
|
||||
<string id="footer_report_bug">report bug</string>
|
||||
<string id="footer_view_xml">view this page as xml</string>
|
||||
<string id="footer_license">view license</string>
|
||||
<string id="footer_source_code">get source code</string>
|
||||
<string id="footer_report_bug">report bug</string>
|
||||
<string id="footer_view_xml">view this page as xml</string>
|
||||
|
||||
|
||||
<!-- front page -->
|
||||
<string id="button_find">Find</string>
|
||||
<string id="button_lucky">Instant Access</string>
|
||||
<string id="button_advanced">Advanced Search</string>
|
||||
<!-- front page -->
|
||||
<string id="button_find">Find</string>
|
||||
<string id="button_lucky">Instant Access</string>
|
||||
<string id="button_advanced">Advanced Search</string>
|
||||
|
||||
<string id="query_latestadditions">latest additions</string>
|
||||
<string id="query_mostdownloads">most downloaded</string>
|
||||
<string id="query_mostviews">most viewed</string>
|
||||
<string id="query_latestadditions">latest additions</string>
|
||||
<string id="query_mostdownloads">most downloaded</string>
|
||||
<string id="query_mostviews">most viewed</string>
|
||||
|
||||
<!-- errors -->
|
||||
<string id="error_202c">Error 202c - Access forbidden by government.</string>
|
||||
<string id="error_missing_file">You did not supply a file.</string>
|
||||
<string id="error_missing_DC.Title">You did not supply a title.</string>
|
||||
<string id="error_missing_DC.Creator">You did not supply a creator.</string>
|
||||
<string id="error_missing_DC.Subject">You did not supply any keywords.</string>
|
||||
<string id="error_missing_DC.Description">You did not supply a description.</string>
|
||||
<string id="error_missing_DC.Publisher">You did not supply a publisher.</string>
|
||||
<string id="error_missing_DC.Title">You did not supply a title.</string>
|
||||
<string id="error_missing_DC.Source">You did not supply a source.</string>
|
||||
<string id="error_missing_DC.Language">You did not supply a language.</string>
|
||||
<string id="error_missing_DC.Coverage">You did not supply a coverage.</string>
|
||||
<string id="error_missing_DC.Rights">You did not supply a rights holder.</string>
|
||||
<string id="error_already_registered">You seem to be already registered. Please log out to create a new account.</string>
|
||||
<string id="error_already_logged_in">You seem to be already logged in. Please log out to log in again.</string>
|
||||
<string id="error_username_password_do_not_match">Username and password do not match.</string>
|
||||
<string id="error_passwords_do_not_match">Passwords do not match.</string>
|
||||
<string id="error_username_already_registered">Your desired Username was already registered</string>
|
||||
<string id="error_insert_username">Please insert a username.</string>
|
||||
<string id="error_insert_password">Please insert a password.</string>
|
||||
<string id="error_repeat_password">Please repeat your password.</string>
|
||||
<string id="error_no_query">You passed no query string.</string>
|
||||
<string id=""></string>
|
||||
<!-- errors -->
|
||||
<string id="error_202c">Error 202c - Access forbidden by government.</string>
|
||||
<string id="error_missing_file">You did not supply a file.</string>
|
||||
<string id="error_missing_DC.Title">You did not supply a title.</string>
|
||||
<string id="error_missing_DC.Creator">You did not supply a creator.</string>
|
||||
<string id="error_missing_DC.Subject">You did not supply any keywords.</string>
|
||||
<string id="error_missing_DC.Description">You did not supply a description.</string>
|
||||
<string id="error_missing_DC.Publisher">You did not supply a publisher.</string>
|
||||
<string id="error_missing_DC.Title">You did not supply a title.</string>
|
||||
<string id="error_missing_DC.Source">You did not supply a source.</string>
|
||||
<string id="error_missing_DC.Language">You did not supply a language.</string>
|
||||
<string id="error_missing_DC.Coverage">You did not supply a coverage.</string>
|
||||
<string id="error_missing_DC.Rights">You did not supply a rights holder.</string>
|
||||
<string id="error_already_registered">You seem to be already registered. Please log out to create a new account.</string>
|
||||
<string id="error_already_logged_in">You seem to be already logged in. Please log out to log in again.</string>
|
||||
<string id="error_username_password_do_not_match">Username and password do not match.</string>
|
||||
<string id="error_passwords_do_not_match">Passwords do not match.</string>
|
||||
<string id="error_username_already_registered">Your desired Username was already registered</string>
|
||||
<string id="error_insert_username">Please insert a username.</string>
|
||||
<string id="error_insert_password">Please insert a password.</string>
|
||||
<string id="error_repeat_password">Please repeat your password.</string>
|
||||
<string id="error_no_query">You passed no query string.</string>
|
||||
<string id=""></string>
|
||||
|
||||
<!-- information -->
|
||||
<string id="information_logged_in">You are now logged in.</string>
|
||||
<string id="information_logged_out">You are now logged out.</string>
|
||||
<string id="information_metainformation_needed">To put the video into context, additional metainformation is needed.</string>
|
||||
<string id="information_metainformation_rights"></string>
|
||||
<string id="information_comment_created">Your comment has been submitted.</string>
|
||||
<string id="information_registered">Your account has been created.</string>
|
||||
<string id="information_uploaded">Your file has been uploaded.</string>
|
||||
<string id="information_settings_changed">Your successfully changed your settings.</string>
|
||||
<!-- information -->
|
||||
<string id="information_logged_in">You are now logged in.</string>
|
||||
<string id="information_logged_out">You are now logged out.</string>
|
||||
<string id="information_metainformation_needed">To put the video into context, additional metainformation is needed.</string>
|
||||
<string id="information_metainformation_rights"></string>
|
||||
<string id="information_comment_created">Your comment has been submitted.</string>
|
||||
<string id="information_registered">Your account has been created.</string>
|
||||
<string id="information_uploaded">Your file has been uploaded.</string>
|
||||
<string id="information_settings_changed">Your successfully changed your settings.</string>
|
||||
|
||||
<!-- warnings -->
|
||||
<string id="warning_no_results">There are no results satisfying your query.</string>
|
||||
<!-- warnings -->
|
||||
<string id="warning_no_results">There are no results satisfying your query.</string>
|
||||
|
||||
<!-- results page-->
|
||||
<string id="results_heading_1">results</string>
|
||||
<string id="results_heading_2">to</string>
|
||||
<string id="results_heading_3">out of</string>
|
||||
<string id="results_heading_4"></string> <!-- this may be needed for other languages -->
|
||||
<string id="ordered_by">ordered by</string>
|
||||
<string id="ascending">ascending</string>
|
||||
<string id="descending">descending</string>
|
||||
<string id="videos_oldest">oldest first</string>
|
||||
<string id="videos_newest">most recent first</string>
|
||||
<string id="videos_downloaded_least">least downloaded first</string>
|
||||
<string id="videos_downloaded_most">most downloaded first</string>
|
||||
<string id="videos_viewed_least">least viewed first</string>
|
||||
<string id="videos_viewed_most">most viewed first</string>
|
||||
<string id="videos_shortest">shortest first</string>
|
||||
<string id="videos_lengthest">lenghtest first</string>
|
||||
<string id="videos_smallest">smallest first</string>
|
||||
<string id="videos_biggest">biggest first</string>
|
||||
<string id="results_on">results on</string>
|
||||
<string id="pages">pages</string>
|
||||
<string id="relevance">relevance</string>
|
||||
<string id="duration">duration</string>
|
||||
<string id="filesize">filesize</string>
|
||||
<string id="viewcount">views</string>
|
||||
<string id="downloadcount">downloads</string>
|
||||
<string id="timestamp">timestamp</string>
|
||||
<!-- results page-->
|
||||
<string id="results_heading_1">results</string>
|
||||
<string id="results_heading_2">to</string>
|
||||
<string id="results_heading_3">out of</string>
|
||||
<string id="results_heading_4"></string> <!-- this may be needed for other languages -->
|
||||
<string id="ordered_by">ordered by</string>
|
||||
<string id="ascending">ascending</string>
|
||||
<string id="descending">descending</string>
|
||||
<string id="videos_oldest">oldest first</string>
|
||||
<string id="videos_newest">most recent first</string>
|
||||
<string id="videos_downloaded_least">least downloaded first</string>
|
||||
<string id="videos_downloaded_most">most downloaded first</string>
|
||||
<string id="videos_viewed_least">least viewed first</string>
|
||||
<string id="videos_viewed_most">most viewed first</string>
|
||||
<string id="videos_shortest">shortest first</string>
|
||||
<string id="videos_lengthest">lenghtest first</string>
|
||||
<string id="videos_smallest">smallest first</string>
|
||||
<string id="videos_biggest">biggest first</string>
|
||||
<string id="results_on">results on</string>
|
||||
<string id="pages">pages</string>
|
||||
<string id="relevance">relevance</string>
|
||||
<string id="duration">duration</string>
|
||||
<string id="filesize">filesize</string>
|
||||
<string id="viewcount">views</string>
|
||||
<string id="downloadcount">downloads</string>
|
||||
<string id="timestamp">timestamp</string>
|
||||
|
||||
<!-- search bar-->
|
||||
<string id="search">search</string>
|
||||
<!-- search bar-->
|
||||
<string id="search">search</string>
|
||||
|
||||
<!-- login / register page -->
|
||||
<string id="username">username</string>
|
||||
<string id="password">password</string>
|
||||
<string id="password_repeat">repeat password</string>
|
||||
<string id="button_register">register</string>
|
||||
<string id="button_login">login</string>
|
||||
<!-- login / register page -->
|
||||
<string id="username">username</string>
|
||||
<string id="password">password</string>
|
||||
<string id="password_repeat">repeat password</string>
|
||||
<string id="button_register">register</string>
|
||||
<string id="button_login">login</string>
|
||||
|
||||
<!-- upload page -->
|
||||
<string id="file">file</string>
|
||||
<string id="button_next_page">continue</string>
|
||||
<string id="button_upload">upload</string>
|
||||
<string id="title_page_1">Basic Information</string>
|
||||
<string id="title_page_2">Similar Videos</string>
|
||||
<string id="title_page_3">Additional Metainformation</string>
|
||||
<string id="title_page_4">Licensing</string>
|
||||
<string id="title_page_5">Summary / Upload</string>
|
||||
<string id="instruction_page_1">Describe the video you want to upload.</string>
|
||||
<string id="instruction_page_2">Similar videos have already been uploaded. If none of these videos matches yours, continue.</string>
|
||||
<string id="instruction_page_3">Providing these infos helps us to put the video into context.</string>
|
||||
<string id="instruction_page_4">Describe the video's license.</string>
|
||||
<string id="instruction_page_5">Double-check the data and correct mistakes, if necessary.</string>
|
||||
<string id="instruction_file">Specify the file you want to upload.</string>
|
||||
<string id="instruction_title">State the title of the video.</string>
|
||||
<string id="instruction_creator">Specify the creator of the video.</string>
|
||||
<string id="instruction_subject">State some keywords, separated by spaces.</string>
|
||||
<string id="instruction_description">Describe the video in natural language.</string>
|
||||
<string id="instruction_source">Specify the source, preferably by URL.</string>
|
||||
<string id="instruction_language">State the language of the video.</string>
|
||||
<string id="instruction_coverage">Specify the time and location covered.</string>
|
||||
<string id="instruction_rights">Specify the copyright owner of the video.</string>
|
||||
<string id="instruction_license">Specify the license, preferably by URL.</string>
|
||||
<string id="instruction_license_cc">Optionally, choose Creative Commons licensing.</string>
|
||||
<string id="instruction_license_cc_remix">Permit modification.</string>
|
||||
<string id="instruction_license_cc_sharealike">Permit modification, derivatives must use the same license.</string>
|
||||
<string id="instruction_license_cc_noderivatives">Prohibit modification.</string>
|
||||
<string id="instruction_license_cc_noncommercial">Prohibit commercial use.</string>
|
||||
<string id="this_is_page_1">This is page 1 of 5.</string>
|
||||
<string id="this_is_page_2">This is page 2 of 5.</string>
|
||||
<string id="this_is_page_3">This is page 3 of 5.</string>
|
||||
<string id="this_is_page_4">This is page 4 of 5.</string>
|
||||
<string id="this_is_page_5">This is page 5 of 5.</string>
|
||||
<string id="button_page_1">back to page 1</string>
|
||||
<string id="button_page_3">back to page 3</string>
|
||||
<string id="button_page_4">back to page 4</string>
|
||||
<!-- upload page -->
|
||||
<string id="file">file</string>
|
||||
<string id="button_next_page">continue</string>
|
||||
<string id="button_upload">upload</string>
|
||||
<string id="title_page_1">Basic Information</string>
|
||||
<string id="title_page_2">Similar Videos</string>
|
||||
<string id="title_page_3">Additional Metainformation</string>
|
||||
<string id="title_page_4">Licensing</string>
|
||||
<string id="title_page_5">Summary / Upload</string>
|
||||
<string id="instruction_page_1">Describe the video you want to upload.</string>
|
||||
<string id="instruction_page_2">Similar videos have already been uploaded. If none of these videos matches yours, continue.</string>
|
||||
<string id="instruction_page_3">Providing these infos helps us to put the video into context.</string>
|
||||
<string id="instruction_page_4">Describe the video's license.</string>
|
||||
<string id="instruction_page_5">Double-check the data and correct mistakes, if necessary.</string>
|
||||
<string id="instruction_file">Specify the file you want to upload.</string>
|
||||
<string id="instruction_title">State the title of the video.</string>
|
||||
<string id="instruction_creator">Specify the creator of the video.</string>
|
||||
<string id="instruction_subject">State some keywords, separated by spaces.</string>
|
||||
<string id="instruction_description">Describe the video in natural language.</string>
|
||||
<string id="instruction_source">Specify the source, preferably by URL.</string>
|
||||
<string id="instruction_language">State the language of the video.</string>
|
||||
<string id="instruction_coverage">Specify the time and location covered.</string>
|
||||
<string id="instruction_rights">Specify the copyright owner of the video.</string>
|
||||
<string id="instruction_license">Specify the license, preferably by URL.</string>
|
||||
<string id="instruction_license_cc">Optionally, choose Creative Commons licensing.</string>
|
||||
<string id="instruction_license_cc_remix">Permit modification.</string>
|
||||
<string id="instruction_license_cc_sharealike">Permit modification, derivatives must use the same license.</string>
|
||||
<string id="instruction_license_cc_noderivatives">Prohibit modification.</string>
|
||||
<string id="instruction_license_cc_noncommercial">Prohibit commercial use.</string>
|
||||
<string id="this_is_page_1">This is page 1 of 5.</string>
|
||||
<string id="this_is_page_2">This is page 2 of 5.</string>
|
||||
<string id="this_is_page_3">This is page 3 of 5.</string>
|
||||
<string id="this_is_page_4">This is page 4 of 5.</string>
|
||||
<string id="this_is_page_5">This is page 5 of 5.</string>
|
||||
<string id="button_page_1">back to page 1</string>
|
||||
<string id="button_page_3">back to page 3</string>
|
||||
<string id="button_page_4">back to page 4</string>
|
||||
|
||||
<!-- languages -->
|
||||
<string id="language_en-us">English</string>
|
||||
<string id="language_de-de">German</string>
|
||||
<!-- languages -->
|
||||
<string id="language_en-us">English</string>
|
||||
<string id="language_de-de">German</string>
|
||||
|
||||
<!-- video page -->
|
||||
<string id="download_video">download</string>
|
||||
<string id="junk_video">mark as junk</string>
|
||||
<string id="edit_video">edit</string>
|
||||
<string id="megabytes">MB</string>
|
||||
<string id="watch_browserplugin">use browser plugin</string>
|
||||
<string id="watch_cortadoapplet">use java applet</string>
|
||||
<string id="license_conditions">license conditions</string>
|
||||
<string id="protip_embed">To embed the video on another web page, use the following HTML code:</string>
|
||||
<string id="login_to_comment">login to comment</string>
|
||||
<string id="comment_post">post</string>
|
||||
<!-- video page -->
|
||||
<string id="download_video">download</string>
|
||||
<string id="junk_video">mark as junk</string>
|
||||
<string id="edit_video">edit</string>
|
||||
<string id="megabytes">MB</string>
|
||||
<string id="watch_browserplugin">use browser plugin</string>
|
||||
<string id="watch_cortadoapplet">use java applet</string>
|
||||
<string id="license_conditions">license conditions</string>
|
||||
<string id="protip_embed">To embed the video on another web page, use the following HTML code:</string>
|
||||
<string id="login_to_comment">login to comment</string>
|
||||
<string id="comment_post">post</string>
|
||||
|
||||
<!-- embedded video page-->
|
||||
<string id="backlink">backlink</string>
|
||||
<!-- embedded video page-->
|
||||
<string id="backlink">backlink</string>
|
||||
|
||||
<!-- dublin core entities -->
|
||||
<string id="DC.Title">title</string>
|
||||
<string id="DC.Creator">author</string>
|
||||
<string id="DC.Subject">keywords</string>
|
||||
<string id="DC.Description">description</string>
|
||||
<string id="DC.Publisher">uploader</string>
|
||||
<string id="DC.Contributor">contributor</string>
|
||||
<string id="DC.Date">upload date</string>
|
||||
<string id="DC.Source">source</string>
|
||||
<string id="DC.Language">language</string>
|
||||
<string id="DC.Coverage">coverage</string>
|
||||
<string id="DC.Rights">rights holder</string>
|
||||
<string id="DC.License">license</string>
|
||||
<!-- dublin core entities -->
|
||||
<string id="DC.Title">title</string>
|
||||
<string id="DC.Creator">author</string>
|
||||
<string id="DC.Subject">keywords</string>
|
||||
<string id="DC.Description">description</string>
|
||||
<string id="DC.Publisher">uploader</string>
|
||||
<string id="DC.Contributor">contributor</string>
|
||||
<string id="DC.Date">upload date</string>
|
||||
<string id="DC.Source">source</string>
|
||||
<string id="DC.Language">language</string>
|
||||
<string id="DC.Coverage">coverage</string>
|
||||
<string id="DC.Rights">rights holder</string>
|
||||
<string id="DC.License">license</string>
|
||||
|
||||
<string id="duration">duration</string>
|
||||
<string id="viewcount">viewcount</string>
|
||||
<string id="duration">duration</string>
|
||||
<string id="viewcount">viewcount</string>
|
||||
|
||||
<!-- settings page -->
|
||||
<string id="settings_heading">account settings</string>
|
||||
<string id="settings_instruction_locale">locale</string>
|
||||
<string id="settings_instruction_pagesize">choose pagesize</string>
|
||||
<string id="settings_instruction_method">choose your preferred method of video playback.</string>
|
||||
<!-- settings page -->
|
||||
<string id="settings_heading">account settings</string>
|
||||
<string id="settings_instruction_locale">locale</string>
|
||||
<string id="settings_instruction_pagesize">choose pagesize</string>
|
||||
<string id="settings_instruction_method">choose your preferred method of video playback.</string>
|
||||
|
||||
<!-- rss feed -->
|
||||
<string id="rss_separator"> - </string>
|
||||
<string id="rss_title_results_this_page">this page</string>
|
||||
<string id="rss_title_results_all_pages">all results</string>
|
||||
<string id="rss_description_1">This is an RSS Feed for the query "</string>
|
||||
<string id="rss_description_2">".</string>
|
||||
<!-- rss feed -->
|
||||
<string id="rss_separator"> - </string>
|
||||
<string id="rss_title_results_this_page">this page</string>
|
||||
<string id="rss_title_results_all_pages">all results</string>
|
||||
<string id="rss_description_1">This is an RSS Feed for the query "</string>
|
||||
<string id="rss_description_2">".</string>
|
||||
|
||||
</strings>
|
||||
|
||||
|
|
|
@ -3,27 +3,27 @@
|
|||
|
||||
<strings>
|
||||
|
||||
<!-- visible -->
|
||||
<string id="site_name">Yolanda</string>
|
||||
<string id="site_motto">WebTV free as in Speech</string>
|
||||
<!-- visible -->
|
||||
<string id="site_name">Yolanda</string>
|
||||
<string id="site_motto">WebTV free as in Speech</string>
|
||||
|
||||
<!-- invisible -->
|
||||
<string id="path_settings">/settings.pl</string>
|
||||
<string id="path_login">/login.pl</string>
|
||||
<string id="path_login-openid">/login.pl?action=openid</string>
|
||||
<string id="path_logout">/login.pl?action=logout</string>
|
||||
<string id="path_authors">http://yolanda.mister-muffin.de/trac</string>
|
||||
<string id="path_license">/LICENSE</string>
|
||||
<string id="path_source-code">http://yolanda.mister-muffin.de/trac/browser/trunk</string>
|
||||
<string id="path_register">/register.pl</string>
|
||||
<string id="path_report_bug">http://yolanda.mister-muffin.de/trac/newticket</string>
|
||||
<string id="path_results">/search.pl?query=</string>
|
||||
<string id="path_root">http://localhost/</string>
|
||||
<string id="path_upload">/upload.pl</string>
|
||||
<string id="path_uploader">/uploader.pl</string>
|
||||
<string id="path_query_latestadditions">/search.pl?query=orderby:timestamp%20sort:descending</string>
|
||||
<string id="path_query_mostdownloads">/search.pl?query=orderby:downloadcount%20sort:descending</string>
|
||||
<string id="path_query_mostviews">/search.pl?query=orderby:viewcount%20sort:descending</string>
|
||||
<!-- invisible -->
|
||||
<string id="path_settings">/settings.pl</string>
|
||||
<string id="path_login">/login.pl</string>
|
||||
<string id="path_login-openid">/login.pl?action=openid</string>
|
||||
<string id="path_logout">/login.pl?action=logout</string>
|
||||
<string id="path_authors">http://yolanda.mister-muffin.de/trac</string>
|
||||
<string id="path_license">/LICENSE</string>
|
||||
<string id="path_source-code">http://yolanda.mister-muffin.de/trac/browser/trunk</string>
|
||||
<string id="path_register">/register.pl</string>
|
||||
<string id="path_report_bug">http://yolanda.mister-muffin.de/trac/newticket</string>
|
||||
<string id="path_results">/search.pl?query=</string>
|
||||
<string id="path_root">http://localhost/</string>
|
||||
<string id="path_upload">/upload.pl</string>
|
||||
<string id="path_uploader">/uploader.pl</string>
|
||||
<string id="path_query_latestadditions">/search.pl?query=orderby:timestamp%20sort:descending</string>
|
||||
<string id="path_query_mostdownloads">/search.pl?query=orderby:downloadcount%20sort:descending</string>
|
||||
<string id="path_query_mostviews">/search.pl?query=orderby:viewcount%20sort:descending</string>
|
||||
|
||||
</strings>
|
||||
|
||||
|
|
|
@ -7,383 +7,382 @@ Yolanda default stylesheet
|
|||
|
||||
*
|
||||
{
|
||||
clear: both;
|
||||
clear: both;
|
||||
}
|
||||
|
||||
|
||||
body
|
||||
{
|
||||
font-family: sans-serif;
|
||||
font-size: 8pt;
|
||||
font-weight: bold;
|
||||
margin: 1.5em;
|
||||
min-height: 100%;
|
||||
text-align: center;
|
||||
font-family: sans-serif;
|
||||
font-size: 8pt;
|
||||
font-weight: bold;
|
||||
margin: 1.5em;
|
||||
min-height: 100%;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
div
|
||||
{
|
||||
border-width: 0px;
|
||||
border-width: 0px;
|
||||
}
|
||||
|
||||
input
|
||||
{
|
||||
text-align: left;
|
||||
text-align: left;
|
||||
}
|
||||
|
||||
img
|
||||
{
|
||||
border-width: 0;
|
||||
border-width: 0;
|
||||
}
|
||||
|
||||
/* links */
|
||||
|
||||
a
|
||||
{
|
||||
color: #3f3fff;
|
||||
text-decoration: none;
|
||||
color: #3f3fff;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
a:focus
|
||||
{
|
||||
font-style: italic;
|
||||
}
|
||||
a:focus
|
||||
{
|
||||
font-style: italic;
|
||||
}
|
||||
|
||||
a:hover
|
||||
{
|
||||
text-decoration: underline;
|
||||
}
|
||||
a:hover
|
||||
{
|
||||
text-decoration: underline;
|
||||
}
|
||||
|
||||
a.tag
|
||||
{
|
||||
display: inline-block;
|
||||
margin-left: 0.25em;
|
||||
margin-right: 0.25em;
|
||||
}
|
||||
a.tag
|
||||
{
|
||||
display: inline-block;
|
||||
margin-left: 0.25em;
|
||||
margin-right: 0.25em;
|
||||
}
|
||||
|
||||
/* header, footer */
|
||||
|
||||
a.footer,
|
||||
a.header,
|
||||
div.footer,
|
||||
div.header
|
||||
{
|
||||
background-color: #f0f0f0;
|
||||
border-color: #f0f0f0;
|
||||
border-style: solid;
|
||||
clear: none;
|
||||
font-size: 1em;
|
||||
line-height: 3em;
|
||||
height: 3em;
|
||||
}
|
||||
a.footer,
|
||||
a.header,
|
||||
div.footer,
|
||||
div.header
|
||||
{
|
||||
background-color: #f0f0f0;
|
||||
border-color: #f0f0f0;
|
||||
border-style: solid;
|
||||
clear: none;
|
||||
font-size: 1em;
|
||||
line-height: 3em;
|
||||
height: 3em;
|
||||
}
|
||||
|
||||
a.footer,
|
||||
a.header
|
||||
{
|
||||
border-bottom-width: 0px;
|
||||
border-top-width: 0px;
|
||||
border-left-width: 1px;
|
||||
border-right-width: 1px;
|
||||
display: block;
|
||||
padding-left: 1em;
|
||||
padding-right: 1em;
|
||||
}
|
||||
a.footer,
|
||||
a.header
|
||||
{
|
||||
border-bottom-width: 0px;
|
||||
border-top-width: 0px;
|
||||
border-left-width: 1px;
|
||||
border-right-width: 1px;
|
||||
display: block;
|
||||
padding-left: 1em;
|
||||
padding-right: 1em;
|
||||
}
|
||||
|
||||
a.footer:hover,
|
||||
a.header:hover
|
||||
{
|
||||
background-color: #ffffff;
|
||||
border-color: #c0c0c0;
|
||||
}
|
||||
a.footer:hover,
|
||||
a.header:hover
|
||||
{
|
||||
background-color: #ffffff;
|
||||
border-color: #c0c0c0;
|
||||
}
|
||||
|
||||
a.latest-additions,
|
||||
a.view-license
|
||||
{
|
||||
border-left-width: 0px;
|
||||
}
|
||||
a.latest-additions,
|
||||
a.view-license
|
||||
{
|
||||
border-left-width: 0px;
|
||||
}
|
||||
|
||||
a.register,
|
||||
a.upload-video,
|
||||
a.view-xml
|
||||
{
|
||||
border-right-width: 0px;
|
||||
}
|
||||
a.register,
|
||||
a.upload-video,
|
||||
a.view-xml
|
||||
{
|
||||
border-right-width: 0px;
|
||||
}
|
||||
|
||||
a.latest-additions,
|
||||
a.most-downloads,
|
||||
a.most-views,
|
||||
a.report-bug,
|
||||
a.view-license,
|
||||
a.view-source-code
|
||||
{
|
||||
float: left;
|
||||
}
|
||||
a.latest-additions,
|
||||
a.most-downloads,
|
||||
a.most-views,
|
||||
a.report-bug,
|
||||
a.view-license,
|
||||
a.view-source-code
|
||||
{
|
||||
float: left;
|
||||
}
|
||||
|
||||
a.login,
|
||||
a.login-openid,
|
||||
a.logout,
|
||||
a.preferences,
|
||||
a.register,
|
||||
a.upload-video,
|
||||
a.view-xml
|
||||
{
|
||||
float: right;
|
||||
}
|
||||
a.login,
|
||||
a.login-openid,
|
||||
a.logout,
|
||||
a.preferences,
|
||||
a.register,
|
||||
a.upload-video,
|
||||
a.view-xml
|
||||
{
|
||||
float: right;
|
||||
}
|
||||
|
||||
div.footer,
|
||||
div.header
|
||||
{
|
||||
border-color: #c0c0c0;
|
||||
border-width: 1px;
|
||||
}
|
||||
div.footer,
|
||||
div.header
|
||||
{
|
||||
border-color: #c0c0c0;
|
||||
border-width: 1px;
|
||||
}
|
||||
|
||||
div.footer
|
||||
{
|
||||
position: absolute;
|
||||
bottom: 1.5em;
|
||||
margin-right: 1.5em;
|
||||
}
|
||||
|
||||
img.logo-header
|
||||
{
|
||||
display: none;
|
||||
border: 1px black solid;
|
||||
clear: none;
|
||||
float: left;
|
||||
margin-left: 1.5em;
|
||||
margin-right: 0.5em;
|
||||
}
|
||||
div.footer
|
||||
{
|
||||
position: absolute;
|
||||
bottom: 1.5em;
|
||||
margin-right: 1.5em;
|
||||
}
|
||||
img.logo-header
|
||||
{
|
||||
display: none;
|
||||
border: 1px black solid;
|
||||
clear: none;
|
||||
float: left;
|
||||
margin-left: 1.5em;
|
||||
margin-right: 0.5em;
|
||||
}
|
||||
|
||||
/* content */
|
||||
|
||||
|
||||
div.button-download,
|
||||
div.button-edit,
|
||||
div.button-junk
|
||||
{
|
||||
display: inline-block;
|
||||
margin: 0.5em;
|
||||
vertical-align: top;
|
||||
}
|
||||
div.button-download,
|
||||
div.button-edit,
|
||||
div.button-junk
|
||||
{
|
||||
display: inline-block;
|
||||
margin: 0.5em;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
div.button-download img,
|
||||
div.button-edit img,
|
||||
div.button-junk img
|
||||
{
|
||||
margin: 0.5em;
|
||||
}
|
||||
div.button-download img,
|
||||
div.button-edit img,
|
||||
div.button-junk img
|
||||
{
|
||||
margin: 0.5em;
|
||||
}
|
||||
|
||||
div.cc-license-chooser
|
||||
{
|
||||
}
|
||||
div.cc-license-chooser
|
||||
{
|
||||
}
|
||||
|
||||
div.cc-license-chooser img
|
||||
{
|
||||
margin: 0.25em;
|
||||
vertical-align: middle;
|
||||
}
|
||||
div.cc-license-chooser img
|
||||
{
|
||||
margin: 0.25em;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
div.commentform,
|
||||
div.loginform,
|
||||
div.registerform,
|
||||
div.settingsform,
|
||||
div.uploadform
|
||||
{
|
||||
line-height: 2.5em;
|
||||
margin: 1.5em;
|
||||
}
|
||||
div.commentform,
|
||||
div.loginform,
|
||||
div.registerform,
|
||||
div.settingsform,
|
||||
div.uploadform
|
||||
{
|
||||
line-height: 2.5em;
|
||||
margin: 1.5em;
|
||||
}
|
||||
|
||||
div.comments
|
||||
{
|
||||
}
|
||||
div.comments
|
||||
{
|
||||
}
|
||||
|
||||
div.messagebox
|
||||
{
|
||||
border-color: #606060;
|
||||
border-style: solid;
|
||||
border-width: 1px;
|
||||
margin: 1.5em;
|
||||
}
|
||||
div.messagebox
|
||||
{
|
||||
border-color: #606060;
|
||||
border-style: solid;
|
||||
border-width: 1px;
|
||||
margin: 1.5em;
|
||||
}
|
||||
|
||||
div.messagebox#error,
|
||||
div.messagebox#warning
|
||||
{
|
||||
background-color: #f09090;
|
||||
}
|
||||
div.messagebox#error,
|
||||
div.messagebox#warning
|
||||
{
|
||||
background-color: #f09090;
|
||||
}
|
||||
|
||||
div.messagebox#information
|
||||
{
|
||||
background-color: #90f090;
|
||||
}
|
||||
div.messagebox#information
|
||||
{
|
||||
background-color: #90f090;
|
||||
}
|
||||
|
||||
div.messagebox img
|
||||
{
|
||||
margin: 0.75em;
|
||||
overflow: visible;
|
||||
vertical-align: middle;
|
||||
}
|
||||
div.messagebox img
|
||||
{
|
||||
margin: 0.75em;
|
||||
overflow: visible;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
div.page-number
|
||||
{
|
||||
color: #606060;
|
||||
display: inline-block;
|
||||
font-size: 40px;
|
||||
height: 32px;
|
||||
width: 32px;
|
||||
overflow: visible;
|
||||
}
|
||||
div.page-number
|
||||
{
|
||||
color: #606060;
|
||||
display: inline-block;
|
||||
font-size: 40px;
|
||||
height: 32px;
|
||||
width: 32px;
|
||||
overflow: visible;
|
||||
}
|
||||
|
||||
div.result
|
||||
{
|
||||
display: inline-block;
|
||||
margin: 0.75em;
|
||||
overflow: visible;
|
||||
vertical-align: top;
|
||||
}
|
||||
div.result
|
||||
{
|
||||
display: inline-block;
|
||||
margin: 0.75em;
|
||||
overflow: visible;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
div.result img
|
||||
{
|
||||
border-color: black;
|
||||
border-width: 1px;
|
||||
}
|
||||
div.result img
|
||||
{
|
||||
border-color: black;
|
||||
border-width: 1px;
|
||||
}
|
||||
|
||||
div.search
|
||||
{
|
||||
padding: 0.75em;
|
||||
}
|
||||
div.search
|
||||
{
|
||||
padding: 0.75em;
|
||||
}
|
||||
|
||||
div.search-small
|
||||
{
|
||||
clear: both;
|
||||
float: right;
|
||||
height: 0em;
|
||||
overflow: visible;
|
||||
text-align: right;
|
||||
}
|
||||
div.search-small
|
||||
{
|
||||
clear: both;
|
||||
float: right;
|
||||
height: 0em;
|
||||
overflow: visible;
|
||||
text-align: right;
|
||||
}
|
||||
|
||||
div.toplists
|
||||
{
|
||||
padding: 0.75em;
|
||||
}
|
||||
div.toplists
|
||||
{
|
||||
padding: 0.75em;
|
||||
}
|
||||
|
||||
div.tagcloud
|
||||
{
|
||||
background-color: #f0f0f0;
|
||||
border-color: #c0c0c0;
|
||||
border-style: solid;
|
||||
border-width: 1px;
|
||||
margin: 0.75em;
|
||||
margin-left: 20%;
|
||||
margin-right: 20%;
|
||||
padding: 0.75em;
|
||||
}
|
||||
div.tagcloud
|
||||
{
|
||||
background-color: #f0f0f0;
|
||||
border-color: #c0c0c0;
|
||||
border-style: solid;
|
||||
border-width: 1px;
|
||||
margin: 0.75em;
|
||||
margin-left: 20%;
|
||||
margin-right: 20%;
|
||||
padding: 0.75em;
|
||||
}
|
||||
|
||||
div.video
|
||||
{
|
||||
display: inline-block;
|
||||
margin-bottom: 0.5em;
|
||||
}
|
||||
div.video
|
||||
{
|
||||
display: inline-block;
|
||||
margin-bottom: 0.5em;
|
||||
}
|
||||
|
||||
div.videoccdata
|
||||
{
|
||||
margin: 0.75em;
|
||||
}
|
||||
div.videoccdata
|
||||
{
|
||||
margin: 0.75em;
|
||||
}
|
||||
|
||||
div.videoccdata img
|
||||
{
|
||||
border-width: 0px;
|
||||
margin-left: 0.5em;
|
||||
margin-right: 0.5em;
|
||||
margin-top: 0.5em;
|
||||
}
|
||||
div.videoccdata img
|
||||
{
|
||||
border-width: 0px;
|
||||
margin-left: 0.5em;
|
||||
margin-right: 0.5em;
|
||||
margin-top: 0.5em;
|
||||
}
|
||||
|
||||
div.video-metadata
|
||||
{
|
||||
display: inline-block;
|
||||
line-height: 1.5em;
|
||||
margin-left: 1.5em;
|
||||
text-align: left;
|
||||
vertical-align: top;
|
||||
width: 256px;
|
||||
}
|
||||
div.video-metadata
|
||||
{
|
||||
display: inline-block;
|
||||
line-height: 1.5em;
|
||||
margin-left: 1.5em;
|
||||
text-align: left;
|
||||
vertical-align: top;
|
||||
width: 256px;
|
||||
}
|
||||
|
||||
div.videotitle
|
||||
{
|
||||
font-size: 1.5em;
|
||||
margin-bottom: 0.5em;
|
||||
}
|
||||
div.videotitle
|
||||
{
|
||||
font-size: 1.5em;
|
||||
margin-bottom: 0.5em;
|
||||
}
|
||||
|
||||
fieldset
|
||||
{
|
||||
border-width: 0px;
|
||||
border-width: 0px;
|
||||
}
|
||||
|
||||
img.logo-big
|
||||
{
|
||||
padding-bottom: 0.5em;
|
||||
}
|
||||
img.logo-big
|
||||
{
|
||||
padding-bottom: 0.5em;
|
||||
}
|
||||
|
||||
img.openid-icon
|
||||
{
|
||||
padding-left: 0.2em;
|
||||
vertical-align: text-top;
|
||||
}
|
||||
img.openid-icon
|
||||
{
|
||||
padding-left: 0.2em;
|
||||
vertical-align: text-top;
|
||||
}
|
||||
|
||||
span.code
|
||||
{
|
||||
font-family: monospace;
|
||||
font-weight: normal;
|
||||
font-family: monospace;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
span.heading
|
||||
{
|
||||
font-size: 1.5em;
|
||||
font-size: 1.5em;
|
||||
}
|
||||
|
||||
span.instruction,
|
||||
span.protip
|
||||
{
|
||||
color: #606060;
|
||||
color: #606060;
|
||||
}
|
||||
|
||||
span.protip:after
|
||||
{
|
||||
content: " )";
|
||||
content: " )";
|
||||
}
|
||||
|
||||
span.protip:before
|
||||
{
|
||||
content: "( ";
|
||||
content: "( ";
|
||||
}
|
||||
|
||||
table.metadata,
|
||||
table.metadata-upload
|
||||
{
|
||||
border-width: 0px;
|
||||
border-collapse: collapse;
|
||||
width: 100%;
|
||||
border-width: 0px;
|
||||
border-collapse: collapse;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
table.metadata td.metadata-content,
|
||||
table.metadata td.metadata-title,
|
||||
table.metadata-upload td.metadata-content
|
||||
{
|
||||
text-align: left;
|
||||
width: 50%;
|
||||
}
|
||||
table.metadata td.metadata-content,
|
||||
table.metadata td.metadata-title,
|
||||
table.metadata-upload td.metadata-content
|
||||
{
|
||||
text-align: left;
|
||||
width: 50%;
|
||||
}
|
||||
|
||||
table.metadata td.metadata-title
|
||||
{
|
||||
width: 40%;
|
||||
}
|
||||
table.metadata td.metadata-title
|
||||
{
|
||||
width: 40%;
|
||||
}
|
||||
|
||||
table.metadata-upload td.metadata-title
|
||||
{
|
||||
text-align: right;
|
||||
width: 50%;
|
||||
}
|
||||
table.metadata-upload td.metadata-title
|
||||
{
|
||||
text-align: right;
|
||||
width: 50%;
|
||||
}
|
||||
|
||||
td.metadata-title
|
||||
{
|
||||
color: #606060;
|
||||
color: #606060;
|
||||
}
|
|
@ -1,21 +1,21 @@
|
|||
body
|
||||
{
|
||||
font-family: sans-serif;
|
||||
font-size: 8pt;
|
||||
font-weight: bold;
|
||||
overflow: visible;
|
||||
font-family: sans-serif;
|
||||
font-size: 8pt;
|
||||
font-weight: bold;
|
||||
overflow: visible;
|
||||
}
|
||||
|
||||
div.watch-browserplugin, div.watch-cortadoapplet
|
||||
{
|
||||
float: left;
|
||||
text-align: left;
|
||||
width: 50%;
|
||||
float: left;
|
||||
text-align: left;
|
||||
width: 50%;
|
||||
}
|
||||
|
||||
div.embedded-backlink
|
||||
{
|
||||
float: right;
|
||||
text-align: right;
|
||||
width: 50%;
|
||||
float: right;
|
||||
text-align: right;
|
||||
width: 50%;
|
||||
}
|
|
@ -21,20 +21,20 @@ $LOG = "$root/daemon.log";
|
|||
#TODO: maybe keep file open the whole time ?
|
||||
sub appendlog
|
||||
{
|
||||
if (open(FILE, ">>$LOG"))
|
||||
{
|
||||
print FILE scalar(localtime)." ".$$."\n";
|
||||
print "------------------------------------\n";
|
||||
print join("\n",@_)."\n";
|
||||
print "------------------------------------\n\n";
|
||||
close FILE;
|
||||
}
|
||||
if (open(FILE, ">>$LOG"))
|
||||
{
|
||||
print FILE scalar(localtime)." ".$$."\n";
|
||||
print "------------------------------------\n";
|
||||
print join("\n",@_)."\n";
|
||||
print "------------------------------------\n\n";
|
||||
close FILE;
|
||||
}
|
||||
}
|
||||
|
||||
sub interrupt
|
||||
{
|
||||
appendlog(@_);
|
||||
die;
|
||||
appendlog(@_);
|
||||
die;
|
||||
}
|
||||
|
||||
$dbh = DBI->connect("DBI:mysql:$database:$dbhost", $dbuser, $dbpass) or interrupt "could not connect to db";
|
||||
|
@ -49,166 +49,166 @@ $dbh = DBI->connect("DBI:mysql:$database:$dbhost", $dbuser, $dbpass) or interrup
|
|||
|
||||
while(1)
|
||||
{
|
||||
#get fresh video id from db
|
||||
my $sth = $dbh->prepare(qq{select id from uploaded where status = 0 limit 1}) or interrupt $dbh->errstr;
|
||||
#get fresh video id from db
|
||||
my $sth = $dbh->prepare(qq{select id from uploaded where status = 0 limit 1}) or interrupt $dbh->errstr;
|
||||
|
||||
$sth->execute() or interrupt $dbh->errstr;
|
||||
my ($id) = $sth->fetchrow_array();
|
||||
$sth->finish() or interrupt $dbh->errstr;
|
||||
$sth->execute() or interrupt $dbh->errstr;
|
||||
my ($id) = $sth->fetchrow_array();
|
||||
$sth->finish() or interrupt $dbh->errstr;
|
||||
|
||||
if($id)
|
||||
{
|
||||
$info = `export SDL_VIDEODRIVER="dummy"; ffplay -stats -an -vn -nodisp /tmp/$id 2>&1`;
|
||||
if($id)
|
||||
{
|
||||
$info = `export SDL_VIDEODRIVER="dummy"; ffplay -stats -an -vn -nodisp /tmp/$id 2>&1`;
|
||||
|
||||
if($info =~ /ignoring/)
|
||||
{
|
||||
appendlog "id: $id",
|
||||
"error: invalid stream",
|
||||
"ffplay msg: $info";
|
||||
if($info =~ /ignoring/)
|
||||
{
|
||||
appendlog "id: $id",
|
||||
"error: invalid stream",
|
||||
"ffplay msg: $info";
|
||||
|
||||
#write status 2 to uploaded table
|
||||
$dbh->do(qq{update uploaded set status = ? where id = ?}, undef, 2, $id) or interrupt $dbh->errstr;
|
||||
unlink "/tmp/$id";
|
||||
}
|
||||
elsif ($info =~ /I\/O error occured/)
|
||||
{
|
||||
appendlog "id: $id",
|
||||
"error: file not found",
|
||||
"ffplay msg: $info";
|
||||
#write status 2 to uploaded table
|
||||
$dbh->do(qq{update uploaded set status = ? where id = ?}, undef, 2, $id) or interrupt $dbh->errstr;
|
||||
unlink "/tmp/$id";
|
||||
}
|
||||
elsif ($info =~ /I\/O error occured/)
|
||||
{
|
||||
appendlog "id: $id",
|
||||
"error: file not found",
|
||||
"ffplay msg: $info";
|
||||
|
||||
#write status 3 to uploaded table
|
||||
$dbh->do(qq{update uploaded set status = ? where id = ?}, undef, 3, $id) or interrupt $dbh->errstr;
|
||||
unlink "/tmp/$id";
|
||||
}
|
||||
elsif ($info =~ /Unknown format/ or $info =~ /could not find codec parameters/)
|
||||
{
|
||||
appendlog "id: $id",
|
||||
"error: file is of unknown format",
|
||||
"ffplay msg: $info";
|
||||
#write status 3 to uploaded table
|
||||
$dbh->do(qq{update uploaded set status = ? where id = ?}, undef, 3, $id) or interrupt $dbh->errstr;
|
||||
unlink "/tmp/$id";
|
||||
}
|
||||
elsif ($info =~ /Unknown format/ or $info =~ /could not find codec parameters/)
|
||||
{
|
||||
appendlog "id: $id",
|
||||
"error: file is of unknown format",
|
||||
"ffplay msg: $info";
|
||||
|
||||
#write status 4 to uploaded table
|
||||
$dbh->do(qq{update uploaded set status = ? where id = ?}, undef, 4, $id) or interrupt $dbh->errstr;
|
||||
unlink "/tmp/$id";
|
||||
}
|
||||
else
|
||||
{
|
||||
$sha = new Digest::SHA(256);
|
||||
$sha->addfile("/tmp/$id");
|
||||
$sha = $sha->hexdigest;
|
||||
#write status 4 to uploaded table
|
||||
$dbh->do(qq{update uploaded set status = ? where id = ?}, undef, 4, $id) or interrupt $dbh->errstr;
|
||||
unlink "/tmp/$id";
|
||||
}
|
||||
else
|
||||
{
|
||||
$sha = new Digest::SHA(256);
|
||||
$sha->addfile("/tmp/$id");
|
||||
$sha = $sha->hexdigest;
|
||||
|
||||
#check if this hash is already in database
|
||||
my $sth = $dbh->prepare(qq{select id from videos where hash = ? limit 1}) or interrupt $dbh->errstr;
|
||||
$sth->execute($sha) or interrupt $dbh->errstr;
|
||||
my ($resultid) = $sth->fetchrow_array();
|
||||
$sth->finish() or interrupt $dbh->errstr;
|
||||
#check if this hash is already in database
|
||||
my $sth = $dbh->prepare(qq{select id from videos where hash = ? limit 1}) or interrupt $dbh->errstr;
|
||||
$sth->execute($sha) or interrupt $dbh->errstr;
|
||||
my ($resultid) = $sth->fetchrow_array();
|
||||
$sth->finish() or interrupt $dbh->errstr;
|
||||
|
||||
#if so, then video is a duplicate (alternatively ALL HAIL QUANTUM COMPUTING)
|
||||
if($resultid)
|
||||
{
|
||||
appendlog "id: $id",
|
||||
"error: video already uploaded: $resultid";
|
||||
#if so, then video is a duplicate (alternatively ALL HAIL QUANTUM COMPUTING)
|
||||
if($resultid)
|
||||
{
|
||||
appendlog "id: $id",
|
||||
"error: video already uploaded: $resultid";
|
||||
|
||||
#write status 5 to uploaded table
|
||||
$dbh->do(qq{update uploaded set status = ? where id = ?}, undef, 5, $id) or interrupt $dbh->errstr;
|
||||
unlink "/tmp/$id";
|
||||
}
|
||||
else
|
||||
{
|
||||
($container, $duration) = $info =~ /Input \#0, (\w+),.+?\n.+?Duration: (\d{2}:\d{2}:\d{2}\.\d)/;
|
||||
#write status 5 to uploaded table
|
||||
$dbh->do(qq{update uploaded set status = ? where id = ?}, undef, 5, $id) or interrupt $dbh->errstr;
|
||||
unlink "/tmp/$id";
|
||||
}
|
||||
else
|
||||
{
|
||||
($container, $duration) = $info =~ /Input \#0, (\w+),.+?\n.+?Duration: (\d{2}:\d{2}:\d{2}\.\d)/;
|
||||
|
||||
#these two regexes have to be applied seperately because nobody knows which stream (audio or video) comes first
|
||||
($audio) = $info =~ /Audio: (\w+)/;
|
||||
($video, $width, $height, $fps) = $info =~ /Video: ([\w\d]+),.+?(\d+)x(\d+),.+?(\d+\.\d+) fps/;
|
||||
#these two regexes have to be applied seperately because nobody knows which stream (audio or video) comes first
|
||||
($audio) = $info =~ /Audio: (\w+)/;
|
||||
($video, $width, $height, $fps) = $info =~ /Video: ([\w\d]+),.+?(\d+)x(\d+),.+?(\d+\.\d+) fps/;
|
||||
|
||||
if(!$audio or !$video or !$duration)
|
||||
{
|
||||
appendlog "id: $id",
|
||||
"error: error: stream is missing or video is corrupt",
|
||||
"audio: $audio",
|
||||
"video: $video",
|
||||
"duration: $duration",
|
||||
"ffplay msg: $info";
|
||||
if(!$audio or !$video or !$duration)
|
||||
{
|
||||
appendlog "id: $id",
|
||||
"error: error: stream is missing or video is corrupt",
|
||||
"audio: $audio",
|
||||
"video: $video",
|
||||
"duration: $duration",
|
||||
"ffplay msg: $info";
|
||||
|
||||
#write status 2 to uploaded table
|
||||
$dbh->do(qq{update uploaded set status = ? where id = ?}, undef, 2, $id) or interrupt $dbh->errstr;
|
||||
unlink "/tmp/$id";
|
||||
}
|
||||
else
|
||||
{
|
||||
$filesize = -s "/tmp/$id";
|
||||
#write status 2 to uploaded table
|
||||
$dbh->do(qq{update uploaded set status = ? where id = ?}, undef, 2, $id) or interrupt $dbh->errstr;
|
||||
unlink "/tmp/$id";
|
||||
}
|
||||
else
|
||||
{
|
||||
$filesize = -s "/tmp/$id";
|
||||
|
||||
#convert hh:mm:ss.s duration to full seconds - thanks perl for making this so damn easy!
|
||||
#don't want to know how this would look in python or php... hell I don't even have to create extra variables!
|
||||
$duration =~ /^(\d{2}):(\d{2}):(\d{2})\.(\d)$/;
|
||||
$duration = int($1*3600 + $2*60 + $3 + $4/10 + .5);
|
||||
#convert hh:mm:ss.s duration to full seconds - thanks perl for making this so damn easy!
|
||||
#don't want to know how this would look in python or php... hell I don't even have to create extra variables!
|
||||
$duration =~ /^(\d{2}):(\d{2}):(\d{2})\.(\d)$/;
|
||||
$duration = int($1*3600 + $2*60 + $3 + $4/10 + .5);
|
||||
|
||||
#create thumbnail
|
||||
$thumbnailsec = int($duration/3 + .5);
|
||||
#create thumbnail
|
||||
$thumbnailsec = int($duration/3 + .5);
|
||||
|
||||
#the width/height calculation could of course be much shorter but less readable then
|
||||
#all thumbs have equal height
|
||||
$tnmaxheight = 120;
|
||||
$tnheight = $tnmaxheight;
|
||||
$tnwidth = int($tnheight*($width/$height)/2 + .5)*2;
|
||||
#the width/height calculation could of course be much shorter but less readable then
|
||||
#all thumbs have equal height
|
||||
$tnmaxheight = 120;
|
||||
$tnheight = $tnmaxheight;
|
||||
$tnwidth = int($tnheight*($width/$height)/2 + .5)*2;
|
||||
|
||||
system "ffmpeg -i /tmp/$id -vcodec mjpeg -vframes 1 -an -f rawvideo -ss $thumbnailsec -s ".$tnwidth."x$tnheight $root/video-stills/$id";
|
||||
system "ffmpeg -i /tmp/$id -vcodec mjpeg -vframes 1 -an -f rawvideo -ss $thumbnailsec -s ".$tnwidth."x$tnheight $root/video-stills/$id";
|
||||
|
||||
$vmaxheight = 640;
|
||||
$vmaxheight = 640;
|
||||
|
||||
#check if the upload already is in the right format and smaller/equal max-width/height
|
||||
if ($container eq 'ogg' and $video eq 'theora' and $audio eq 'vorbis' and $height <= $vmaxheight)
|
||||
{
|
||||
appendlog $id, "file already is ogg-theora/vorbis";
|
||||
#check if the upload already is in the right format and smaller/equal max-width/height
|
||||
if ($container eq 'ogg' and $video eq 'theora' and $audio eq 'vorbis' and $height <= $vmaxheight)
|
||||
{
|
||||
appendlog $id, "file already is ogg-theora/vorbis";
|
||||
|
||||
#add video to videos table
|
||||
$dbh->do(qq{insert into videos select id, title, description, userid, timestamp, creator,
|
||||
subject, source, language, coverage, rights, license, ?, ?, ?, ?, ?, ?, 0, 0
|
||||
from uploaded where id = ?}, undef, $filesize, $duration, $width,
|
||||
$height, $fps, $sha, $id) or interrupt $dbh->errstr;
|
||||
#add video to videos table
|
||||
$dbh->do(qq{insert into videos select id, title, description, userid, timestamp, creator,
|
||||
subject, source, language, coverage, rights, license, ?, ?, ?, ?, ?, ?, 0, 0
|
||||
from uploaded where id = ?}, undef, $filesize, $duration, $width,
|
||||
$height, $fps, $sha, $id) or interrupt $dbh->errstr;
|
||||
|
||||
#move video
|
||||
move "/tmp/$id", "$root/videos/$id";
|
||||
}
|
||||
else #encode video
|
||||
{
|
||||
#video height is either ther maximum video height
|
||||
#or when the original is smaller than that the original height
|
||||
#check for multiple by 8
|
||||
$vheight = $vmaxheight <= $height ? $vmaxheight : int($height/8 + .5)*8;
|
||||
$vwidth = int($vheight*($width/$height)/8 + .5)*8;
|
||||
#move video
|
||||
move "/tmp/$id", "$root/videos/$id";
|
||||
}
|
||||
else #encode video
|
||||
{
|
||||
#video height is either ther maximum video height
|
||||
#or when the original is smaller than that the original height
|
||||
#check for multiple by 8
|
||||
$vheight = $vmaxheight <= $height ? $vmaxheight : int($height/8 + .5)*8;
|
||||
$vwidth = int($vheight*($width/$height)/8 + .5)*8;
|
||||
|
||||
$abitrate = 64;
|
||||
$vbitrate = int($filesize*8) / $duration + .5) - $abitrate;
|
||||
$abitrate = 64;
|
||||
$vbitrate = int($filesize*8) / $duration + .5) - $abitrate;
|
||||
|
||||
#TODO: add metadata information
|
||||
system "ffmpeg2theora --optimize --videobitrate $vbitrate --audiobitrate $abitrate --sharpness 0 --width $vwidth --height $vheight --output $root/videos/$id /tmp/$id";
|
||||
#TODO: add metadata information
|
||||
system "ffmpeg2theora --optimize --videobitrate $vbitrate --audiobitrate $abitrate --sharpness 0 --width $vwidth --height $vheight --output $root/videos/$id /tmp/$id";
|
||||
|
||||
appendlog $id, $audio, $video, $vwidth, $vheight, $fps, $duration, $sha;
|
||||
appendlog $id, $audio, $video, $vwidth, $vheight, $fps, $duration, $sha;
|
||||
|
||||
$filesize = -s "$root/videos/$id";
|
||||
$filesize = -s "$root/videos/$id";
|
||||
|
||||
#add video to videos table
|
||||
$dbh->do(qq{insert into videos select id, title, description, userid, timestamp, creator,
|
||||
subject, source, language, coverage, rights, license, ?, ?, ?, ?, ?, ?, 0, 0
|
||||
from uploaded where id = ?}, undef, $filesize, $duration, $vwidth,
|
||||
$vheight, $fps, $sha, $id) or interrupt $dbh->errstr;
|
||||
#add video to videos table
|
||||
$dbh->do(qq{insert into videos select id, title, description, userid, timestamp, creator,
|
||||
subject, source, language, coverage, rights, license, ?, ?, ?, ?, ?, ?, 0, 0
|
||||
from uploaded where id = ?}, undef, $filesize, $duration, $vwidth,
|
||||
$vheight, $fps, $sha, $id) or interrupt $dbh->errstr;
|
||||
|
||||
#delete temp file
|
||||
unlink "/tmp/$id";
|
||||
}
|
||||
#delete temp file
|
||||
unlink "/tmp/$id";
|
||||
}
|
||||
|
||||
#create torrent file
|
||||
#create torrent file
|
||||
|
||||
|
||||
#delete from uploaded table
|
||||
$dbh->do(qq{delete from uploaded where id = ?}, undef, $id) or interrupt $dbh->errstr;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
TODO: maybe make this event-driven by using the kernels has-this-file-changed-interface ?
|
||||
sleep 10;
|
||||
}
|
||||
#delete from uploaded table
|
||||
$dbh->do(qq{delete from uploaded where id = ?}, undef, $id) or interrupt $dbh->errstr;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
TODO: maybe make this event-driven by using the kernels has-this-file-changed-interface ?
|
||||
sleep 10;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -13,15 +13,15 @@ $sth = $dbh->prepare("select subject from videos");
|
|||
$sth->execute();
|
||||
while(($subject) = $sth->fetchrow_array())
|
||||
{
|
||||
@subject = split(' ', $subject);
|
||||
foreach my $val (@subject)
|
||||
{
|
||||
$val =~ s/^\s*(.*?)\s*$/$1/;
|
||||
if(length($val) >= 4)
|
||||
{
|
||||
%hash->{$val}++;
|
||||
}
|
||||
}
|
||||
@subject = split(' ', $subject);
|
||||
foreach my $val (@subject)
|
||||
{
|
||||
$val =~ s/^\s*(.*?)\s*$/$1/;
|
||||
if(length($val) >= 4)
|
||||
{
|
||||
%hash->{$val}++;
|
||||
}
|
||||
}
|
||||
}
|
||||
$sth->finish();
|
||||
|
||||
|
@ -31,5 +31,5 @@ $dbh->do("delete from tagcloud");
|
|||
$sth = $dbh->prepare("insert into tagcloud (text, count) values (?, ?)");
|
||||
for($i=0;$i<20 and $i<=$#sorted;$i++)
|
||||
{
|
||||
$sth->execute( $sorted[$i], %hash->{$sorted[$i]} );
|
||||
$sth->execute( $sorted[$i], %hash->{$sorted[$i]} );
|
||||
}
|
||||
|
|
|
@ -40,7 +40,7 @@ getopts('u:p:f:t:d:x:c:s:l:v:', \%opts);
|
|||
unless (defined $opts{u}) {
|
||||
unless (length USER) {
|
||||
preamble();
|
||||
print "Username was neither defined nor passed as an argument\n";
|
||||
print "Username was neither defined nor passed as an argument\n";
|
||||
print "Use -u switch to specify the username\n";
|
||||
print "Example: -u joe_random\n";
|
||||
exit 1;
|
||||
|
@ -97,8 +97,8 @@ print "Getting sid cookie...\n";
|
|||
$response = $ua->request(GET $url);
|
||||
unless($response->is_success)
|
||||
{
|
||||
die "Failed opening $url: ",
|
||||
$response->status_line;
|
||||
die "Failed opening $url: ",
|
||||
$response->status_line;
|
||||
}
|
||||
|
||||
print "Logging in to $url/login.pl...\n";
|
||||
|
@ -106,33 +106,33 @@ print "Logging in to $url/login.pl...\n";
|
|||
$response = $ua->request(POST "$url/login.pl", "Content_Type" => "form-data", "Content" => [action => login, user => test, pass => test]);
|
||||
unless($response->is_success)
|
||||
{
|
||||
die "Failed logging in: ",
|
||||
$response->status_line;
|
||||
die "Failed logging in: ",
|
||||
$response->status_line;
|
||||
}
|
||||
unless($response->content =~ /action=logout/)
|
||||
{
|
||||
die "Failed logging in: username/password do not match";
|
||||
die "Failed logging in: username/password do not match";
|
||||
}
|
||||
|
||||
print "Uploading $opts{f} to $url/uploader.pl...\n";
|
||||
# DONT PRINT THIS - UNIX PHILOSPHY IS: IF IT WORKS DONT DISPLAY SHIT ! ( maybe add a -v switch )
|
||||
$response = $ua->request(POST "$url/uploader.pl",
|
||||
"Content_Type" => "multipart/form-data",
|
||||
"Content" => [
|
||||
file => [$opts{f}],
|
||||
"DC.Title" => $opts{t},
|
||||
"DC.Description" => $opts{d},
|
||||
"DC.Subject" => $opts{x},
|
||||
"DC.Creator" => $opts{c} ? $opts{c} : "",
|
||||
"DC.Source" => $opts{s} ? $opts{s} : "",
|
||||
"DC.Language" => $opts{l} ? $opts{l} : "",
|
||||
"DC.Coverage" => $opts{v} ? $opts{v} : "",
|
||||
]
|
||||
"Content_Type" => "multipart/form-data",
|
||||
"Content" => [
|
||||
file => [$opts{f}],
|
||||
"DC.Title" => $opts{t},
|
||||
"DC.Description" => $opts{d},
|
||||
"DC.Subject" => $opts{x},
|
||||
"DC.Creator" => $opts{c} ? $opts{c} : "",
|
||||
"DC.Source" => $opts{s} ? $opts{s} : "",
|
||||
"DC.Language" => $opts{l} ? $opts{l} : "",
|
||||
"DC.Coverage" => $opts{v} ? $opts{v} : "",
|
||||
]
|
||||
);
|
||||
unless($response->is_success)
|
||||
{
|
||||
die "Failed uploading: ",
|
||||
$response->status_line;
|
||||
die "Failed uploading: ",
|
||||
$response->status_line;
|
||||
}
|
||||
print "Done!\n";
|
||||
# DONT PRINT THIS - UNIX PHILOSPHY IS: IF IT WORKS DONT DISPLAY SHIT ! ( maybe add a -v switch )
|
||||
|
|
Loading…
Reference in a new issue