Forum     

Go Back   Digit Technology Discussion Forum > Software > Programming
Register FAQ Calendar Mark Forums Read

Programming The destination for developers - C, C++, Java, Python and the lot


Reply
 
LinkBack Thread Tools Display Modes
Old 01-07-2011, 02:31 PM   #1 (permalink)
In The Zone
 
cute.bandar's Avatar
 
Join Date: Jan 2010
Posts: 408
Default Basic javascript questions


I am not learning javascript ATM , but want to know how to do a couple of things for a php project.

Problem 1.
This page: Zenfolio has a nice javascript effect. Click on 'send message' and via onmousedown event a method is called.
But this doesn't work if I save the source of the page locally and then run the local file. Why?

Exact Steps:
  1. save source of Zenfolio | G i a n m a r i o M a s a l a A r t w o r k s | Contact into a file (local.html)
  2. run local.html
  3. click on send message to see that javascript effect doesn't work.
__________________
Computer parts search Engine(for india) : http://goo.gl/Sg8Yv
cute.bandar is online now   Reply With Quote
Advertisements. Register and be a member of the community to get rid of them.
Advertisement

Old 01-07-2011, 02:38 PM   #2 (permalink)
Wise Old Owl
 
abhidev's Avatar
 
Join Date: Sep 2009
Posts: 1,624
Default Re: Basic javascript questions

what effect is that......also have you downloaded the js files???
__________________
Core 2 duo E4500 2.2gHz , ASUS P5GCMX , 3GB Transcend , Corsair VX 550w, MSI R5770 HAWK Edition 1GB, CM HAF-922, LG W2243T 21.5" LCD, I-Ball Baton
abhidev is online now   Reply With Quote
Old 01-07-2011, 02:40 PM   #3 (permalink)
In The Zone
 
cute.bandar's Avatar
 
Join Date: Jan 2010
Posts: 408
Default Re: Basic javascript questions

effect: just calls a function to rewrite the a href.
I didn't download the js files , but tried to set the paths right (relative to absolute)...Is there a way to find the exact relevant js file? so that i won't have to plough through the source code?
__________________
Computer parts search Engine(for india) : http://goo.gl/Sg8Yv
cute.bandar is online now   Reply With Quote
Old 01-07-2011, 02:53 PM   #4 (permalink)
Wise Old Owl
 
abhidev's Avatar
 
Join Date: Sep 2009
Posts: 1,624
Default Re: Basic javascript questions

onmousedown it just posts the form, hides it and then shows the message.

I didn't get what effect are you talking abt
__________________
Core 2 duo E4500 2.2gHz , ASUS P5GCMX , 3GB Transcend , Corsair VX 550w, MSI R5770 HAWK Edition 1GB, CM HAF-922, LG W2243T 21.5" LCD, I-Ball Baton
abhidev is online now   Reply With Quote
Old 01-07-2011, 03:05 PM   #5 (permalink)
In The Zone
 
cute.bandar's Avatar
 
Join Date: Jan 2010
Posts: 408
Default Re: Basic javascript questions

Quote:
onmousedown it just posts the form, hides it and then shows the message.
yes thats what I meant by effect. sorry for being confusing.

SO how do I get it working locally? can someone try it on their machine ?
__________________
Computer parts search Engine(for india) : http://goo.gl/Sg8Yv
cute.bandar is online now   Reply With Quote
Old 01-07-2011, 03:20 PM   #6 (permalink)
Wise Old Owl
 
abhidev's Avatar
 
Join Date: Sep 2009
Posts: 1,624
Default Re: Basic javascript questions

u just need to set the path of the js files correct...and that should work...also don't forget to host it on the server because for ajax to work it should be hosted on the server...also edit the js file and write the entire url 'http://gianmariomasala.zenfolio.com/zf/layout/layout.asmx'
__________________
Core 2 duo E4500 2.2gHz , ASUS P5GCMX , 3GB Transcend , Corsair VX 550w, MSI R5770 HAWK Edition 1GB, CM HAF-922, LG W2243T 21.5" LCD, I-Ball Baton

Last edited by abhidev; 01-07-2011 at 03:28 PM.
abhidev is online now   Reply With Quote
Old 01-07-2011, 03:32 PM   #7 (permalink)
In The Zone
 
cute.bandar's Avatar
 
Join Date: Jan 2010
Posts: 408
Default Re: Basic javascript questions

ok I'll try...
btw how did you figure out it was posting using ajax ?
__________________
Computer parts search Engine(for india) : http://goo.gl/Sg8Yv
cute.bandar is online now   Reply With Quote
Old 01-07-2011, 05:53 PM   #8 (permalink)
Wise Old Owl
 
abhidev's Avatar
 
Join Date: Sep 2009
Posts: 1,624
Default Re: Basic javascript questions

Quote:
Originally Posted by cute.bandar View Post
ok I'll try...
btw how did you figure out it was posting using ajax ?
its not refreshing the page right...so it means its using ajax...
__________________
Core 2 duo E4500 2.2gHz , ASUS P5GCMX , 3GB Transcend , Corsair VX 550w, MSI R5770 HAWK Edition 1GB, CM HAF-922, LG W2243T 21.5" LCD, I-Ball Baton
abhidev is online now   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


 
Latest Threads
- by Charan
- by Sarath
- by clmlbx

Advertisement




All times are GMT +5.5. The time now is 12:31 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.

Search Engine Optimization by vBSEO 3.3.2