Revise setup instructions

Fix some formatting
This commit is contained in:
Justin Foell
2017-05-10 12:17:25 -05:00
parent 714b349f23
commit ded3929a44
+6 -7
View File
@@ -110,29 +110,28 @@ class WPStrava_Settings {
$signup_url = 'http://www.strava.com/developers'; $signup_url = 'http://www.strava.com/developers';
$settings_url = 'https://www.strava.com/settings/api'; $settings_url = 'https://www.strava.com/settings/api';
$blog_name = get_bloginfo( 'name' ); $blog_name = get_bloginfo( 'name' );
$app_name = $blog_name . ' Strava'; $app_name = sprintf( esc_html( '%s Strava', 'wp-strava' ), $blog_name );
$url_parts = parse_url( site_url() ); $site_url = site_url();
$site_url = $url_parts['host']; //strip http/https for copying/pasting into strava
$description = 'WP-Strava for ' . $blog_name; $description = 'WP-Strava for ' . $blog_name;
printf( __( "<p>Steps:</p> printf( __( "<p>Steps:</p>
<ol> <ol>
<li>Create your API Application here: <a href='%s' target='_blank'>%s</a> using the following information:</li> <li>Create your API Application/Connection here: <a href='%s' target='_blank'>%s</a> using the following information:</li>
<ul> <ul>
<li>Application Name: <strong>%s</strong></li> <li>Application Name: <strong>%s</strong></li>
<li>Website: <strong>%s</strong></li> <li>Website: <strong>%s</strong></li>
<li>Application Description: <strong>%s</strong></li> <li>Application Description: <strong>%s</strong></li>
<li>Authorization Callback Domain: <strong>%s</strong></li> <li>Authorization Callback Domain: <strong>%s</strong></li>
</ul> </ul>
<li>Once you've created your API Application at strava.com, enter the Client ID and Client Secret below, which can be found at <a href='%s' target='_blank'>%s</a></li> <li>Once you've created your API Application at strava.com, enter the <strong>Client ID</strong> and <strong>Client Secret</strong> below, which can now be found on that same strava API Settings page.
<li>After saving your Client ID and Secret, you'll be redirected to strava to authorize your API Application. If successful, your Strava Token will display instead of Client ID and Client Secret.</li> <li>After saving your Client ID and Secret, you'll be redirected to strava to authorize your API Application. If successful, your Strava Token will display instead of Client ID and Client Secret.</li>
<li>If you need to re-authorize your API Application, erase your Strava Token here and click 'Save Changes' to start over.</li> <li>If you need to re-authorize your API Application, erase your Strava Token here and click 'Save Changes' to start over.</li>
</ol>", 'wp-strava' ), $signup_url, $signup_url, $app_name, $site_url, $description, $site_url, $settings_url, $settings_url ); </ol>", 'wp-strava' ), $settings_url, $settings_url, $app_name, $site_url, $description, $site_url );
} }
public function print_strava_options() { public function print_strava_options() {
?> ?>
<div class="wrap"> <div class="wrap">
<div id="icon-options-general" class="icon32"><br/></div> <div id="icon-options-general" class="icon32"><br/></div>
<h2><?php _e( 'Strava Settings', 'wp-strava' ); ?></h2> <h2><?php _e( 'Strava Settings', 'wp-strava' ); ?></h2>
<form method="post" action="<?php echo admin_url( 'options.php' ); ?>"> <form method="post" action="<?php echo admin_url( 'options.php' ); ?>">