[Import] common ASP functions: loadfromfile ()

'Function: Get file data streams'Source: http://jorkin.reallydo.com/article.asp? Id = 523 Function loadfromfile (sfilename, scharset)On Error resume nextDim ostreamSet ostream = server. Createobject ("ADODB. Stream ")Ostream. type = 2Ostream. mode =

[Import] common ASP functions: str4js ()

'Function: Define the conversion to javascript string output (Convention in Javascript, reference the string with single quotes)'Source: http://jorkin.reallydo.com/article.asp? Id = 465 Function str4js (sstring)Str4js = sstringIf isnull (sstring)

Remove HTML tags from asp.net

Using system;Using system. Web;Using system. Text. regularexpressions;   Public static string nohtml (string htmlstring){// Delete the scriptHtmlstring = RegEx. Replace (htmlstring, @ " "," ", regexoptions. ignorecase );// Delete HTMLHtmlstring =

C # common function tables and Asp.net (C #) Common Function tables

C # common function tables 1. DateTime numeric typeSystem. DateTime currentTime = new System. DateTime ();1.1 take the current year, month, day, hour, minute, secondCurrentTime = System. DateTime. Now;1.2 get current yearInt Year = currentTime. Year;

Dynamically load the Asp.net paging Control

In Asp.net, it is relatively simple to dynamically load controls. Here I am talking about the loading of user controls. A typical example is that the loaded user control contains a send-back event, new data must be retained when it is

Asp.net generates html static pages

This function is applicable to websites with poor background database functions, that is, most of the text is not stored in the database records, but in html or xml files, and only the index is placed in the database, such as the title, category,

ASP. NET program implements blog calendar

Front-end page webform1 DayHeaderStyle-BackColor = "# 5e715e" OtherMonthDayStyle-ForeColor = "# cccccc" DayNameFormat = "Full"Runat = "server" TitleStyle-ForeColor = "# ffffff" NextPrevStyle-ForeColor = "# ffffff" CellSpacing =

ASP. NET page indication identifier

The page indication mark function is used to determine what special settings do the system need when processing the aspx file? Its syntax is: For example:   Note that space is required between attributes, and no space is allowed between "=. The web

Routine for connecting ASP to SQL Server2000 data warehouse

Dim mode Mode = request. form ("text4 ") If mode = 1 then Name = request. form ("text1 ") Age = request. form ("text2 ") Addr = request. form ("text3 ") If not isnumeric (age) then response. write "age must be number! try again ": response.

JQuery $ post usage in asp.net

Function prototype: $. post (url, params, callback) UrlIs the submitted address. For example:"Sample. ashx" ParamsYes. For example:{Name: "xxx", id: "001 "} CallbackIs the callback function. For example:Function (msg) {alert (msg );} NOTE 1: In

Asp.net uses jQuery for Data Binding and paging

Use jquery to bind and pagination the data of server-side data display controls such as gridview and repeater. This article focuses on how to bind data.Content Jquery's strength and availability make it popular quickly. Microsoft also released a

Asp.net's four error event handling methods

ASP. NET error handling methods (Collation & summary)Research on http://wrfwjn.blog.hexun.com/4172839_d.htmlSummary:To create a global handler on the page, create a handler for the Page_Error event. To create an error handler within the application

ASP. NET outputs pure XML data

Sometimes the Asp.net file outputs pure XML data very useful, then the Asp.net file is equivalent to a WebService, the output XML document is also very simple, divided into the following parts1. Set the output type-response. contenttype = "text/XML "

The problem that the page font becomes larger due to response using response. Write () in ASP. NET

For example, there is a LinkButton in the page. You need to click it to open a new window, And the URL of the new window is generated dynamically based on the user selection result. Write the LinkButton Code as follows:Protected void

[Import] common ASP functions: HTMLFilter ()

'Filter various HTML Tag style scripts'Source: http://jorkin.reallydo.com/article.asp? Id = 521'Need RegReplace function: http://jorkin.reallydo.com/article.asp? Id = 345 Function HTMLFilter (sHTML, sFilters)If sHTML & "" = "" Then Exit FunctionIf

[Import] common ASP functions: PCase ()

'Function: converts the first letter of each word in a string to uppercase.'Source: http://jorkin.reallydo.com/article.asp? Id = 481 Private Function PCase (byVal sString)Dim Tmp, Word, Tmp1, Tmp2, firstCt, a, sSentence, c, IIf IsNull (sString)

[Import] common ASP functions: Exec ()

'Function: Execute an SQL statement'Source: http://jorkin.reallydo.com/article.asp? Id = 487 Public Function Exec (sCommand)On Error Resume NextOpenConn ()Set Exec = oConn. Execute (sCommand)If Err ThenWriteLn Err. Source & ", please check whether

[Import] common ASP functions: DelArray2 ()

'Function: Delete the row with the value of sValue in the iColumn of the Two-dimensional array. When the value of iColumn is-1, delete the row sValue.'Source: http://jorkin.reallydo.com/article.asp? Id = 483 Function DelArray2 (aArray, iColumn,

[Import] How to use ASP to capture server-side encrypted Web pages?

For example: Http://bill.finance.sina.com.cn/bill/detail.php? Stock_code = sh600900 & bill_size = 40000 There are a few words about the captured Stream Server: nginx/0.5.19 and Accept-Encoding: gzip, deflate Content-Encoding: deflate is an

[Import] common ASP functions: FormatDate ()

'Function: Date Formatting Function'Source: http://jorkin.reallydo.com/article.asp? Id = 477 Function formatdate (sdatetime, sreallydo)Dim sjorkinSjorkin = getlocale ()If not isdate (sdatetime) Then sdatetime = now ()Sdatetime = cdate

Total Pages: 1800 1 .... 1255 1256 1257 1258 1259 .... 1800 Go to: GO

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.