Exit
  • Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
  • 한국 커뮤니티
0

Generate html from database before runtime (infrequent sql query)

Community Beginner ,
Jan 21, 2011 Jan 21, 2011

Hi,

I have a SQL query which I want to use to update one section of my web page but the data only changes once a month.  I don't need a dynamic page where the results are executed against the database every time the page is opened (results display on the main index.htm of my web site).

Is there some way to configure DW (preferably DW CS3) so that it will query the database and insert the results into my static html page being edited on my machine?

Is there a general technique for including SQL data in static web pages in DW?

Thanks,

G

TOPICS
Server side applications
463
Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jan 21, 2011 Jan 21, 2011

There is nothing built into DW that will do this. You can just do it manually like this:

Create a dynamic page that incorporates your database query. Save this in a private location, away from spiders. Once a month, access the page and then get the html from the page source. Use that in your static page.

You could probably write a script to automate this.

What's wrong with just using a dynamic page, even though the data is updated infrequently?

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jan 21, 2011 Jan 21, 2011

tx for the tip.

reason: gobaddy's mysql servers are slow pokes.  i have a larger application where the list would be a dozen or more pages long and only the last entry changes with my update each month.  figured I'd generate all the pages and then just update the first one but your method is the same thing minus all the fuss of screwing around with the first page all the time.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jan 21, 2011 Jan 21, 2011
LATEST

I guess the "feature" to use in DW is the server feature... setup a test server, deploy the script to

that, execute the page(s) to generate the html, scrape that for html and then put that in the real pages and post to the

actual web server.

Translate
Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines