473,394 Members | 1,773 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

how to make a htm page by ASP FSO

Hello, I tried to use FSO to have a function.

the idea is when people fill out the form which include the property
information.

such as hotel info, hotel image,..., then when they hit the button

the system will create a html page for this resort with some name like

http://www.resorts.com/resort/resort23432345.htm, and name of resort
page should be
generate dynamic by FSO function from a ASP page.
and i do try use FSO, but hard to find the info how to generate a HTM
page by ASP File System Object
function.
and hints will be great appreciate it.
Jul 19 '05 #1
5 2380
what is the problem you are having?

"work4u" <ro*****@yahoo.com> wrote in message
news:9c**************************@posting.google.c om...
Hello, I tried to use FSO to have a function.

the idea is when people fill out the form which include the property
information.

such as hotel info, hotel image,..., then when they hit the button

the system will create a html page for this resort with some name like

http://www.resorts.com/resort/resort23432345.htm, and name of resort
page should be
generate dynamic by FSO function from a ASP page.
and i do try use FSO, but hard to find the info how to generate a HTM
page by ASP File System Object
function.
and hints will be great appreciate it.

Jul 19 '05 #2


Hello,

I'd like to know how to generate a htm page by asp function rather than
write to a txt file, and I know that File System Object can finish that
work.

a simple link as below
http://rentalo.com/properties/1_bedr..._huatulcomexic
o.html

and i think this page is automatic generate when people filled out a
form . and i just would like to have a function to finish this kind of
job.

so, if anyone can show me where can i find some sample code, that will
be a great appeciate it.

Ross
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 19 '05 #3
Try this:

<%
theSite="http://www.resorts.com/resort/resort23432345.htm"

Set objWinHttp = Server.CreateObject("WinHttp.WinHttpRequest.5.1")
objWinHttp.Open "GET", theSite
objWinHttp.Send

StrHTML = replace( objWinHttp.ResponseText, "<html>","<html><BASE href=" &
theSite & ">")

dim fs,f
set fs=Server.CreateObject("Scripting.FileSystemObject ")

set f=fs.CreateTextFile("e:\myfile.htm",true)

f.WriteLine StrHTML

f.close
set f=nothing
set fs=nothing
set objWinHttp= nothing
%>
Jul 19 '05 #4
Hi

thank you very much for the code.

and i just tried it and it seem something still wrong.

so I did replace "http://www.resorts.com/resort/resort23432345.htm"

with an real full URL like "http://www.vegasall.com/index.asp"

and change this part "set f=fs.CreateTextFile("e:\myfile.htm",true)"
with the real path, and saved this page as htm.asp page

so when i run this page in my PC, it should like convert index.asp code
and save to my pc as name myfile.htm.

but when i runing the asp page, the page just like frozen there. I am
wondering do i need to configure to run FSO ?

PS: i use win200 server and runing IIS, and i use dreamweaver ultradev
to run the page...
thanks again for your continue help.

Ross




*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Jul 19 '05 #5
it is more likely that you need to install the latest service pack so the
first component will run.
response.write the strHTML.
if that fails then
Goto microsoft and download the winhttp component

"ross b" <ro*****@yahoo.com> wrote in message
news:uo**************@TK2MSFTNGP10.phx.gbl...
Hi

thank you very much for the code.

and i just tried it and it seem something still wrong.

so I did replace "http://www.resorts.com/resort/resort23432345.htm"

with an real full URL like "http://www.vegasall.com/index.asp"

and change this part "set f=fs.CreateTextFile("e:\myfile.htm",true)"
with the real path, and saved this page as htm.asp page

so when i run this page in my PC, it should like convert index.asp code
and save to my pc as name myfile.htm.

but when i runing the asp page, the page just like frozen there. I am
wondering do i need to configure to run FSO ?

PS: i use win200 server and runing IIS, and i use dreamweaver ultradev
to run the page...
thanks again for your continue help.

Ross




*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Jul 19 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

31
by: Bruce W...1 | last post by:
This is a best practices question. For a website where PHP is used, does it make sense to have both .htm and .php files? In other words, for pages that have no active content there's no point...
7
by: WindAndWaves | last post by:
Hi Gurus I am keen to make a search page on a website, but I have absolutely zero experience with PHP. I am going to hire an expert, but I thought that it may pay to try it a bit first myself...
40
by: Brian Jorgenson | last post by:
On my web page, I have a few hyperlinks with target frame of _blank. The hyperlink brings up a second window, but everytime I click on thie hperlink, it keeps bringing up a new window and not...
37
by: ajay | last post by:
How to make a web page getting refreshed after a given time interval automatically. HTML Code plz. Tx Ajay
5
by: Simon Harvey | last post by:
Hi there everyone, I have a fairly open ended but simple question that I could really use some assistance with. When I first bought visual studio (under the student license) i thought it was...
2
by: Dexter | last post by:
Hello all, I have webform1, and i need to make a bow to catch all textbox in my webform1. I tray this, but don't function. Dim obj As System.Web.UI.WebControls.TextBox Dim cont As Integer For...
6
by: Jeremy S. | last post by:
Sorry if this is too far OT - I posted this in the IIS group and got no response - so here goes: What would be a good or recommended way to make a Web site in IIS6 inaccessible to users on the...
1
by: jasdak | last post by:
i want to programatically make my page of varying height based on the content. if you go to trinadoula.com you will see what i am talking about. you'll see the mid section of the page is a bar...
6
by: scottyman | last post by:
I can't make this script work properly. I've gone as far as I can with it and the rest is out of my ability. I can do some html editing but I'm lost in the Java world. The script at the bottom of...
6
by: divya | last post by:
I have a page name edit.asp which should expire immediately .The user cannot open this page directly he has to provide a password for entering this page.thus when the user enters edit.asp , it has...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.