Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion _content/keyboards/session.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,10 @@
// Set a cookie header for subsequent requests so that we do not get a
// locale redirect for embedded keyboard search for Keyman 14.0-18.0. See
// /.htaccess for full discussion (line ~32)
setcookie('embed_keyboards_no_locale_redirect', '1', 0, '/');
//
// Note: 'SameSite=None; secure' is required for embedding in Keyman
// Configuration for Windows because that uses an iframe to embed the search
setcookie('embed_keyboards_no_locale_redirect', '1', ["secure" => true, "samesite" => 'None', 'path' => '/']);
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah, this uses a different casing from ll 3-4?

session_set_cookie_params(["SameSite" => "None"]);   // Allow use in iframe, needed for Download Keyboards dialog
    session_set_cookie_params(["Secure" => "true"]);     // None requires Secure to be set

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah seems slightly different, but PHP appears not to care.


$session_query = http_build_query([
'embed' => $embed,
Expand Down
Loading