This is a discussion on "Calling functions" within the Classic ASP section. This forum, and the thread "Calling functions are both part of the Program Your Website category.
|
|
|
|
|
![]() |
||
Calling functions
|
||
| Notices |
![]() |
|
|
LinkBack | Thread Tools |
|
|||
|
Hi I am fairly new to ASP so don't laugh too loud. Firstly, how do I call functions in ASP and is it possible to call a javascript from ASP.
Regards Rob |
|
|
|
||||
|
Re: Calling functions
You call a function like this:
Your question was a bit vague. If you could be a bit more specific or post some code, it would help us help you.
Last Blog Entry: 10 Reasons Why My Laptop Is Better Than Your Girlfriend (Dec 15th, 2007)
|
|
|||
|
Re: Calling functions
Hi thanks for that. I fully understand the javascript you posted but wondered if a javascript function can be called by using VB script. The reason I ask is that I am running a small access database on a site and as far as I am aware you can't make a connection via javascript, (or can you?), so I am using ASP VB script to access the database and javascript to do other stuff. Or am I asking too much?
Cheers Rob |
|
||||
|
Re: Calling functions
Javascript is client-side. ASP is server-side.
That means that ASP generates HTML and Javascript and sends it to the browser. Javascript runs on the client browser and can't access a server. The two languages can't "run" together because one lives on a web server and the other lives in browsers, so to speak. I think you could load stuff from a databank using Ajax, but I'm not an Ajax person at all.
Last Blog Entry: 10 Reasons Why My Laptop Is Better Than Your Girlfriend (Dec 15th, 2007)
|
|
|||
|
Re: Calling functions
Thanks, that makes a lot of sense now. I should have realised that.
Cheers |
|
||||
|
Re: Calling functions
I can understand you. It took me a while to grasp the concept of client / server side languages. When I was learning PHP I kept getting confused about what I could and couldn't do because I didn't realize that HTML is client side and PHP generates HTML on the server and sends the output to the browser....
Anyway, you're welcome and good luck!
Last Blog Entry: 10 Reasons Why My Laptop Is Better Than Your Girlfriend (Dec 15th, 2007)
|
![]() |
| Tags |
| asp |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| calling functions in a function | fatsurfer | PHP Forum | 1 | Jun 12th, 2008 21:53 |
| Calling functions with variable? | CloudedVision | JavaScript Forum | 1 | Apr 18th, 2008 08:44 |
| Functions? | Jack Franklin | PHP Forum | 10 | Feb 3rd, 2008 16:49 |
| Calling functions between frames | apparentlyso | JavaScript Forum | 0 | Oct 18th, 2006 21:07 |
| Calling functions in mail message | Andy K | PHP Forum | 2 | Aug 24th, 2005 18:47 |