小编Sar*_*mar的帖子

使用html模板在gmail中无法正确加载图像(在Samsung Galaxy Note 5上)

我为电子邮件创建了一个html模板.(使用PHPPHPMailer发送邮件)

它在以下尺寸下工作正常.

  • 大屏幕显示器(LG)
  • 中型或普通屏幕显示器和笔记本电脑(MD)
  • 平板电脑屏幕(SM)
  • 移动设备屏幕(XS)
  • 在Outlook中工作也是如此

但它不适用于三星Galaxy Note 5.

在其他Android设备看起来像下面的图像,

在此输入图像描述

三星Galaxy Note 5中如下所示,

在此输入图像描述

图像显示为三星Galaxy Note 5中的附件.

Html代码:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>A Simple Responsive HTML Email</title>
    <style type="text/css">
      .content {max-width: 900px !important;}
      .dynamic_container{width: 31.33% !important;border:1px solid #ccc;margin:1%;}
      a{padding: 10px 8px !important;}
      
      @media (min-width:651px) and (max-width: 992px){
      .content {max-width: 600px !important;}
      .dynamic_container{width: 47% !important;margin:1.5%;}
      a{padding: …
Run Code Online (Sandbox Code Playgroud)

html email email-integration

8
推荐指数
1
解决办法
2194
查看次数

agSetColumnFilter 在服务器端分页时出现错误

agSetColumnFilter 在服务器端分页时遇到错误,因为“设置过滤器无法初始化,因为您使用的行模型不包含浏览器中的所有行。请使用不同的过滤器类型,或配置设置过滤器以便为其提供值” 。

我已指定

enableServerSideSorting: true,
enableServerSideFilter: true,
rowModelType: 'infinite' 
Run Code Online (Sandbox Code Playgroud)

并添加了

filter: "agSetColumnFilter". 
Run Code Online (Sandbox Code Playgroud)

但我仍然收到错误。

如何克服这个问题(在反应应用程序中)?

ag-grid

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

如何使用show all/none按钮进行此操作?

我想问一个问题:我有这个代码,做了一个片段,让你的工作更轻松.

如果你点击你现在看不到的图像,另一个div会出现一些信息,在div内有另一个你也看不到的图像,点击它会显示更多信息.

并且有一个按钮显示所有/隐藏所有信息.

我想要实现的是,当任何弹出文本(通过点击图片显示)已经可见时,然后点击Show all按钮,它保持原样,只有那些不可见的那些出现.

你能帮我解决一下这个问题吗?

我希望你明白我的意思,如果没有,请问:)

谢谢你的帮助!

function popupD1() {
    var popup = document.getElementById("myPopupD1");
    popup.classList.toggle("show");
    var image =  document.getElementById("arrow1");

    if (image.getAttribute('src') == "arrow.png") {
        image.src = "arrowL.png";
    } else {
        image.src = "arrow.png";
    }

    var D1S=document.getElementById("D1S");
    if(D1S.textContent=="Show info"){
      D1S.textContent="Hide info";
    } else {
      D1S.textContent="Show info";
    }
}

function D1moreinfo() {
    var hide=document.getElementById("D1moreinfo");
    if(hide.style.display ==="block") {
        hide.style.display="none";
    } else{
        hide.style.display="block";
    }

    var image =  document.getElementById("arrowL1");
    if (image.getAttribute('src') == "arrowL.png") {
        image.src = "arrow.png";
    } else {
        image.src = …
Run Code Online (Sandbox Code Playgroud)

html javascript css

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

如何在角反应形式输入中添加“必填字段”星号

我正在开发一种具有反应性动态角度形式的应用程序。此表单字段来自API请求,并且是动态生成的。

我确实需要在所需的表单输入中添加“必填字段”星号(*)。如何实现呢?

以下是我的表单字段的外观。

<ng-container *ngIf="input1.type=='string'" [hidden]="False">
 <div>
  <mat-form-field>
   <input matInput   [formControlName]="input1.field_name"  type="text"  placeholder="{{input1.title}}">
  </mat-form-field>   
 </div>
</ng-container>
Run Code Online (Sandbox Code Playgroud)

css validation typescript angular

5
推荐指数
1
解决办法
6219
查看次数

Javascript没有收到或修改值

我有一个正在网页上显示的MySQL表.我有一个按钮,每行使用行中的值切换一个函数:

<button id="loginButtonSmall" onclick="resumeApplication(<?php echo $row['newApplicationNumb']; ?>)">
 Pickup where we left off
</button>
Run Code Online (Sandbox Code Playgroud)

$row['newApplicationNumb']显示的值在页面上进一步正确显示.

这里$row['newApplicationNumb']= 359786918929342363.

然后我有:

function resumeApplication(applicationID) {
  var newApplicationNumb = applicationID;
  alert(newApplicationNumb); 
}
Run Code Online (Sandbox Code Playgroud)

警报返回:359786918929342340.

所以它每次将最后2位数从63改为40 ......

我环顾四周,真的不明白它是如何改变这样的价值的......

任何线索将非常感谢!

javascript php

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

使用Angular 5在Angular Material自动完成显示中绑定'this'

我试图使用Material Angular自动完成功能,但遇到了displayWith函数,该函数显然可以用作选择时显示的输出。我想在显示功能中调用自定义功能,例如

displayFn(id) {
 return this.getValue(id)
}
getValue(id) {
 /**return some string
}
Run Code Online (Sandbox Code Playgroud)

对于自动完成

<mat-autocomplete #autoOutlet="matAutocomplete" [displayWith]="displayFn">
  <mat-option *ngFor="let option of outletFilterOptions | async [value]="option.outletId">
   {{ option.outletName }}
  </mat-option>
</mat-autocomplete>
Run Code Online (Sandbox Code Playgroud)

如您所见,我使用id而不是整个对象作为模型。

当显示函数返回未定义this.getValue的错误时,我在Stack Overflow中搜索了一种解决方案,并建议我使用类似的内容[displayWith]="displayFn.bind(this)"

但不幸的是,这对我也不起作用。我正在使用Angular材质5.1.0。

我有什么想念的吗?

javascript angular-material angular-material2 angular angular-material-5

4
推荐指数
2
解决办法
2227
查看次数

Angular无法获取响应状态文本

export class GitComponent implements OnInit {
  http: HttpClient;
  headerForAjax: HttpHeaders;

  constructor(http: HttpClient) {
    this.http = http;
  }

  ngOnInit(): void {
    const headers = 'Bearer eyJhbGciOiJIUzUxMiJ9.eyJzdWIiOiJzYXNobyIsImF1dGgiOiJST0xFX1VTRVIiLCJleHAiOjE1MjQwODcyMzJ9.MUv5RgI9LxQyrrCfjfX8HR2-XiQmz4vjLqH7V_0Du7VFLC0WrK_y3FfeNoT2Nj_uguIK2ss7jv-LNiHuCGtz4A';
    this.headerForAjax = new HttpHeaders().set('Authorization', headers);
    const linkBindingModel = {
      title: 'angular2',
      linkUrl: 'angularUr2l',
      imageUrl: 'imageUrl22'
    };
    this.http.post('http://localhost:8080/links/add', linkBindingModel, {headers: this.headerForAjax}).subscribe((e) => {
      console.log(e);
    });
  }
}
Run Code Online (Sandbox Code Playgroud)

所以这个ajax被发送到我的spring服务器并且服务器正确地将数据保存在DB中,它基本上都运行良好.

但我无法获得响应状态,我的意思是如何获取我的服务器发回的200响应状态号或文本

javascript ajax httpclient angular

3
推荐指数
1
解决办法
79
查看次数

Python 通过一对 nan 获取坐标

我有一个像这样的数据框

>>df1 = pd.DataFrame({
          'A': ['1', '2', '3', '4', '5'],
          'B': ['1', '1', '1', '1', '1'],
          'C': ['c', 'A1', NaN, 'c3', Nan],
          'D': ['d0', 'B1', 'B2', Nan, 'B4'],
          'E': ['A', Nan, 'S', Nan, 'S'],
          'F': ['3', '4', '5', '6', '7'],
          'G': ['2', '2', NaN, '2', '2']
        })
>>df1

    A   B     C     D     E   F     G
0   1   1     c    d0     A   3     2
1   2   1    A1    B1   NaN   4     2
2   3   1   NaN    B2     S   5   NaN
3 …
Run Code Online (Sandbox Code Playgroud)

python nan pandas

3
推荐指数
1
解决办法
756
查看次数

如何将"<>"作为HTML中的文本?

我想在HTML中包含<和包含>文本,但我无法,因为HTML不理解它的文本.

有没有办法将这些符号作为文本放在HTML中并让编辑器理解它?

例:

<div> <this is some text> </div>
Run Code Online (Sandbox Code Playgroud)

html css html5

0
推荐指数
2
解决办法
901
查看次数