public function form($instance)
    {
        $defaults = array('title' => esc_html__('Newsletter', 'couponhut'), 'sub_text' => esc_html__("Make sure you don't miss anything!", 'couponhut'), 'button_text' => esc_html__('Subscribe', 'couponhut'));
        $instance = wp_parse_args((array) $instance, $defaults);
        ?>

		<!-- API Key check -->

		<p>
			<?php 
        fw_ssd_api_key_check('mailchimp');
        ?>

		</p>
		
		<p>
			<label for="<?php 
        echo esc_attr($this->get_field_id('title'));
        ?>
"><?php 
        esc_html_e('Title', 'couponhut');
        ?>
:</label>
			<input class="widefat" id="<?php 
        echo esc_attr($this->get_field_id('title'));
        ?>
" name="<?php 
        echo esc_attr($this->get_field_name('title'));
        ?>
" type="text" value="<?php 
        echo esc_attr($instance['title']);
        ?>
" />
			
		</p>
		<p>
			<label for="<?php 
        echo esc_attr($this->get_field_id('button_text'));
        ?>
"><?php 
        esc_html_e('Button Text', 'couponhut');
        ?>
:</label>
			<input class="widefat" id="<?php 
        echo esc_attr($this->get_field_id('button_text'));
        ?>
" name="<?php 
        echo esc_attr($this->get_field_name('button_text'));
        ?>
" type="text" value="<?php 
        echo esc_attr($instance['button_text']);
        ?>
" />
			
		</p>
		<p>
			<label for="<?php 
        echo esc_attr($this->get_field_id('sub_text'));
        ?>
"><?php 
        esc_html_e('Subscription Text', 'couponhut');
        ?>
</label>
			<textarea cols="45" rows="4" id="<?php 
        echo esc_attr($this->get_field_id('sub_text'));
        ?>
" name="<?php 
        echo esc_attr($this->get_field_name('sub_text'));
        ?>
" class="widefat"><?php 
        echo esc_attr($instance['sub_text']);
        ?>
</textarea>
		</p>

	<?php 
    }
    public function form($instance)
    {
        $defaults = array('title' => esc_html__('Twitter', 'couponhut'), 'username' => '', 'tweet_count' => '3');
        $instance = wp_parse_args((array) $instance, $defaults);
        ?>


		<!-- API Key check -->
		<?php 
        if (function_exists('ssd_twitter_feed')) {
            ?>

		<p>
			<?php 
            fw_ssd_api_key_check('twitter');
            ?>

		</p>
		<?php 
        }
        ?>


		<!-- The Title -->
		<p>
			<label for="<?php 
        echo esc_attr($this->get_field_id('title'));
        ?>
"><?php 
        esc_html_e('Title', 'couponhut');
        ?>
</label>
			<input type="text" id="<?php 
        echo esc_attr($this->get_field_id('title'));
        ?>
" name="<?php 
        echo esc_attr($this->get_field_name('title'));
        ?>
" class="widefat" value="<?php 
        echo esc_attr($instance['title']);
        ?>
">
		</p>

		<!-- Username -->
		<p>
			<label for="<?php 
        echo esc_attr($this->get_field_id('username'));
        ?>
"><?php 
        esc_html_e('Username:'******'couponhut');
        ?>
</label>
			<input id="<?php 
        echo esc_attr($this->get_field_id('username'));
        ?>
" class="widefat" name="<?php 
        echo esc_attr($this->get_field_name('username'));
        ?>
" type="text" value="<?php 
        echo esc_attr($instance['username']);
        ?>
" />
		</p>
		
		<!-- Number of tweets -->
		<p>
			<label for="<?php 
        echo esc_attr($this->get_field_id('tweet_count'));
        ?>
"><?php 
        esc_html_e('Number of tweets to show:', 'couponhut');
        ?>
</label>
			<input id="<?php 
        echo esc_attr($this->get_field_id('tweet_count'));
        ?>
" class='widefat' name="<?php 
        echo esc_attr($this->get_field_name('tweet_count'));
        ?>
" type="number" value="<?php 
        echo esc_attr((int) $instance['tweet_count']);
        ?>
" />
		</p>
		
	<?php 
    }