小编Tsc*_*eck的帖子

Bootstrap - 选择和按钮彼此相邻

我有一个<select>和一个按钮彼此相邻,并希望用引导程序来设置它们. Select没有类看起来像这样:

在此输入图像描述

selectclass="form-control"这个样子的: 在此输入图像描述

请注意,该按钮现在处于选择状态.我不确定,哪个CSS属性对此负责.我应该更改什么,在选择旁边有按钮?

css twitter-bootstrap

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

如何在div元素中居中文本?

我正在尝试创建方形元素,它将使文本在垂直和水平方向上居中.此外,广场的整个区域应该是一个链接.这是我的HTML:

<div class="w1h1 medium">
    <a class="userLink" target="_blank" href="Fancybox.aspx">
        <table style="width: 100%; height: 100%">
            <tr style="vertical-align: central">
                <td style="text-align: center; font-weight: bold;">
                    text in the middle 
                </td>
            </tr>
        </table>
    </a>
</div>
Run Code Online (Sandbox Code Playgroud)

这是我的CSS:

div.w1h1 {
    width: 150px;
    height: 150px;
}

.medium {
    background-color: #06849b;
    color: white;
    font-family: sans-serif;
}

a.userLink
{
    width: 150px;
    height: 150px;
    display: table;
    color: #FFFFFF;
    text-decoration: none;
}
Run Code Online (Sandbox Code Playgroud)

它适用于Chrome和Firefox,但不适用于Internet Explorer.在IE中,文本位于正方形的顶部,而不是在中间.你能帮帮我吗?

我刚刚在这里创建了游乐场:http://jsfiddle.net/Tschareck/yfnnm/

html css

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

如何从CRM中获取超过5000个实体

我从我的控制台应用程序查询MS Dynamics CRM Online:

public EntityCollection GetEntities(string entityName)
{
    IOrganizationService proxy = ServerConnection.GetOrganizationProxy();

    string request = string.Format("<fetch mapping ='logical'><entity name = '{0}'></entity></fetch>", entityName);
    FetchExpression expression = new FetchExpression(request);
    var mult = proxy.RetrieveMultiple(expression);

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

此代码仅返回最多5000个元素mult.Entities.我知道CRM中有更多实体. 如何检索所有的entites?

c# dynamics-crm-online dynamics-crm-2013

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

从API获取Twitter卡

我将能够检索存储在Twitter卡(https://dev.twitter.com/docs/cards)中的HTML标记.

到目前为止,我使用TweetSharp库从某个用户的时间线中检索推文.但是,这并不奇怪,因为卡片是新的东西,它不包括在内.

有谁知道,如果可以使用API​​访问卡(由Twitter爬虫缓存的数据)?

twitter

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

Google报亭的API

Google Play拥有报亭应用程序(无处不在) - https://play.google.com/store/newsstand.它取代了旧的Currents应用程序.它显示来自许多不同网站/杂志/提要的新闻/文章.

是否存在允许我在自己的应用程序中使用这些源的官方或非官方API?

api google-play

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

如何使用实体框架在 SQLite 中设置线程模式?

我将 SQLite 与 Entity Framework Core (RC1) 一起使用。

我读到,SQLite 支持三种不同的线程模式:单线程、多线程和序列化

如何在运行时设置我想对数据库使用哪种模式?

sqlite multithreading entity-framework-core

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

使用具有适当内容类型的 AWS CLI 复制到 S3

我正在将静态 AngularJS 网页部署到 S3 存储桶。我使用 Jenkins,使用 AWS CLI 通过 Shell 复制文件。Groovy 中的具体命令如下所示:

// after build, files are located in frontend/target/myfrontend/
sh 'aws s3 cp frontend/target/myfrontend/ $FrontendAddress --recursive'
Run Code Online (Sandbox Code Playgroud)

我在/resources文件夹中有 SVG 图形。该图像在img标签内未正确显示,因为它的内容类型默认设置为binary/octet-stream。应该是这样image/svg+xml

如何使用aws s3 cp命令复制我的 SVG 文件,并设置正确的内容类型?

content-type amazon-s3 amazon-web-services aws-cli

6
推荐指数
2
解决办法
5891
查看次数

HttpServletRequest request = this.getThreadLocalRequest()返回null?

我想在GWT app中获得会话属性.我得到这样的Session

HttpServletRequest request = this.getThreadLocalRequest();
System.out.println("Check HttpServletRequest");       
HttpSession session = request.getSession();
Run Code Online (Sandbox Code Playgroud)

this.getThreadLocalRequest()总是如此null.

代码:

客户:

@RemoteServiceRelativePath("service.s3gwt")
public interface getAttributeSession extends RemoteService 
{
    String getSessionAttribute(String name);
}

public interface getAttributeSessionAsync 
{
    void getSessionAttribute(String name, AsyncCallback<String> callback);
}
Run Code Online (Sandbox Code Playgroud)

服务器:

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
import com.google.gwt.user.server.rpc.RemoteServiceServlet;
import daTotNghiep.client.service.getAttributeSession;

public class getAttributeSessionImpl extends RemoteServiceServlet implements getAttributeSession 
{
    private static final long serialVersionUID = 1L;

    public String getSessionAttribute(String name) 
    {
    // TODO Auto-generated method stub

    HttpServletRequest request = this.getThreadLocalRequest();
    System.out.println("Check HttpServletRequest"); …
Run Code Online (Sandbox Code Playgroud)

gwt

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

Web.config的最大大小是多少?

当我尝试打开SharePoint扩展站点时,收到错误500.错误消息为:

无法读取配置文件,因为它超出了最大文件大小

我的web.config文件只有大约260 KB,因为它有很多<SafeControl>条目.删除一些旧条目,并将文件降至186 KB后,我的网站开始正确加载.

我的问题:

  • web.config的最大大小是多少?
  • 可以采取哪些措施来避免将来出现此类问题?

.net error-handling sharepoint web-config

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

使用其他用户凭据从远程路径获取FileStream文件

在我的应用程序中,我FileStream用来从文件中读取,即文件共享在网络中的某个位置.所以我的remoteFilePath变量是这样的:\\computername\folder\file.pdf

FileStream fileStream = new FileStream(remoteFilePath, FileMode.Open, FileAccess.Read, FileShare.None, 1024 * 1024)
Run Code Online (Sandbox Code Playgroud)

不幸的是,我正在运行此应用程序的用户(我已登录到PC)无法访问此文件共享.我有另一个用户(域名,登录名和密码),可以访问这些文件.

是否可以使用其他用户凭据将文件转换为文件流?我可以冒充用户获取文件,然后继续使用我自己的用户吗?

c# credentials filestream

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