|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
Hey, I have my whole site in iframe. I need a script.
When someone visit my videos section (example) go to votm.htm, can't see whole layout, ony that one page. I need something like 2 seconds redirect after short message to visitor 'you have to visit main site to view this page'. I'm looking for that script from weeks, I remember one site had it (can't find it now), so it's possible ![]() I hope you know what I mean If not you can check my site www.alicia-keys.net/aliciakeys.htm and page without main layout eg. www.alicia-keys.net/votm.htmReally need help with this. Pretty please ![]() much luv |
|
#2
|
|||
|
|||
|
Hey roxana! I don't mean to sound bad..but you haven't looked hard enough. I mean, I sought for five seconds and 20 pages apeared before my eyes with exactly what you need.
Anyway...since I'm a sweet man, here it is... Use the function: setTimeout("document.location.href=..........",<milisecondstowait>); The statements in the first argument will execute once the miliseconds on the second argument have passed. Good Luck Anibal. |
|
#3
|
|||
|
|||
|
Hey, I just don't know what exactly I'm looking for lol
and yes, you are sweet man I know html yes, but java script is black hole for me, so I have no idea what I have to do whit this I will ask google but question - maybe you or anyone can made that kind of script - detect ifame and redirect? *pretty smile here* |
|
#4
|
|||
|
|||
|
hey again
I found two scripts, can U made one from these two? 1st redirect after 2 sec Code:
redirTime = "2000"; redirURL = "aliciakeys.htm"; function redirTimer() { self.setTimeout("self.location.href = redirURL;",redirTime); } 2nd to main page Code:
if (window.location.href
== window.top.location.href) {
window.location.href = 'aliciakeys.htm';
}
I need redirect but after 2 seconds, with message to visitor: 'you have to visit main page' that's all please I'm totally newbie with java script, thats why Im requesting whole code. much luv |
|
#5
|
||||
|
||||
|
Why not implement a little bit of trial and error?
that's how "newbies" progress to become "novice" Rest assured that you do have all the code in front of you... its just a matter of combining the two... both your code snippets are practically one line |
|
#6
|
|||
|
|||
|
I know you know
can you just tell me? that would be nice of you ![]() |
|
#7
|
|||
|
|||
|
grr :|
|
|
#8
|
|||
|
|||
|
Hey...that kind of attitude is not going to get you any friends...I agree with MadCowDzz on the matter. You cannot expect to be given all (you have to work for it). Programming is not about the code itself, it's about ideas!
Anyway I can tell you're desperated, and I have been there so..here's the code. Code:
function redirTimer(){
redirTime = "2000";
redirURL = "aliciakeys.htm";
self.setTimeout("self.location.href = redirURL;",redirTime);
}
you should place the code onLoad in the <body> tag on the main page. Good Luck.. Anibal. |
|
#9
|
|||
|
|||
|
Hey, I'm not looking friends, I found that board and thought you can help me. I know you have big heads and know everything about java and stuff, I just needed help, no lesson. I will not learn java script, I wanted to get script, so I asked for it. I saw that someone has problems to gave it to me, but why? I had to wait almost month to get any help from here. 'Where is the love' ? lol
This is not that script I needed, but really thank you. You see, this one redirecting page when it is in iframe, so its useless ![]() (sorry for my english) thanks again Anibal |
![]() |
| Viewing: Dev Articles Community Forums > Programming > JavaScript Development > Need one script plz |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|