diff --git a/2020/template/header.php b/2020/template/header.php index 8c14238..c26b1a6 100644 --- a/2020/template/header.php +++ b/2020/template/header.php @@ -1,64 +1,68 @@ . /** * Available arguments: * * $title: page title */ + +$page_title = $title ?? $conference->getConferenceTitle(); + +$page_url = $url ?? URL; ?> <?= esc_html( sprintf( __( "%s - %s" ), - $title ?? $conference->getConferenceTitle(), + $page_title, isset( $title ) ? $conference->getConferenceTitle() : $conference->getConferenceSubtitle() ) ) ?> - - + + diff --git a/2020/www/event.php b/2020/www/event.php index d1d2acd..0e08a15 100644 --- a/2020/www/event.php +++ b/2020/www/event.php @@ -1,332 +1,333 @@ . // load all the stuff require 'load.php'; // the Event we want to visit $event = null; // load this conference //$conference = ( new QueryConference() ) // ->whereConferenceUID( THIS_CONFERENCE_UID ) // ->queryRow(); // no conference no party //if( !$conference ) { // error_die( sprintf( // "missing conference %s", // THIS_CONFERENCE_UID // ) ); //} // event UID $event_slug = $_SERVER['PATH_INFO'] ?? null; if( !$event_slug ) { error_die( "missing event UID" ); } // remove unuseful slashes $event_slug = trim( $event_slug, _ ); // 123-something $event_slug_parts = explode( '-', $event_slug ); // no ID no party $event_ID = $event_slug_parts[0] ?? 0; $event_ID = (int) $event_ID; if( $event_ID ) { // Event $event = FullEvent::factory() ->whereEventID( $event_ID ) ->queryRow(); } else { // else use the complete Event slug // Event $event = FullEvent::factory() ->whereEventUID( $event_slug ) ->queryRow(); } // no Event no party if( !$event ) { error_die( "missing event $event_slug" ); } // inherit the Conference information from the Event object // the $conference is read from the website header $conference = $event; // check if this is the correct permalink if( site_page( $_SERVER['REQUEST_URI'], true ) !== $event->getEventStandardURL( true ) ) { http_redirect( $event->getEventStandardURL( true ) ); } $users = ( new QueryEventUser() ) ->joinUser() ->whereEvent( $event ) ->orderByEventUserOrder() ->queryGenerator(); $user_links = []; foreach( $users as $user ) { // check if the User has an account in Wikimedia Meta-wiki if( $user->has( User::META_WIKI ) ) { // print the Meta-wiki permalink $user_links[] = HTML::a( $user->getUserMetaWikiURL(), esc_html( $user->getUserDisplayName() ) ); } else { $user_links[] = esc_html( $user->getUserDisplayName() ); } } // print the website header template_2020( 'header', [ 'conference' => $conference, 'title' => $event->getEventTitle(), + 'url' => $event->getEventURL(), ] ); ?>

getEventTitle() ) ?> – getConferenceAcronym() ) ?>

factorySharebleByEvent() ->select( Sharable::fields() ) ->whereSharableIsRoot() ->selectSharableHasChildren() ->queryGenerator(); ?> valid() ): ?>
get( 'sharable_has_children' ) ) { $child_sharables = ( new QuerySharable() ) ->whereSharableParent( $sharable ) ->queryResults(); } ?>
isSharableDownloadable() ): ?> isSharableVideo() ): ?>

isEventPassed() ): ?>

getEventStart( 'd' ) ?> getEventStart( 'H:i' ) ?>–getEventEnd( 'H:i' ) ?> in stanza "getRoomName() ) ?>":

getSharablePath(), icon_2020('attachment', 'left') . esc_html( $child_sharable->getSharableMIME() ), null, null, 'target="_blank"' ), $sharable->getSharableLicense()->getLink() ) ?>

getSharablePath(), icon_2020('share', 'left') . esc_html( $sharable->getSharableTitle( [ 'prop' => true ] ) ), null, null, 'target="_blank"' ), $sharable->getSharableLicense()->getLink() ) ?>

hasEventAbstract() ): ?>

getEventAbstractHTML( [ 'p' => 'flow-text', ] ) ?>
isEventPassed() ): ?>

getEventStart( 'd' ) ?> getEventStart( 'H:i' ) ?>–getEventEnd( 'H:i' ) ?> in getRoomName() ) ?>.

play_arrow getRoomName() ) ?>

hasEventDescription() ): ?> getEventDescription() ?>

getEventExternalURL(), __( "Maggiori informazioni su Meta-wiki" ) ) ?>

factoryPreviousFullEvent( [ 'whatever-room' => true ] ) ->select( Event::fields() ) ->select( Conference::fields() ) ->limit( 2 ) ->queryResults(); // next talk in the same room $nexts = $event->factoryNextFullEvent( [ 'whatever-room' => true ] ) ->select( Event::fields() ) ->select( Conference::fields() ) ->limit( 2 ) ->queryResults(); // in the meanwhile $durings = $event->factoryMeanwhileFullEvent() ->limit( 2 ) ->queryResults(); ?>

navigate_before

getEventURL(), esc_html( $previous->getEventTitle() ) ) ?>

navigate_next

getEventURL(), esc_html( $next->getEventTitle() ) ) ?>

play_arrow

getEventURL(), esc_html( $during->getEventTitle() ) ) ?>

isEventEditable() ): ?>

getEventEditURL(), '[edit]' ) ?>

$conference, ] );