PluginProbe
Extendify / 3.1.0
Extendify v3.1.0
3.2.1 3.2.0 3.1.6 3.1.5 3.1.4 3.1.3 3.1.2 3.1.1 3.1.0 3.0.6 3.0.5 3.0.4 trunk 0.1.0 0.10.0 0.10.1 0.10.2 0.11.0 0.11.1 0.2.0 0.3.0 0.3.1 0.4.0 0.5.0 0.6.0 All 127 releases
extendify / tests / playwright / QuickEdit / cursor-rule / setup.php

setup.php in Extendify 3.1.0, at tests/playwright/QuickEdit/cursor-rule/setup.php

29 lines 997 B
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 require '/wordpress/wp-load.php';
3
4 // Cursor-rule seed: a tagged paragraph with an inline link
5 // (crosshair on text, pointer on the anchor), a search block (form
6 // control branch), and a sibling page so the "edit mode off" assertion
7 // has a real URL to land on with the same shape.
8 $homeContent = "<!-- wp:paragraph -->\n"
9 . "<p>Cursor rule paragraph with an <a href=\"/about/\">inline link</a> inside.</p>\n"
10 . "<!-- /wp:paragraph -->\n\n"
11 . "<!-- wp:search {\"label\":\"Search\",\"buttonText\":\"Go\"} /-->\n";
12
13 $pageId = wp_insert_post([
14 'post_type' => 'page',
15 'post_status' => 'publish',
16 'post_title' => 'QE Cursor Rule Home',
17 'post_content' => $homeContent,
18 ]);
19
20 wp_insert_post([
21 'post_type' => 'page',
22 'post_status' => 'publish',
23 'post_title' => 'About',
24 'post_content' => "<!-- wp:heading --><h2 class=\"wp-block-heading\">About page reached.</h2><!-- /wp:heading -->\n",
25 ]);
26
27 update_option('show_on_front', 'page');
28 update_option('page_on_front', $pageId);
29