master
editor 3 weeks ago
commit 15d6e328c6

@ -0,0 +1,40 @@
51ASPX可拖曳简单新闻系统
一、源码描述
环境VS2022 sql2019
二、功能介绍
一个可以简单实现模块的拖曳、锁定、最大化、最小化控制的示例,用简单新闻系统来展示。
采用了SqlHelper进行数据库操作
注意该系统采用Sql2005数据库现已升级至sql2019
需要在Edge浏览器中使用IE模式访问该网站。
三、注意事项
1、在项目web.config修改数据库连接字符串附加数据库。
2、管理员账号与密码admin 51aspx 。
3、ctrl+F5运行即可。
作者: 不详
如需获得该源码的视频、更新等更多资料请访问: https://www.51aspx.com/Code/DragDropNews
------------------------------------------------------------------------------------------------
源码服务专家
官网: https://www.51aspx.com
讨论圈: https://club.51aspx.com/
平台声明:
1.51Aspx平台上提供下载的资源为免费、共享、商业三类源码,其中免费和共享源码仅供个人学习和研究使用,商业源码请在相应的授权许可条件下使用;
2.51Aspx平台对提供下载的软件及其它资源不拥有任何权利,其版权归属源码合法拥有者所有;
3.著作权人发现本网站载有侵害其合法权益的内容或作品,请与我们联系( 登录官网与客服反馈或发送邮件到support@51Aspx.com
4.51Aspx平台不保证提供的下载资源的准确性、安全性和完整性;
友情提示:
一般数据库文件默认在 DB_51Aspx 文件夹下
默认账号密码一般均为51Aspx
关于源码使用常见问题及解决方案,请参阅: https://www.51aspx.com/Help

@ -0,0 +1,15 @@
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="AddNews.aspx.cs" Inherits="AddNews" %>
<!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 runat="server">
<title>无标题页</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<table align="center" width="500" border="0" cellspacing="0" cellpadding="3">
<tr>
<td>添加新闻</td>
</tr>
<tr>

@ -0,0 +1,15 @@
using System;
using System.Data;
using System.Data.SqlClient;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Text;
public partial class AddNews : System.Web.UI.Page
{

@ -0,0 +1,15 @@
using System;
using System.Collections;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Text;
using System.Text.RegularExpressions;
// ********************
// PageHelp页面辅助类

@ -0,0 +1,15 @@
using System;
using System.Data;
using System.Data.SqlClient;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Text;
/// <summary>
/// SqlHelp 的摘要说明
/// </summary>

@ -0,0 +1,15 @@
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default.aspx.cs" Inherits="_Default" %>
<!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 runat="server">
<title>页面拖曳——示例</title>
<link href="DragDropStyle.css" rel="Stylesheet" />
<script type="text/javascript" language="javascript" src="Prototype.js"></script>
<script type="text/javascript" language="javascript" src="DragDrop.js"></script>
<script type="text/javascript" language="javascript">
//所有可以使用的模块
CDrag.database.json = [
//tag:"1"是我自己加的,目的是给它一个额外的参数
/*
{ id : "m_1_1", title : "国际新闻", className : "News", src : "News", tag : "1" },

@ -0,0 +1,15 @@
using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Text;
public partial class _Default : System.Web.UI.Page
{
protected string databaseContent;
protected string eventContent;

@ -0,0 +1,15 @@
var CDrag = Class.create();
CDrag.IE = /MSIE/.test(window.navigator.userAgent);
CDrag.load = function (obj_string, func, time) {
//加载对象
var index = 0, timer = window.setInterval(function () {
try {
if (eval(obj_string + ".loaded")) {
window.clearInterval(timer);
func(eval("new " + obj_string));
}
} catch (exp) {}
if (++ index == 20) window.clearInterval(timer);

@ -0,0 +1,15 @@
html, body {
width:100%;
height:100%;
padding:0px;
margin:0px;
}
body {
text-align:center;
font-size:14px;
}
.cell_left, .cell_right {
width:202px;
}

@ -0,0 +1,15 @@
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="News.aspx.cs" Inherits="News" %>
<!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 id="Head1" runat="server">
<title><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD></title>
</head>
<body>
</body>
<a href="http://www.51aspx.com" target="_blank">download from 51aspx.com</a>
</html>

@ -0,0 +1,15 @@
using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Text;
public partial class News : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)

@ -0,0 +1,15 @@
var News = Class.create();
News.prototype = {
initialize : function () {
var wc = this;
wc.parent = null;
wc.ajax = new CDrag.Ajax;
},
edit : function (o) {
alert("<22><>ʱû<CAB1>п<EFBFBD>ͨ<EFBFBD><EFBFBD><E0BCAD><EFBFBD>ܡ<EFBFBD>");
//alert("<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>չ<EFBFBD><D5B9><EFBFBD>һ<EFBFBD><D2BB><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Դ<EFBFBD>News.js<6A><73><EFBFBD>Լ<EFBFBD><D4BC><EFBFBD><EFBFBD>ã<EFBFBD><C3A3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ڸı<DAB8><C4B1><EFBFBD><EFBFBD><EFBFBD>Ϊ<EFBFBD><CEAA><EFBFBD><EFBFBD>");
//o.content.innerHTML = o.title.innerHTML;
},

@ -0,0 +1,15 @@
var Class = {
//创建类
create : function () {
return function () {
this.initialize.apply(this, arguments);
};
}
};
var $A = function (a) {
//转换数组
return a ? Array.apply(null, a) : new Array;
};
var $ = function (id) {

@ -0,0 +1,15 @@
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="ShowNews.aspx.cs" Inherits="ShowNews" %>
<!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 runat="server">
<title>无标题页</title>
</head>
<body>
<form id="form1" runat="server">
<div>
<asp:DetailsView ID="dvwNews" runat="server" Height="50px" Width="400px" AutoGenerateRows="False">
<Fields>
<asp:BoundField DataField="NewsCaption" HeaderText="主题:" />
<asp:BoundField DataField="NewsContent" HeaderText="内容:" />
</Fields>

@ -0,0 +1,15 @@
using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
//该源码下载自www.51aspx.com()
public partial class ShowNews : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{

@ -0,0 +1,15 @@
<!DOCTYPE html>
<!-- saved from url=(0014)about:internet -->
<html xmlns:msxsl="urn:schemas-microsoft-com:xslt"><head><meta content="en-us" http-equiv="Content-Language" /><meta content="text/html; charset=utf-16" http-equiv="Content-Type" /><title _locID="ConversionReport0">
Migration Report
</title><style>
/* Body style, for the entire document */
body
{
background: #F3F3F4;
color: #1E1E1F;
font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
padding: 0;
margin: 0;
}

@ -0,0 +1,15 @@
<?xml version="1.0"?>
<!--
注意: 除了手动编辑此文件以外,您还可以使用
Web 管理工具来配置应用程序的设置。可以使用 Visual Studio 中的
“网站”->“Asp.Net 配置”选项。
设置和注释的完整列表在
machine.config.comments 中,该文件通常位于
\Windows\Microsoft.Net\Framework\v2.x\Config 中
-->
<configuration>
<appSettings>
<!--<add key="sqlServer2005DbName" value="App_Data\DragDropDemo.mdf"/>-->
<add key="sqlServer2005DbName" value="Data Source=.;Initial Catalog=DragDropDemo;Integrated Security=True;"/>
</appSettings>
<connectionStrings/>
Loading…
Cancel
Save