| 1 |
<?php |
| 2 |
|
| 3 |
namespace Hostinger\Admin\Onboarding\Steps; |
| 4 |
|
| 5 |
use Hostinger\Settings; |
| 6 |
|
| 7 |
defined( 'ABSPATH' ) || exit; |
| 8 |
|
| 9 |
class AddDescription extends OnboardingStep { |
| 10 |
private string $website_type; |
| 11 |
|
| 12 |
public function __construct() { |
| 13 |
$this->website_type = Settings::get_setting( 'survey.website.type' ); |
| 14 |
} |
| 15 |
|
| 16 |
public function get_title(): string { |
| 17 |
return __( 'Edit post description', 'hostinger' ); |
| 18 |
} |
| 19 |
|
| 20 |
public function get_body(): array { |
| 21 |
return array( |
| 22 |
array( |
| 23 |
'title' => __( 'Go to Posts', 'hostinger' ), |
| 24 |
'description' => __( 'In the left sidebar, find the Posts button. Click on the All Posts button and find the post for which you want to change the description.', 'hostinger' ), |
| 25 |
), |
| 26 |
array( |
| 27 |
'title' => __( 'Edit post', 'hostinger' ), |
| 28 |
'description' => __( 'Hover over the chosen post to see the options menu. Click on the Edit button to open the post editor.', 'hostinger' ), |
| 29 |
), |
| 30 |
array( |
| 31 |
'title' => __( 'Edit description', 'hostinger' ), |
| 32 |
'description' => __( 'You can see the whole post in the editor. Find the description part and change it to your preferences.', 'hostinger' ), |
| 33 |
), |
| 34 |
); |
| 35 |
} |
| 36 |
|
| 37 |
public function step_identifier(): string { |
| 38 |
return 'edit_description'; |
| 39 |
} |
| 40 |
|
| 41 |
public function get_redirect_link(): string { |
| 42 |
return admin_url( 'edit.php' ); |
| 43 |
} |
| 44 |
|
| 45 |
public function button_text(): string { |
| 46 |
return __( 'Take me there', 'hostinger' ); |
| 47 |
} |
| 48 |
} |
| 49 |
|