Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 6 of 6
  1. #1
    New to the CF scene
    Join Date
    Oct 2007
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts

    ASP and JavaScript working together

    Hi. I understand that ASP is server side and JS is, at least in my case, run on the client. So, an ASP process will be run before a JS process. I want to make them work together if possible.

    Here is my problem: I have an ASP process that uses a component on my server to FTP files from my server to another. It gets the files it needs and FTP settings from a database and runs great.

    Then, I have a progress bar in JS. I can run a loop to test it and it runs great.

    Now, I want to combine the two so that as each file is transferred from my server the progress bar progresses. The problem is that the ASP process run to completion before the progress bar is ever displayed on the page.

    My next approach is to use an if statement to see if the counter is equal to the number of records from the recordset of files to transfer. Maybe if I do it that way I can transfer one file at a time and then update the prograss bar instead of trying to do it all at one in a while loop.

    Does anyone else have any ideas on how I could do this?

  • #2
    Regular Coder
    Join Date
    Mar 2007
    Posts
    505
    Thanks
    1
    Thanked 19 Times in 19 Posts
    Look at ASPUpload' Progress Bar.

    While you do not need to use their software, they have an ASP and JS 'progress bar' that works well for both IE and FF.

    Also - JS is ALWAYS client-side, not just in your case.
    To say my fate is not tied to your fate is like saying, 'Your end of the boat is sinking.' -- Hugh Downs
    Please, if you found my post helpful, pay it forward. Go and help someone else today.

  • #3
    Senior Coder nikkiH's Avatar
    Join Date
    Jun 2005
    Location
    Near Chicago, IL, USA
    Posts
    1,973
    Thanks
    1
    Thanked 32 Times in 31 Posts
    JS is ALWAYS client-side
    What do you call server-side javascript, then? JScript?

    If this post contains any code, I may or may not have tested it. It's probably just example code, so no getting knickers in a bunch over a typo, OK? If it doesn't have basic error checking in it, such as object detection or checking if objects are null before using them, put that in there. I'm giving examples, not typing up your whole app for you. You run code at your own risk.
    Bored? Visit
    http://www.kaelisspace.com/

  • #4
    Regular Coder
    Join Date
    Mar 2007
    Posts
    505
    Thanks
    1
    Thanked 19 Times in 19 Posts
    JScript is M$'s version of JavaScript, with some non-standard M$ crap put into it as well as the ability to embed code into pages.

    ( I'm an ASP programmer and I still hate M$. Go figure... =| )

    What is commonly referred to as JavaScript is technically Mozilla/Netscape's implementation of the ECMA Scripting language.

    There are 3 versions of "JavaScript": Client-side [CS], Core, and Server-side [SS].

    CS tracks the effect a user has on a web page.

    Core includes the functions, variables, and LiveConnect, the tool used to connect CS <- Core -> SS.

    SS JS is embedded EXECUTABLES, known as bytecode executable files.

    So, yeah, I guess it would be called JScript.
    To say my fate is not tied to your fate is like saying, 'Your end of the boat is sinking.' -- Hugh Downs
    Please, if you found my post helpful, pay it forward. Go and help someone else today.

  • #5
    Senior Coder nikkiH's Avatar
    Join Date
    Jun 2005
    Location
    Near Chicago, IL, USA
    Posts
    1,973
    Thanks
    1
    Thanked 32 Times in 31 Posts
    I'm an ASP programmer and I still hate M$. Go figure... =|
    Well, I code mostly in .NET and I hate them too. LOL

    Awhile back there used to be server-side javascript for Netscape Enterprise Server as well, but it's been awhile since I've worked with Unix, so I don't know if that's still around.

    I think some programs, such as Adobe, even have their own version of javascript implemented to interact with their objects. Way to confuse people, eh?

    If this post contains any code, I may or may not have tested it. It's probably just example code, so no getting knickers in a bunch over a typo, OK? If it doesn't have basic error checking in it, such as object detection or checking if objects are null before using them, put that in there. I'm giving examples, not typing up your whole app for you. You run code at your own risk.
    Bored? Visit
    http://www.kaelisspace.com/

  • #6
    Regular Coder
    Join Date
    Mar 2007
    Posts
    505
    Thanks
    1
    Thanked 19 Times in 19 Posts
    Don't get me started on ActionScript and Flash.... I love designing in Flash and it's ability to do some really cool stuff, but do I really have to learn another version of *Script?? I think that I am up to 4 (JavaScript, JScript, ActionScript, VBScript).

    ...blech...

    And I just noticed how totally OT this has become... Mosqwik - I hope we answered your question...
    To say my fate is not tied to your fate is like saying, 'Your end of the boat is sinking.' -- Hugh Downs
    Please, if you found my post helpful, pay it forward. Go and help someone else today.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •