小编Lin*_*vel的帖子

如何在asp.net c中的webconfig文件中设置启动页面

如何使用webconfig文件设置起始页面.我试过这段代码

<system.webServer>
        <defaultDocument enabled="true">
            <files>
                <clear />
                <add value="index.aspx"/>
            </files>
        </defaultDocument>
    </system.webServer>
Run Code Online (Sandbox Code Playgroud)

但它对我没用.我已通过右键单击解决方案资源管理器中的页面设置起始页面,然后选择选项设置为起始页面,但我如何以编程方式执行此操作

asp.net configuration web-config

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

jQuery对话框失去了对滚动的关注

我在下面有一个jQuery对话框.我正在使用jQuery UI 1.11.

$("#contactContainer").dialog({
  closeOnEscape: false,
  modal: true,
  dialogClass: 'contactsFooter', 
  open: function(event, ui) {
    $(".ui-dialog-titlebar-close").show();
    $('#dialog_footer').remove();
    $(".contactsFooter").append('<div class="" id="dialog_footer"><div class="dialog-footer-buttons"><button type="button" id ="close" class="button-style-2" onclick="$(\'#hasChangedForm\').val(\'\');" style="margin-left: 5px;">Cancel</button></div></div>');
  },
  autoOpen: false,          
  width: 300,
  minHeight: 'auto',
  maxHeight: 400,
  position: { my: 'top', at: 'top+50' },
  close:function() {
    $('#contactContainer').dialog("option", "position", { my:"top", at:"top+50", of: window });
    $('#contactContainer').html('');
  }
}); 

$("#contactContainer").dialog('open');
Run Code Online (Sandbox Code Playgroud)

这是小提琴.在那个小提琴,

  1. 单击任何文本框(表示焦点.在此示例中,它是我们具有值"test here"的那个).

  2. 现在滚动对话框,单击对话框的滚动条并向下/向上拖动它,看看发生了什么.它忽略了我们点击的文本框.如果我按Tab键,它会再次将焦点设置到第一个字段.这很奇怪.

如果我使用鼠标滚动,焦点仍然在同一个字段上.这个是正常的.

坦率地说,我不知道为什么会这样.有人可以帮助我在滚动时如何防止对话失去焦点?我希望焦点保留在同一个领域.

html javascript jquery jquery-ui jquery-ui-dialog

13
推荐指数
1
解决办法
1457
查看次数

VBA HTTP POST无法正常工作

我正在尝试通过VBA发送HTTP帖子.这是我的代码部分

Set objHTTP = CreateObject("MSXML2.ServerXMLHTTP")
objHTTP.Open "POST", url, False
objHTTP.setRequestHeader "User-Agent", "EPS 1.0"
objHTTP.setRequestHeader "Content-Type", "application/x-www-form-urlencoded"
objHTTP.setRequestHeader "content", postString
objHTTP.setRequestHeader "Content-Length", Len(postString)
objHTTP.send
Run Code Online (Sandbox Code Playgroud)

问题是,代码仅在postString小于65535字符时才起作用.如果超过65535字符,则会在下面的行中抛出错误:

错误:参数不正确

objHTTP.setRequestHeader "content", postString
Run Code Online (Sandbox Code Playgroud)

有关于此的任何想法?我是否需要设置任何其他参数才能使其解决?

vba ms-word word-vba

12
推荐指数
1
解决办法
1014
查看次数

如何从地址栏隐藏.php

我使用php来构建Web应用程序,但我希望我的网页没有.php扩展名在浏览器的地址栏中.例如,在浏览器的地址栏中http://www.example.com/index.php显示示例http://www.example.com/index.

我怎样才能做到这一点?

php url address-bar

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

Jquery数据表默认过滤多列

有什么方法可以为起始定义中的列设置默认搜索值?

定义默认订单或默认搜索

$('#table').dataTable({
    ajax: {url: '...'},
    order: [['0', 'asc']],
    search: { search: '...' },
    columns: [
        { data: "id" },
        { data: "name" },
        { data: "description" }
    ]
});
Run Code Online (Sandbox Code Playgroud)

对于列"名称",我试过了

{ data: "name", search: "initial search" }
{ data: "name", search: { search: "initial search" } }
{ data: "name", search: { value: "initial search" } }
Run Code Online (Sandbox Code Playgroud)

但都没有奏效!

有什么建议?

javascript jquery datatables

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

表单重置无效

我正在使用以下代码重置表单字段.

document.getElementById("form1").reset();//form1 is the form id.
Run Code Online (Sandbox Code Playgroud)

它不起作用.我也尝试过JQuery.即使是JQuery也无法正常工作.

$("#reset").click(function(){
$('form1')[0].reset();
});
Run Code Online (Sandbox Code Playgroud)

我的HTML代码是

<form name="form1" id="form1" method="post">
<h3>Personal Information</h3>
<h4>Name</h4>
<input type="text" id="fname" name="fname" maxlength=50 size=11/>
<input type="text" id="mname" name="mname" maxlength=15 size=8/>
<input type="text" id="lname" name="lname" maxlength=50 size=11/>
<input type="button" id="reset" value="Reset" onclick="Reset()"/>
</form>
Run Code Online (Sandbox Code Playgroud)

我正在关注W3Schools.这是我的小提琴.你能解释一下这个错误吗?

html javascript forms jquery reset

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

ORA-00928在oracle中缺少SELECT关键字

我正在使用以下代码插入数据.但我收到的错误是"ORA-00928: missing SELECT keyword"

try
{
Class.forName("oracle.jdbc.driver.OracleDriver");
java.sql.Connection conn = DriverManager.getConnection("jdbc:oracle:thin:@xxx.xxx.x.xxx:xxxx:xxxx", "xxxx", "xxxx");
String query="insert into offer1('RCODE','OFFERNO','DAT') values(?,?,?)"; 
    PreparedStatement ps=conn.prepareStatement(query);
    ps.setString(1,r_code);
    ps.setString(2,offerno);
    ps.setDate(3,sqlDate);
    ResultSet rs=ps.executeQuery();
    out.println("data inserted");
}catch(Exception e)
 {
     out.println(e);
 }
Run Code Online (Sandbox Code Playgroud)

我在这段代码中看不到任何错误.如果有人发现,请说出错误是什么以及如何解决?

java sql oracle jdbc prepared-statement

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

如何在ios 6中处理重复的推文错误

我处理推文取消和完成条件在其完成块它正在工作,当我发送重复推文它显示重复推文错误消息确定没问题但我的问题是在重复错误之后它显示推文已完成消息所以我想停止推文已完成消息如果出现重复的错误消息,请解决我的问题.这是我的工作代码.

self.tweetSheet = [[TWTweetComposeViewController alloc] init];
        [self.tweetSheet setInitialText:@"Some message."];
        [self.navigationController presentModalViewController:self.tweetSheet animated:YES];
    // Called when the tweet dialog has been closed
    self.tweetSheet.completionHandler = ^(TWTweetComposeViewControllerResult result)
    {
        NSString * msg;
        if (result == TWTweetComposeViewControllerResultCancelled)
        {
                msg = @"Tweet compostion was canceled.";
        }
        else if (result == TWTweetComposeViewControllerResultDone)
        {
            NSLog(@"result %d",result);
                msg = @"Tweet composition completed.";
        }

         UIAlertView *alertView = [[UIAlertView alloc] initWithTitle:@"Tweet Status" message:msg delegate:nil cancelButtonTitle:@"OK" otherButtonTitles:nil];
            [alertView show];
        // Show alert to see how things went...
        [self.tweetSheet dismissModalViewControllerAnimated:YES];

        // Dismiss …
Run Code Online (Sandbox Code Playgroud)

ios

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

Recaptcha invalid-request-cookie

我想Recaptcha在我的页面中做.我正在检查一个演示localhost.但是,我invalid-request-cookie一直在检查时一直收到错误.我正在关注不带插件显示recaptcha验证没有插件的recaptcha.

这是我的代码

<html>
<body>
<form method="post" action="http://www.google.com/recaptcha/api/verify">
<script type="text/javascript"
 src="http://www.google.com/recaptcha/api/challenge?k=my_public_key">
 <!-- I used my public key -->
</script>
<noscript>
 <iframe src="http://www.google.com/recaptcha/api/noscript?k=my_public_key"
     height="300" width="500" frameborder="0"></iframe><br>
 <textarea name="recaptcha_challenge_field" rows="3" cols="40">
 </textarea>
 <input type="hidden" name="recaptcha_response_field"
     value="manual_challenge">
</noscript>
<input type="hidden" name="privatekey" value="my_private_key">
<!-- I used my private key -->
<input type="submit" value="Ok"/>
</form>
</body>
</html>
Run Code Online (Sandbox Code Playgroud)

在谷歌,我看到了,invalid-request-cookie意味着The challenge parameter of the verify script was incorrect.但这似乎是正确的.是对还是还有其他错误?有人帮忙

html javascript captcha google-api recaptcha

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

TCPDF错误:无法创建输出文件

我正在尝试使用TCPDF和FPDI的组合生成pdf.这是我的代码.

require_once('../tcpdf/tcpdf.php');
require_once('../FPDI/fpdi.php');

$fileName = '../sample.pdf';

class PDF extends FPDI {
/**
 * "Remembers" the template id of the imported page
 */
var $_tplIdx;
var $numPages = 0;

/**
 * Draw an imported PDF logo on every page
 */
function Header() {

    global $fileName;

    if (is_null($this->_tplIdx)) {
        $this->setSourceFile($fileName);
        $this->_tplIdx = $this->importPage(1);
        $this->numPages = $this->setSourceFile($fileName);
    }
    $size = $this->useTemplate($this->_tplIdx);
}

function Footer() {
    // emtpy method body
}
}

// initiate PDF
$pdf = new PDF($fileName);
$pdf->setFontSubsetting(true);

// add a page …
Run Code Online (Sandbox Code Playgroud)

php pdf fpdf tcpdf

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