PHP File() Function Equivalent To ASP
I'm looking for the ASP equivalent of the PHP file() function. The PHP file(yourURL) returns an array where each element contains a line returned by the URL it called. I only know of Response.Redirect or a straight post/get from a form but that takes the user away from the scripting page. Can ASP 'call' another script page and return it's repsonse as the PHP example I have does??
View Replies
ADVERTISEMENT
In PHP, we have an useful function: array_merge();, not available in ASP. I was wondering, what approach I should use in order to create a similar function, in ASP.
The only way I see it is to use 2 separate arrays, grab their contents and store it temporary into Application server memory, erase the 2 arrays, then put it back into a global Array...
It's a fairly complex process that will also drain a little the server memory... I don't like it. I dont use .NET, so SortedList is out of the game... If you have a function/class made, please let me know.
View Replies
View Related
Like this one:
http://www.php.net/sleep
If not how can I sleep?!
Thank you...
View Replies
View Related
Is there an equivalent function in ASP which does the same as PHP's eval function?
View Replies
View Related
i have a person upload a file, that is done, then i want to email the file. I know the location, but not the file name. How do i find the file name to attach to the location addy?
example:
objEmail.AttachFile("d:greguploads" & filename & """) , "SNAIL_File" , 1
View Replies
View Related
I've recently made a recursive sub in asp to search all folder and subfolders of the map "file" for a certain filename. It will list all results and show a link.
Now there's still a bug. I can't place files in the root because this script won't find 'em. The root i mean files.
If i replace the empty dir with Server.MapPath("") it will show the files in the root but it will show 'em twice. Code:
View Replies
View Related
PHP Code:
function resize($n) {$n=$n*10;return $n;}
what is the equivalent in asp? I get an error with this
Code:
function resize(n)
n=n*10
return n
end function
View Replies
View Related
what th ASP equivalent is of PHP's while statement?
e.g.
while (test=condition){
do stuff;
}
View Replies
View Related
We have piece of hardware that can post xml data via post, A clocking in machine to be exact. The data that it posts is raw and without headers so when I use the PHP (on apache) system variable $HTTP_RAW_POST_DATA all I see is the XML and CRLF's. As the server I need to use this on does not have PHP, I need to use ASP.
I have tried using ALL_RAW and ALL_HTTP with IIS and ASP but cannot get any data out. If I create a form and post some data to the same script I get what I would expect (the field name= then the data). Is there any equivalent to the $HTTP_RAW_POST_DATA in ASP or do I have to enable something to get this data out (there is a flag in php.ini to turn this on).
View Replies
View Related
Is there a asp/sql server 2k equivalent of phpMyAdmin? I can't seem to find one and hate having to use enterprise manager.
View Replies
View Related
Does anyone know if ASP has the equivalent of ISSET in PHP. eg. below:
It just basically says if a variable IS SET do something...
PHP Code:
<?php if (isset($userName)) print "Welcome " . $userName . "<br>"; else print "You are not logged in <br>";?>
View Replies
View Related
I'm used to working with PHP, but have a project that requires me to use ASP. The project is almost finished, but I have one problem that needs to be rectified.
In PHP you can use the NL2BR fundtion to ensure that the line breaks are formatted correctly when viewed on the page.Is there a ASP equivalent?
If so, how exactly would it be utilised with a server behaviour like this?Code:
<%=(rsCategory.Fields.Item("catDescription").Value)%>
View Replies
View Related
is there an equivalent system plot like php_info() in asp?
View Replies
View Related
I am unable to create object of ("Lotus.NotesSession") from ASP page.I am getting OutOfMemory error.
If i do same thing from ASP.Net and add <identity tag in web.config file with My Network
Logon Id and password it works fine. So i want to know How to implement this impersonation in ASP.
View Replies
View Related
is there an equivalent to PHP's eregi_replace.... i know that there is something called tokens enclosed within "[% %]" tags in ASP but i have never used it before... is there anything that can help me such as articles.... i have found some examples from another site but IIS will not load the page.... it just comes out with an empty page. Although when i upload it, it works fine on the webserver.... is there a way to configure it to work on local intranet..?
View Replies
View Related
Does ASP have an equivalent to file_get_contents from PHP? This function essentially returns the output of a webpage.I am also looking for the Perl equivalent if anyone knows that one.
View Replies
View Related
Is there a piece of forum s/w like vBulletin but that runs on ASP/MS SQL Server rather than PHP/MySQL? Someone has asked me about setting up a forum for a client, and though I've written forum s/w myself and much of the functionality is simple enough to do, on this ocassion a more generic approach will be acceptable and more cost effective.
vBulletin is undoubtedly the forum daddy, but the server is an IIS box running ASP (obviously) and in tandem with a SQL Server and that isn't going to change.
View Replies
View Related
i am doing a webpage for a charity i volunteer at. i am setting up a database of all the funders we have sent to and what not. i am trying to code an asp page so that we can only see each funder by the first letter of its name.
i have made the index page which is just html to go to equivilent asp page. then on the asp page i want to query the database and only display the funders that begin with that letter. i have asp code to connect to the database and read from it all i need is to only look for funders that begin with ..
View Replies
View Related
DO we have a function that works like javascript's CharAt(i). I have tried Mid but then found out that it doesn't work in VBScript. What Should I do?
View Replies
View Related
I have some tracking software I wrote in PHP that simple collects a GET string and enters data into a database. I wrote it this way so to use my tracking software all one has to do is pass a few paramaters in the query string and viola, page tracked.
It was also written this way so multiple platforms (read: ASP) could be supported. I am a noob when it comes to ASP but I did manage to write a little script that collects variables, sets cookies and builds the url to post. However, after trying Server.Execute, Server.Redirect, and even an XML object I have not achieved success. Code:
View Replies
View Related
Is there an ASP equivilant of the VB DoEvents function? I am having problems with an ASP script that copies a set of folders and then renames them. Basically the code is running too quickly and it tries to rename the folder before it has been created.
I think in VB you can use the DoEvents function to make sure it has finished doing one bit of your code before moving on to the next bit. Is there zomething I can do in ASP to resolve this problem?
View Replies
View Related
I need to ba able to update records of my database via a user-input form. I have some scripts that uses the Persits objects, such as PersitsUpload.1, that allows to do that.
But, since I am hosting my programs somether that the server does not have persits objects my program fails. What is the equivalent PersitsUpload.1 objects in ASP which allow upload, edit/delete/create new records from user inout via form? Or is there a better way to do this?
View Replies
View Related
I need help creating an asp upload page that will allow the user to browse a local .txt file and then submit it a SQL database. At the same time I would like SQL to run an equivalent process to BCP and add each line in the .txt file to a table.
View Replies
View Related
working on a windows/iis for the first time... is there any equivalent to *nix symbolic links in windows/iis? i'm in a shared account, so i need something like an .htacces or .lnk file...
what i'm looking for is redirect every request to "/my_dir/images" to "/images".
View Replies
View Related
Can anybody tell me what is the equivalent of response.end in Javascript?????For eg,consider the following:
<%
if i=1 then
.
.
.
else
resposne.write("Error Message!")
response.end
end if
%>
I am using a confirmation box in my program.If the users clicks "Cancel" he should be redirected to the page he was last viewing and stop the action.
<script>
var cc=confirm("Do you want to update the changes?")
if (cc==false) then
{
window.history.go(-1)
here i wud want the response to end
}
</script>
View Replies
View Related
I am looking for the equivalent of $_SERVER[PHP_SELF] in ASP. I have looked at the Page and Request Class. Didn't quite find what I want.
View Replies
View Related
I have the following code that returns a string from once it has been descrypted
Code:
varCaseManager = DeCryptString(request.QueryString("CaseManager"))
Usually i use this for integers but before i can use the variable i have to use Cint to get the actual value to use in a database. Is there an equivalent fucntion to Cint that returns the string value?
View Replies
View Related
I am trying to find a function in ASP that is the equivalent to PHP's is_dir and is_file. I searched google but had no luck. If no function exists does anyone have another way of determining a folders content and whether or not that content is either a file or folder.
View Replies
View Related
I'm doing some error logging on a page and I want to catch a specific error. The error is when the form is submitted and validated, if the entry already exists in the database, rather than displaying the default ugly error, use a custom one.
I can do this with ColdFusion using the <cfcatch> and <cftry> but is there an equivalent in ASP? I know ASP.NET has the 'catch' and 'try' but that doesn't really help me much. the error code for a duplicated entry is -1605.
View Replies
View Related
I'd like to do something similar to CFParam, but in ASP - basically, I have a form variable ("Type") which may or may not be passed from the referring page. Some referring pages have an input field called "Type", whilst others do not.
I'm actually a CF developer, but keen to learn ASP. My current code at the top of the script is : Code:
View Replies
View Related
I was wondering if anybody could help me translate this from my native Cold Fusion tongue to ASP? :
#DateFormat(Visitors_DateTime, 'dd mmmm yyyy')#
#TimeFormat(Visitors_DateTime, 'h:mm tt')#
The data is held with SQL2000 in a smalldatetime datatype column.
Would just like to display the full date and time really.
View Replies
View Related
What's the difference between private and public functions in ASP? When should I use either?
View Replies
View Related
I am using a simple guestbook /portal and i want script to send mail to the thread owner when someone reply his message.
this is the send message code ....
View Replies
View Related