Problems with ASP generating static pages

Updated on technology 2024-04-04
9 answers
  1. Anonymous users2024-02-07

    Forehead. I'll come and help you in the evening. Went to work.

  2. Anonymous users2024-02-06

    asp ..NET technology implements pages with a .com extension ofaspx, aspx is a very popular dynamic web page format at the moment.

    One of the characteristics of dynamic web pages is that information is interactive, updated in a timely manner, and the page has few files, and the development speed is fast. However, one of its serious problems is that in the case of a large number of visits, and the configuration and resources of the server are relatively limited, each access may frequently process program logic, read and write databases, etc., which will reduce the performance of the server.

    Tools Raw materials.

    Static method 1:

    Rewriting each page requires a static dynamic page. The render() method of the CS file, as shown in the following figure. Note that in the red box, the parameters in the red box indicate the name of the static page to be generated.

    This method is simple to implement, but every time you visit the page, the render() method will be re-executed to generate the page, and the performance is low.

    Static method two:

    1. Remake an aspx page, which is specially used to generate a static page of each dynamic search vertical aspx page. As shown in the figure below, only the content page and the main page are generated as static pages, of course, this example is just a simple example, the actual situation is very complex, but the principle is the same.

    2. Generate content page:

    In this example, different content pages are distinguished by different IDs, enter different ID values, and click the "Generate Content Pages" button to call the execution backend (as shown below) to generate HTML pages.

    If the content of the content page changes, repeat the steps above and regenerate it.

    The parameters in the following figure represent the dynamic URL, static path, and static file name, respectively, which need to be modified in more practical situations.

    3. Generate the main page:

    Directly click the "Generate Homepage" button in the foreground to execute the backend** (as shown in the figure below), and the homepage HTML will be generated. If the content of the homepage changes, you can regenerate it. The parameters in the following figure need to be modified according to the actual situation.

    This summary of experience provides two ideas and methods for generating static pages with a simple example, which may be more complex, but the principle is the same.

  3. Anonymous users2024-02-05

    It's as simple as marking each page with a serial number, and then the page is fixed, and it doesn't change, and there aren't as many as in dynamic pages? No. or something.

  4. Anonymous users2024-02-04

    Web pages have both static and dynamic pages

    One-click generation of static pages, that is, after clicking the button, ASP will automatically execute some programs to generate static web pages

  5. Anonymous users2024-02-03

    Emit hypertext content with <%= or method.

  6. Anonymous users2024-02-02

    Then you will see a line of text on the page: "1234".

    If you see these numbers, you have successfully tested.

    Now let's start configuring ISAPI rewrite:

    Open the ISAPI rewrite directory, remove the read-only attribute, and open it. What do we need to put now? id=1234 to something like new, so we need to add a sentence to it.

    Once saved, we can test this**.

    You can see the "1234" on the page, so the pseudo-static configuration is successful!

    Of course, the above is just simple, according to the actual situation, there are also table of contents type, as well as page turning type and so on.

    ==There is also a kind of CMS that I have used Kexun.,You can set it in the background of the program.,The landlord's must also be CMS.,Dedecms or Imperial CMS or Dream CMS? There's php168, popular and so on.。。。

  7. Anonymous users2024-02-01

    do url = your **address.

    strurl = do_url

    dim objxmlhttp

    set objxmlhttp =

    get,strurl,false

    dim binfiledata

    binfiledata =

    dim objadostream

    set objadostream =

    1filepath,2

    nexthtml_temp = html_temp&%>

    ( Successfully generated file: ).

    html_temp

    Method 2: Template file and data replacement method, which is a more convenient method of generating static pages, the method is to first establish one or more HTML-based template files, use special strings in the file to represent the variable values to be replaced, and then use the query and replacement method to replace the corresponding strings with the values in the database to generate. A fully static page for HTML.

  8. Anonymous users2024-01-31

    There are only two main steps in generating the HTML method:

    1. Get the content of the HTML file to be generated.

    2. Save the content of the obtained html file as an html file.

    At present, there are several commonly used methods to obtain the content of an HTML file:

    1、 str="str=str&"This method is not convenient to preview the content of the generated page, it is not possible to visualize the layout of the page, and it will be more complicated when changing the HTML template.

    There are many people who use this method, but I feel that this method is the most inconvenient.

    2. Make a separate HTML template page, use specific characters as markup for dynamic content (e.g., someone tags it as the title of the page with $title$), load it with or load its template content, and then replace the original markup with dynamic content with a replacement method.

    For example: replace(Loaded template content,"$title$",rs("title" )

    3. Use XMLHTTP or serverXMLHTTP to get the HTML content displayed on the dynamic page

  9. Anonymous users2024-01-30

    Dynamic web page: Generally refers to the page dynamically generated by ASP, JSP, PHP, COLD FUSION, CGI and other programs, and most of the data content in the web page comes from the database connected to **. This page doesn't exist in cyberspace, and dynamic web pages tend to make a great impression.

    In addition, dynamic web pages have the advantage of being easy to maintain and update.

Related questions
8 answers2024-04-04

If you do it small, put some company profiles and the like, and do it static. Cheap.

16 answers2024-04-04

rewriterule /(.*html $ is not executed because you have this sentence in front of you. >>>More

11 answers2024-04-04

1. The dynamic page cache implemented by the application caches the html file generated by the dynamic file to the file server, and then the user requests the dynamic file, and the corresponding static cached html file is loaded directly from the file server and returned to the user, which mainly saves the execution time of the dynamic language and the database access time. However, the caching framework will be added.

4 answers2024-04-04

dim rs,sql,filename,fs,myfile,objspreadsheet,x

set fs = "") >>>More

7 answers2024-04-04

I guess I'll have to convert this myself.