小编App*_*eer的帖子

jQuery选择当前脚本标记

有人知道是否有可能在没有任何其他选择器定义的情况下用jQuery选择当前的脚本标签?

<script type="text/javascript">
$(document).ready( function(){
    // Here i need to select the current tag "<script ..."
})
</script>
Run Code Online (Sandbox Code Playgroud)

javascript jquery jquery-selectors

8
推荐指数
3
解决办法
5029
查看次数

Paypal Restful - 无法解析主机

我有一个"Paypal PHP Restful SDK"的问题.我的问题是,(在沙箱模式下)我有时会得到错误" 无法解析主机 ......".这种情况发生在沙箱模式的每第10个支付会话中.

这里记录的错误:

mod_fcgid: stderr: PHP Fatal error:  Uncaught exception 'PayPal\\Exception\\PayPalConnectionException' with message 'Could not resolve host: api.sandbox.paypal.com' in /var/www/xxxxx.com/httpdocs/app/paypal/paypal/rest-api-sdk-php/lib/PayPal/Core/PayPalHttpConnection.php:137
Run Code Online (Sandbox Code Playgroud)

来自SDK的腐蚀线是:

//Throw Exception if Retries and Certificates doenst work
if (curl_errno($ch)) {
    $ex = new PayPalConnectionException(
        $this->httpConfig->getUrl(),
        curl_error($ch),
        curl_errno($ch)
    );
    curl_close($ch);
    throw $ex;
}
Run Code Online (Sandbox Code Playgroud)

信息:我的vServer上没有证书

有人知道,什么是错误的?

php paypal paypal-rest-sdk

7
推荐指数
1
解决办法
1058
查看次数

MySQL声明PHPMyADMIN

我想在PHPMYADMIN中使用声明运行查询.

这是我的查询代码

declare @shopdomain varchar(30);
SET @shopdomain = 'newdomain.com';
UPDATE trans SET tval=REPLACE(name,'olddomain.de', @shopdomain ) WHERE name LIKE 'olddomain.de';
UPDATE settings SET tval=REPLACE(name,'olddomain.de', @shopdomain ) WHERE name LIKE 'olddomain.de';
UPDATE...
Run Code Online (Sandbox Code Playgroud)

PHPMYADMIN显示此错误

#1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'declare @shopdomain varchar(30)' at line 1 
Run Code Online (Sandbox Code Playgroud)

我做错了什么?

php mysql declaration phpmyadmin

2
推荐指数
1
解决办法
1万
查看次数

回调CSS动画结束

我有一个小的jQuery函数,其中返回值必须在子函数中触发.原因:我想稍后使用其他jQuery函数链接此函数.但是下一个链接函数应该在main函数返回jQuery对象之后启动

app.h.aniend = 'webkitAnimationEnd oanimationend msAnimationEnd animationend';
$.fn.animate_scale = function( callback ) {
    var $this = $(this);
    $this.addClass('animate_scale').one( app.h.aniend, function() {
        $(this).removeClass('animate_scale');
        if( typeof callback === 'function' ) {
            callback($this);
        }
        return $this; // return here...
    });
    // return $this;
};
Run Code Online (Sandbox Code Playgroud)

有没有说jQuery要等到子函数返回必要的jQuery对象进行链接?

$('#my_object').animate_scale().fadeOut(2000);
Run Code Online (Sandbox Code Playgroud)

javascript css jquery css3 promise

2
推荐指数
1
解决办法
665
查看次数