| | |||||
| ||||||||
| Programming PHP, Perl, Ruby on Rails, AJAX, HTML, XHTML, CSS, JavaScript, MySQL and any other coding topics. |
![]() |
| | LinkBack | Thread Tools |
| | THREAD STARTER #1 (permalink) |
| NamePros Regular Join Date: Jul 2004
Posts: 588
![]() ![]() ![]() | Need Help With JS Code I'm looking to create a custom splash page. aka full page ad/interstitial Example of the page I'm trying to create can be find by visiting this site. http://imgchili.com/show/396/396314_691404701.jpg Notice how it was the Continue to Image link when you click it. I'm looking for a way to do that. Spent hours searching google and no luck. Any help is appreciated. |
| | |
| | #2 (permalink) |
| Senior Member Join Date: May 2009 Location: internet@ctivist.com
Posts: 4,790
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() | Not How I would do it..... Basically they have an image that scales to the whole window which is viewable and the actual page is hidden in a div. Once you click the text (not a true link) - it hides the image and the text and makes the invisible div (the actual page) visible.
__________________ A Member of: IdeationTeam.com HowToBeADomainer.com - a Domaining How To AuthorEditor.com |
| | |
| | #5 (permalink) | ||||
| Senior Member Join Date: May 2009 Location: internet@ctivist.com
Posts: 4,790
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() | They have most of their logic here: http://imgchili.com/js/showa.js ????: NamePros.com http://www.namepros.com/programming/728119-need-help-with-javascript-code.html
__________________ A Member of: IdeationTeam.com HowToBeADomainer.com - a Domaining How To AuthorEditor.com | ||||
| | |
| | #7 (permalink) |
| Senior Member Join Date: May 2009 Location: internet@ctivist.com
Posts: 4,790
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() | It really depends on exactly what you want to do. You want a splash page all the time? Only on the first visit? Only on the first visit per page? Only if the visit is to the site directly? If the link is used as an IMG src should it render the JPG ? I would tend to use .htaccess to convert the request into a specific php page and do it all there with PHP and ignore the javascript - use a real link. I'd use the following technique. http://stackoverflow.com/questions/2...get-parameters
__________________ A Member of: IdeationTeam.com HowToBeADomainer.com - a Domaining How To AuthorEditor.com |
| | |
| | THREAD STARTER #8 (permalink) |
| NamePros Regular Join Date: Jul 2004
Posts: 588
![]() ![]() ![]() | What I basically need it to do is display that splash page on the first visit per page. or once per 24 hours. Unfortunately that link you sent me doesn't help me much since I'm not familiar with what to do at all.
Last edited by resellerlogic; 08-24-2011 at 07:17 AM.
|
| | |
| | THREAD STARTER #9 (permalink) |
| NamePros Regular Join Date: Jul 2004
Posts: 588
![]() ![]() ![]() | I'll pay $15 via PP or AP if anyone can get this designed and to me within 24 hours. Need a replica or something similar. http://imagetwist.com/ayajynidpn3o/691404701.jpg.html something like that one would be excellent as well. |
| | |
| | #10 (permalink) |
| Senior Member Join Date: May 2009 Location: internet@ctivist.com
Posts: 4,790
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() | Code: <!DOCTYPE html popUpBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Title Page</title>
<META http-equiv=Content-Type content="text-html; charset=UTF-8">
</head>
<body>
<!--The Popup Box Layout Start -->
<style>
.popupOverlay {
position:absolute; background-color:#000000;
display:none; height:300%;
left:0; top:0;
width:100%; z-index:6;
}
</style>
<div class="popupOverlay" id="popupOverlay" style="display: none; opacity: 0.9; filter:alpha(opacity=90); -moz-opacity:0.9;">
<div style="border: 5px solid #ccc; padding: 20px; z-index: 1000; position: relative; margin:200px auto;display: none; font-size: 18px; width: 300px; height: 130px; text-align: center;opacity: 1; filter:alpha(opacity=100); -moz-opacity:1;background-color: white;" id="popupBox">
<br/>Press Button to Continue<br/>
<a style="font-size: 24px; padding-left: 10px; padding-right: 10px;" class="buttonblue" href="javascript:doClose();">ENTER</a><br/>
<a style="font-size: 12px;" href="JavaScript:location.replace('http://www.fark.com');">fark off</a><br/>
</div>
</div>
<!--The Popup Box Layout End -->
<!--The Popup Box Javascript to show Begin -->
<script>
var showPopup = true;
//If Cookie is set then don't show - remove this line if you always want and just leave at true
if (getCookie("popupOverlay") != null)
{
showPopup = false;
}
var popupOverlay=document.getElementById("popupOverlay");
var popupBox=document.getElementById("popupBox");
if(showPopup==true){
popupBox.style.display="block";
popupOverlay.style.display="block";
}
function doClose(){
popupBox.style.display="none";
popupOverlay.style.display="none";
var exp = new Date();
exp.setTime(exp.getTime() + (1000 * 60 * 60 * 24));
setCookie('popupOverlay','1', exp);
}
function setCookie(name, value, expires) {
document.cookie = name + "=" + escape(value) + "; path=/" + ((expires == null) ? "" : "; expires=" + expires.toGMTString());
}
function getCookie (name) {
var arg = name + "=";
var alen = arg.length;
var clen = document.cookie.length;
var i = 0;
while (i < clen) {
var j = i + alen;
if (document.cookie.substring(i, j) == arg) {
return getCookieVal (j);
}
i = document.cookie.indexOf(" ", i) + 1;
if (i == 0) break;
}
return null;
}
</script>
<!--The Popup Box Javascript to show End -->
<!--Your Normal Page-->
HELLO WORLD!!!<BR />
I am here but hidden until accepted
</body>
</html> ????: NamePros.com http://www.namepros.com/showthread.php?t=728119 ????: NamePros.com http://www.namepros.com/showthread.php?t=728119 This is the last example Shows a Box with a Press Button to continue. It will ONLY show if the Cookie is not set. If you hit CONTINUE then it sets a cookie and you won't be prompted again. Remove the "getCookie" line and it will show ALWAYS - even if you reload. The style is "borrowed" from the last example you show If you have lots of other Javascript going on then you may need to put this in a function and call it from the "window.onload = " piece.You can change the "Fark off" option
__________________ A Member of: IdeationTeam.com HowToBeADomainer.com - a Domaining How To AuthorEditor.com
Last edited by defaultuser; 08-25-2011 at 08:14 AM.
|
| | |
| | #11 (permalink) |
| New Member Join Date: Dec 2010
Posts: 12
![]() | I advise not to do that. It enoys to always get popups with ads on websites.
__________________ Real Estate Spain |
| | |
| | THREAD STARTER #12 (permalink) |
| NamePros Regular Join Date: Jul 2004
Posts: 588
![]() ![]() ![]() | Is there anyway to when you click enter open a new window as well as closing it? Seems to be what they do and many other sites.
__________________ Earn up to $2.20 Per 1000 Image Views at http://www.imagepad.us |
| | |
| | #13 (permalink) | ||||
| Senior Member Join Date: May 2009 Location: internet@ctivist.com
Posts: 4,790
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() |
????: NamePros.com http://www.namepros.com/showthread.php?t=728119 I'm kidding.
__________________ A Member of: IdeationTeam.com HowToBeADomainer.com - a Domaining How To AuthorEditor.com | ||||
| | |
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Empire Technolgy 50% off in stock deicated Servers 50% off VPS Servers | Lowesthost | Web Hosting Offers | 1 | 08-20-2011 02:52 AM |
| TuningTube social network, included brand new Image Gallery and Forum, ORIGINAL CODE! | flash_back | Domains For Sale - Auctions | 4 | 05-21-2011 12:50 PM |
| Help with C# code | Ik | Programming | 0 | 05-11-2011 09:48 AM |
| invitation code TNX.net and 1000 free backlinks | Boer94 | Link Exchange Requests | 0 | 08-31-2008 02:08 AM |