ERROR = Refused to display '.....' in a frame because it set 'X-Frame-Options' to 'sameorigin'

  • Overview

    Your wanting to add an iframe to a page but your getting the error:
    Quote: ERROR = Refused to display '............../' in a frame because it set 'X-Frame-Options' to 'sameorigin'.

    This is because from JR6.1 the X-Frame header was set to 'sameorigin' which means any jamroom page can only be embedded in an iframe on the same domain.

    If you want to allow other websites to embed your site, you need to disable this default option by setting the advanced config value jrCore_disable_xframe to on.
  • Advanced Config Keys

    There is an editor to edit your config.php file directly from the ACP found at:
    ACP -> MODULES -> CORE -> SYSTEM CORE -> TOOLS -> ADVANCED CONFIG KEYS
  • screenshot of the advanced config tool button
  • screenshot of the jrCore_disable_xframe setting set in the Advanced Config Keys tool
  • config.php

    What happens when you add this setting is it is written directly to the config.php file located at:
    /data/config/config.php
  • screenshot of config.php after the Advanced Config Key has been added
  • Other Advanced Config Key Options

    jrCore_disable_db_templates - (if set) - disable checking for database template overrides
    jrCore_max_system_queue_workers - (default 12) - max number of queue workers system wide
    jrCore_queue_worker_ratio - (1 to 100, default 100) - percent chance any single process can become a queue worker
    jrCore_db_persistent - (on/off) - set to “on” for persistent DB connections
    jrCore_sql_mode - set to requested SQL_MODE or boolean TRUE to disable
    jrCore_db_connect_timeout - (seconds > 0) number of seconds to wait for connection to MySQL DB before timing out
    jrCore_play_key_expire_hours - hours until a play key expires
    jrCore_form_session_expire_hours - hours until form sessions expire
    jrCore_bbcode_languages - comma separated list of languages supported in [code] blocks
    jrCloudFileClient_skip_exists_check (set to 1) - skips checking if a file exists before attempting to use it

Tags