GravityView
2.17
The best, easiest way to display Gravity Forms entries on your website.
|
If this file is called directly, abort. More...
Static Public Member Functions | |
static | init () |
Initialize. More... | |
static | pre_oembed_result ( $result, $url, $args) |
Internal oEmbed output, shortcircuit without proxying to the provider. More... | |
static | render ( $matches, $attr, $url, $rawattr) |
Output the embed HTML. More... | |
static | render_provider_request () |
Output a response as a provider for an entry oEmbed URL. More... | |
Static Public Attributes | |
static | $provider_url = '' |
Static Private Member Functions | |
static | get_entry_regex () |
Generate the Regular expression that matches embedded entries. More... | |
static | parse_matches ( $matches, $url) |
Parse oEmbed regex matches and return View and Entry. More... | |
static | render_admin ( $view, $entry) |
Display a nice placeholder in the admin for the entry. More... | |
static | render_frontend ( $view, $entry) |
Render the entry as an oEmbed. More... | |
static | render_preview_notice () |
Generate a warning to users when previewing oEmbed in the Add Media modal. More... | |
If this file is called directly, abort.
oEmbed functionality for GravityView
Definition at line 12 of file class-gv-oembed.php.
|
staticprivate |
Generate the Regular expression that matches embedded entries.
Generates different regex if using permalinks and if not using permalinks
gravityview_slug
Modify the url part for a View. Read the doc string | $rewrite_slug | The slug shown in the URL |
Definition at line 292 of file class-gv-oembed.php.
References Entry\get_endpoint_name().
|
static |
Initialize.
Register the oEmbed handler and the provider. Fire off the provider handler if detected.
Definition at line 23 of file class-gv-oembed.php.
|
staticprivate |
Parse oEmbed regex matches and return View and Entry.
array | $matches | The regex matches. |
string | $url | The URL of the embed. |
Definition at line 112 of file class-gv-oembed.php.
References $entry, $url, $view_id, View\by_id(), View\from_post(), and gravityview().
|
static |
Internal oEmbed output, shortcircuit without proxying to the provider.
Definition at line 319 of file class-gv-oembed.php.
|
static |
Output the embed HTML.
array | $matches | The regex matches from the provided regex when calling wp_embed_register_handler() |
array | $attr | Embed attributes. |
string | $url | The original URL that was matched by the regex. |
array | $rawattr | The original unmodified attributes. |
Render a nice placeholder in the Visual mode.
Prepend a preview notice in Add Media / From URL screen
Definition at line 82 of file class-gv-oembed.php.
References $entry, $url, and gravityview().
|
staticprivate |
Display a nice placeholder in the admin for the entry.
Definition at line 168 of file class-gv-oembed.php.
References $entry, $image, and GravityView_Admin\get_floaty().
|
staticprivate |
Render the entry as an oEmbed.
Private, pending, draft, etc.
When this is embedded inside a view we should not display the widgets.
Remove Widgets on a nested embedded View. Also, don't show widgets if we're embedding an entry
Based on code in our unit-tests. Mocks old context, etc.
Remove the back link.
Definition at line 207 of file class-gv-oembed.php.
References $entry, GV\$form, GravityView_View_Data\$instance, GravityView_View\$instance, $output, $template, GVCommon\get_template_settings(), GravityView_Edit_Entry\getInstance(), GravityView_View_Data\getInstance(), GravityView_View\getInstance(), gravityview(), GVCommon\has_cap(), GravityView_Entry_Approval_Status\is_approved(), and GravityView_Entry_Approval\meta_key.
|
staticprivate |
Generate a warning to users when previewing oEmbed in the Add Media modal.
Definition at line 192 of file class-gv-oembed.php.
References $title, and GravityView_Admin\get_floaty().
|
static |
Output a response as a provider for an entry oEmbed URL.
For now we only output the JSON format and don't care about the size (width, height). Our only current use-case is for it to provide output to the Add Media / From URL box in WordPress 4.8.
Parse the URL to an entry and a view
Definition at line 45 of file class-gv-oembed.php.
|
static |
Definition at line 13 of file class-gv-oembed.php.