小编Vis*_*hAl的帖子

获得广告响应.ErrorCode:1

我在设备中测试我的应用程序它显示调试logcat中的错误这是什么错误以及如何解决这个问题?

错误是

There was a problem getting an ad response. ErrorCode: 1
Run Code Online (Sandbox Code Playgroud)

我的xml代码是

<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
     xmlns:ads="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="match_parent"
    android:background="@color/accent_material_light"
    android:paddingBottom="@dimen/activity_vertical_margin"
    android:paddingLeft="@dimen/activity_horizontal_margin"
    android:paddingRight="@dimen/activity_horizontal_margin"
    android:paddingTop="@dimen/activity_vertical_margin"

     >
      <com.google.android.gms.ads.AdView
        android:id="@+id/adView"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_centerHorizontal="true"
        android:layout_alignParentBottom="true"
        ads:adSize="BANNER"
        ads:adUnitId="@string/banner_ad_unit_id">
    </com.google.android.gms.ads.AdView>
Run Code Online (Sandbox Code Playgroud)

我显示广告的代码是

AdView mAdView = (AdView) findViewById(R.id.adView);
            AdRequest adRequest = new AdRequest.Builder().build();
            mAdView.loadAd(adRequest);
Run Code Online (Sandbox Code Playgroud)

在清单文件中我正在添加.代码工作正常,但广告没有显示我正在我的设备上测试它

<application
        android:allowBackup="true"
        android:icon="@drawable/icon"
        android:label="@string/app_name"
        android:theme="@style/AppTheme" >
         <!--This meta-data tag is required to use Google Play Services.-->
        <meta-data android:name="com.google.android.gms.version"
        android:value="@integer/google_play_services_version" />
<activity android:name="com.google.android.gms.ads.AdActivity"
                android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"
                android:theme="@android:style/Theme.Translucent" />
Run Code Online (Sandbox Code Playgroud)

android admob addsubview

8
推荐指数
2
解决办法
9781
查看次数

尝试使用jQuery UI时,"TypeError:'undefined'不是函数"

我正在尝试使用slider()jQuery UI 的功能,并在控制台中不断收到以下错误:

TypeError: undefined不是函数(评估jQuery('#slider').slider())

我肯定正确地链接到jQuery UI javascript和CSS文件 - 当我查看页面源时,它们都在那里.为什么我仍然会收到此错误?

如果有任何用处,我使用Rails和一些Bootstrap的东西.这是javascript代码:

<script type="text/javascript">
    $(document).ready(function(){
        $('#slider').slider();     
    });
</script>
Run Code Online (Sandbox Code Playgroud)

谢谢

这是<head>:

<!DOCTYPE html>
   <html lang="en">
   <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="">
    <meta name="author" content="">
    <link rel="shortcut icon" href="../../docs-assets/ico/favicon.png">
    <link href="/assets/jquery.ui.core.css?body=1" media="screen" rel="stylesheet" />
    <link href="/assets/jquery.ui.theme.css?body=1" media="screen" rel="stylesheet" />
    <link href="/assets/jquery.ui.accordion.css?body=1" media="screen" rel="stylesheet" />
    <link href="/assets/jquery.ui.menu.css?body=1" media="screen" rel="stylesheet" />
    <link href="/assets/jquery.ui.autocomplete.css?body=1" media="screen" rel="stylesheet" />
    <link href="/assets/jquery.ui.button.css?body=1" media="screen" rel="stylesheet" /> …
Run Code Online (Sandbox Code Playgroud)

javascript css jquery ruby-on-rails twitter-bootstrap

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

Git 提交到 Android Studio 存储库内的子目录

我正在使用带有这个插件“jetbrains-bitbucket-connector_IC-139.224”的Android Studio 2.2版我按照这个链接将我的android studio连接到bitbucket(或git)。

现在,我想要做的是将代码直接从 android studio 推送到 bitbucket,但位置(我必须将代码推送到该位置)是存储库的子目录。IE

myProject/AndroidCode/
Run Code Online (Sandbox Code Playgroud)

其中 myProject 是根存储库,AndroidCode 是我想要推送代码的子目录。有什么帮助吗?或建议?

git android bitbucket android-studio

5
推荐指数
0
解决办法
159
查看次数

Google Chart全屏点击

有没有办法在点击时全屏显示Google Chart?

我已经玩了好几个小时了

JS -

 $('#chart_div').on('click', function(e) {
     $(this).css({
         width: "100%",
         height: "100%",
         margin: "0",
         border: "none"

     });
 });
Run Code Online (Sandbox Code Playgroud)

CSS -

#chart_div {
    width: 100 px;
    height: 100 px;
    margin: 20 px;
    background - color: red;
    border: 1 px solid black;
}
body, html {
    height: 100 % ;
}
Run Code Online (Sandbox Code Playgroud)

HTML - 您可以根据Apache许可证的条款(http://www.apache.org/licenses/LICENSE-2.0.html)自由复制和使用此示例

 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" 
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">

<head>
    <meta http-equiv="content-type" content="text/html; charset=utf-8" />
    <title>
        Google Visualization API Sample
    </title>
    <script type="text/javascript" …
Run Code Online (Sandbox Code Playgroud)

javascript jquery google-visualization

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

想要从日期 javascript 中减去 5.30 小时

我想从日期中减去 5.30 小时,例如,我有一个日期:

Fri Jan 15 2016 00:00:00 
Run Code Online (Sandbox Code Playgroud)

减法后,它应该是这样的,

Thu Jan 14 2016 19:30:00
Run Code Online (Sandbox Code Playgroud)

我如何才能做到这一点。任何帮助将不胜感激。

javascript datetime

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