One of my merges might have removed the actual CAPTCHA checking code. Nobody will find out anyway, eh? Eh?
This commit is contained in:
16
result.php
16
result.php
@@ -1,11 +1,6 @@
|
||||
<?php
|
||||
include('header.php');
|
||||
|
||||
if ($recaptcha_json['success'] != 'true') {
|
||||
// What happens when the CAPTCHA was entered incorrectly
|
||||
die ( '<p class="error" title="' . $resp->error . '">' . yourls__( 'Are you a bot? Google thinks so. Go back and try again.', 'isq_translation' ) . '</p></div></div>' );
|
||||
}
|
||||
|
||||
$url = yourls_sanitize_url( $_REQUEST['url'] );
|
||||
$keyword = isset( $_REQUEST['keyword'] ) ? yourls_sanitize_keyword( $_REQUEST['keyword'] ): '' ;
|
||||
$title = isset( $_REQUEST['title'] ) ? yourls_sanitize_title( $_REQUEST['title'] ) : '' ;
|
||||
@@ -14,6 +9,15 @@ $return = yourls_add_new_link( $url, $keyword, $title );
|
||||
$shorturl = isset( $return['shorturl'] ) ? $return['shorturl'] : '';
|
||||
$message = isset( $return['message'] ) ? $return['message'] : '';
|
||||
$title = isset( $return['title'] ) ? $return['title'] : '';
|
||||
|
||||
$recaptcha_data = file_get_contents('https://www.google.com/recaptcha/api/siteverify?secret=' . ISQ::$recaptcha['secret'] . '&response=' . $_REQUEST['g-recaptcha-response']);
|
||||
$recaptcha_json = json_decode($recaptcha_data, TRUE);
|
||||
|
||||
if ($recaptcha_json['success'] != 'true') {
|
||||
// What happens when the CAPTCHA was entered incorrectly
|
||||
die ( '<p class="error" title="' . $resp->error . '">' . yourls__( 'Are you a bot? Google thinks so. Go back and try again.', 'isq_translation' ) . '</p></div></div>' );
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
<!-- Error reporting -->
|
||||
@@ -40,4 +44,4 @@ $title = isset( $return['title'] ) ? $return['title'] : '';
|
||||
<?php if (!empty(ISQ::$social['plus'])) { echo '<div class="g-plus social-sharer" data-action="share" data-annotation="vertical-bubble" data-height="62" data-href="' . $shorturl . '"></div>'; } ?>
|
||||
<?php if (!empty(ISQ::$social['linkedin'])) { echo '<div class="social-sharer"><script src="http://platform.linkedin.com/in.js"></script><script type="IN/Share" data-url="' . $shorturl . '" data-counter="top"></script></div>'; } ?>
|
||||
<?php if (!empty(ISQ::$social['tumblr'])) { echo '<a href="http://www.tumblr.com/share/link?url='. urlencode($shorturl) .'&name='. urlencode($title) .'" title="Share on Tumblr"><img src="public/img/tumblr.png" alt="Share on Tumblr" width="55px" height="62px" /></a>'; } ?>
|
||||
<?php include('footer.php'); ?>
|
||||
<?php include('footer.php'); ?>
|
||||
Reference in New Issue
Block a user