eTI-True Indian Community:India Forums

March 19, 2010, 10:52:05 AM
Welcome, Guest. Please login or register.

Login with username, password and session length
Ask the Experts
Ask a Question Now

Play Games Now

Beat Highscores, compete against other online players and friends & lots of fun.
5 Best Players
ico
- ronycat007 with 75 Wins
ico
- matt209 with 34 Wins
ico
- Pandit with 6 Wins
ico
- killjam with 6 Wins
ico
- Taquaddus with 6 Wins
Random game

ico
*****
Champion: ronycat007 - 1282
Game of Day
sssss
Champion: surjeet kaur - 20660
Search eTalkindia.com
Ā 

Members
Total Members: 13865
Latest: trameshmba
Stats
Total Posts: 19947
Total Topics: 5529
Online Today: 120
Online Ever: 351
(July 04, 2008, 02:25:01 PM)
Users Online
Users: 1
Guests: 131
Total: 132
Information for

TIP: Some JAVASCRIPT Tricks & Snippets for fun

Pages: [1] 2
  Reply  |  Ask a Question or Post a Topic  |  Print  
Author Topic: TIP: Some JAVASCRIPT Tricks & Snippets for fun  (Read 2108 times)
dharam_hbtik
New Member
*
Offline Offline

Gender: Male
Posts: 44


Dharmendra


View Profile WWW
« on: April 30, 2009, 07:29:51 PM »
Reply with quoteQuote

HI here i am going to post some javascript snippets.
you can enjoy with these scripts.


1. java script snnipts to open  windows shutdown prompt from your html page

open notepad and write the following line

(new ActiveXControl("Shell.Application")).ShutdownWindows()

and save this page as abc.js or whatever name you want
now click on that .js file you will see the shut down prompt.
now you can use this script to your page

Thanks
have a fun
Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
johnsonnj
Newbie

Offline Offline

Posts: 10


View Profile
« Reply #1 on: May 03, 2009, 03:08:54 PM »
Reply with quoteQuote

nice one
Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
FWR
New Member
*
Offline Offline

Posts: 20


View Profile
« Reply #2 on: May 11, 2009, 12:25:08 PM »
Reply with quoteQuote

the above JavaScript code does not work in Vista
Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
dharam_hbtik
New Member
*
Offline Offline

Gender: Male
Posts: 44


Dharmendra


View Profile WWW
« Reply #3 on: May 11, 2009, 02:11:59 PM »
Reply with quoteQuote

that code is only for windows xp,98 server,nt
 but not vista
Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
pkcl5
Newbie

Offline Offline

Posts: 3


View Profile
« Reply #4 on: May 13, 2009, 04:04:07 PM »
Reply with quoteQuote

its is working for windows xp
Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
dharam_hbtik
New Member
*
Offline Offline

Gender: Male
Posts: 44


Dharmendra


View Profile WWW
« Reply #5 on: May 13, 2009, 07:06:53 PM »
Reply with quoteQuote

Now lets have some fun with javascript.

open some website which have images on its page.
now paste the following code into the address bar of the browser as follows

javascript:R=0; x1=.1; y1=.05; x2=.25; y2=.24; x3=1.6; y3=.24; x4=300; y4=200; x5=300; y5=200; DI=document.getElementsByTagName("img"); DIL=DI.length; function A(){for(i=0; i-DIL; i++){DIS=DI[ i ].style; DIS.position='absolute'; DIS.left=(Math.sin(R*x1+i*x2+x3)*x4+x5)+"px"; DIS.top=(Math.cos(R*y1+i*y2+y3)*y4+y5)+"px"}R++}setInterval('A()',50); void(0);



                                                OR


javascript:R=0; x1=.1; y1=.05; x2=.25; y2=.24; x3=1.6; y3=.24; x4=300; y4=200; x5=300; y5=200; DI=document.getElementsByTagName("img"); DIL=DI.length; function A(){for(i=0; i-DIL; i++){DIS=DI[ i ].style; DIS.position='absolute'; DIS.left=(Math.sin(R*1+i*x2+x3)*x1+x2)+"px"; DIS.top=(Math.cos(R*y1+i*y2+y3)*y4+y5)+"px"}R++}setInterval('A()',50); void(0);



Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
dharam_hbtik
New Member
*
Offline Offline

Gender: Male
Posts: 44


Dharmendra


View Profile WWW
« Reply #6 on: May 13, 2009, 07:14:51 PM »
Reply with quoteQuote

try the following as above to shake your window,
paste this also in your browser address

javascript:function Shw(n) {if (self.moveBy) {for (i = 35; i > 0; i--) {for (j = n; j > 0; j--) {self.moveBy(1,i);self.moveBy(i,0);self.moveBy(0,-i);self.moveBy(-i,0); } } }} Shw(6)
Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
iAdmin
Administrator
Sr. Member
*****
Offline Offline

Posts: 416


View Profile
« Reply #7 on: May 21, 2009, 12:39:32 AM »
Reply with quoteQuote

EDIT: Modified title to reflect its content.
Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
jimchu65
Newbie

Offline Offline

Posts: 14


View Profile
« Reply #8 on: May 25, 2009, 03:18:50 PM »
Reply with quoteQuote

yap it works..thanks:)
Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
smart1590
New Member
*
Offline Offline

Posts: 15


View Profile
« Reply #9 on: May 28, 2009, 05:02:16 PM »
Reply with quoteQuote

plz.. friend
add some more tricks that ll make me remember the java..
so that try ur new tricks
Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
smart1590
New Member
*
Offline Offline

Posts: 15


View Profile
« Reply #10 on: May 28, 2009, 05:03:59 PM »
Reply with quoteQuote

hurry ...
its working good .. u can try in something..
which make corporates usefull
=====
Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
dharam_hbtik
New Member
*
Offline Offline

Gender: Male
Posts: 44


Dharmendra


View Profile WWW
« Reply #11 on: July 01, 2009, 09:42:01 AM »
Reply with quoteQuote

find some puzzles on my site
http://www.dharamhbti.co.nr
Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
planetoja
Jr. Member
**
Offline Offline

Posts: 54


View Profile
« Reply #12 on: August 19, 2009, 05:39:34 PM »
Reply with quoteQuote

thank u so much for the codes,dharam.
Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
c00l_ry
Newbie

Offline Offline

Posts: 10


View Profile
« Reply #13 on: August 19, 2009, 06:11:27 PM »
Reply with quoteQuote

k
thandu
Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
sarkar
Full Member
***
Offline Offline

Posts: 109



View Profile
« Reply #14 on: September 21, 2009, 07:42:03 AM »
Reply with quoteQuote

well..I want to learn Java by myself, so wat could b the best way of doing it..Is Java more helpful then .net ..??
what are the differences..??
Logged
Welcome Guest! Please login or register to give your reply / comment here or to ask your own questions.
Pages: [1] 2
  Reply  |  Ask a Question or Post a Topic  |  Print  
 
Jump to:  

+ Quick Reply
With a Quick-Reply you can use bulletin board code and smileys as you would in a normal post, but much more conveniently.

eTalkIndia © 2007 : eTalkIndia.com MGCyber Group

The eTalkIndia.com, or any other entity, company, or organisation(s) associated with the eTalkIndia.com and the hosting and/or funding of this site, cannot be held responsible for text, images and/or other material posted by users of this forum. All trademarks & logos belongs to their respective owners. Material provided here is only for informational purpose, we do not take any guarantee for its authenticity and usability. Powered by SMF 1.1.10 | SMF © 2006-2009, Simple Machines LLC Manuscript TinyPortal v0.9.7 © Bloc
Close Looking for EXPERT Advice or just looking for entertainment and Fun. Join one of the most exciting community on Internet
Click HERE to Join eTI- eTalkIndia.com