当前位置:网站首页>EasyUI export excel cannot download the method that the box pops up
EasyUI export excel cannot download the method that the box pops up
2022-07-07 04:06:00 【Full stack programmer webmaster】
Hello everyone , I meet you again , I'm the king of the whole stack
Before using ajax Hair , The code is as follows (ActionUrl General handler ashx route ):
$.ajax({
url: ActionUrl + '?action=export&ID=' + $('#fm_ID').val(),
dataType: 'json',
success: function (jsonstr) {
//top.art.dialog.tips(' Export succeeded .');
}
});
There is no way to pop up the download box .
Directly enter the address of the relevant page in the browser address bar and open the download box to download , Consider maybe iframe Why .
Because entering the page address can open the download box , So consider opening a new page to download , But because of the export NPOI Why , To pass DataTable, So don't do this .
Want to use window.showModalDialog Methods :
window.showModalDialog(ActionUrl + '?action=export&ID=' + $('#fm_ID').val());
But only a blank window pops up , Will not download .
So in the end window.open Realization :
window.open(ActionUrl + '?action=export&ID=' + $('#fm_ID').val());
Publisher : Full stack programmer stack length , Reprint please indicate the source :https://javaforall.cn/116701.html Link to the original text :https://javaforall.cn
边栏推荐
- 链表面试常见题
- easyui出口excel无法下载框弹出的办法来解决
- 10 ways of interface data security assurance
- PHP implements lottery according to probability
- Antd Comment 递归循环评论
- 使用 TiDB Lightning 恢复 GCS 上的备份数据
- Optimization cases of complex factor calculation: deep imbalance, buying and selling pressure index, volatility calculation
- 使用 BR 备份 TiDB 集群到 GCS
- termux设置电脑连接手机。(敲打命令贼快),手机termux端口8022
- HW notes (II)
猜你喜欢
Do you choose pandas or SQL for the top 1 of data analysis in your mind?
Docker部署Mysql8的实现步骤
ggplot 分面的细节调整汇总
Antd Comment 递归循环评论
Operational amplifier application summary 1
GPT-3当一作自己研究自己,已投稿,在线蹲一个同行评议
Optimization cases of complex factor calculation: deep imbalance, buying and selling pressure index, volatility calculation
ABAP 動態內錶分組循環
How to detect whether the MySQL code runs deadlock +binlog view
Adaptive non European advertising retrieval system amcad
随机推荐
Probability formula
Analysis on urban transportation ideas of 2022 Zhongqing cup C
Index of MySQL
Analysis on the thinking of college mathematical modeling competition and curriculum education of the 2022a question of the China Youth Cup
[record of question brushing] 2 Add two numbers
[development software] tilipa Developer Software
数据的存储
Use facet to record operation log
使用 BR 备份 TiDB 集群到 GCS
史上最全学习率调整策略lr_scheduler
Redis源码学习(30),字典学习,dict.h
Triple half circle progress bar, you can use it directly
Antd comment recursive loop comment
Summer 2022 daily question 1 (1)
SQL injection -day15
Implementation of map and set
QT opens a file and uses QFileDialog to obtain the file name, content, etc
Redis source code learning (31), dictionary learning, dict.c (1)
杭州电 3711 Binary Number
超越Postman,新一代国产调试工具Apifox,用起来够优雅