Lokasyona göre banner ve pop-up
6
●117
- 29-07-2010, 22:39:26Kimlik doğrulama veya yönetimden onay bekliyor.html yeter ama bunun ıcın yabancı ıp adreslerını bılmen lazım bunu java ılede yapabılırsın ama genellikle bunu htacces ile yapıyorlar bir yerde gormusdum ama sımdı hatırlamıyorum istersen bılgısayarımda arasdırma yapabılırım, htacces ıle gelen zıyaretcının ıp adresınden hangı ulke oldugu bulunuyor ve ona gore belirlenen kod calısıyor
- 30-07-2010, 22:29:25kardes yarın sabah bılgısayarımı aratıracagım ısallah unutmam, su anda ıs yerındeyım, sabaha ıletmeye calısırım,
- 30-07-2010, 23:37:09şöyle bişey yazdım ama bakalım ne yapabileceğiz
<? if ($HTTP_ACCEPT_LANGUAGE == tr) { header("Location:index_tr.php"); // } else { header("Location:index_en.php"); //index_en.php dosyasına yönlendiriyor } ?>yada ip adresini dısarıdan alırsak soyle yazmamıs gerekır
$ziyaretci_ip = getenv(REMOTE_ADDR); // ip alalım $ziyaretci_yer = file("http://www.hostip.info/api/get.html?ip=$ziyaretci_ip"); //ip'yi geoip sitesi kullanarak yerini bulalım ve kaynağı aktaralım $ziyaretci_yer = join ("", $ziyaretci_yer); if (eregi ("Turkey", $ziyaretci_yer)) { header ("Location: http://tr.site.com/"); } else { header ("Location: http://en.site.com"); } - 31-07-2010, 00:00:08java ile yazılmıs olanıda burada
<!-- ONE STEP TO INSTALL LANGUAGE: 1. Copy the coding into the HEAD of your HTML document --> <!-- STEP ONE: Paste this code into the HEAD of your HTML document --> <HEAD> <SCRIPT LANGUAGE="JavaScript1.2"> <!-- Begin if (navigator.appName == 'Netscape') var language = navigator.language; else var language = navigator.browserLanguage; /*------------------------------------------------------------- Netscape instructions: In Netscape, find the language you want to redirect by going to Edit Menu --> Preferences... Then click the '+' box next to 'Navigator' and click 'Languages' Click 'Add' then find the languages you want and add them below. --------------------------------------------------------------- Microsoft Internet Explorer instructions: In MSIE, find the language you want to redirect by going to Tools Menu --> Internet Options... Then click the 'Languages' button near the bottom of the page. Click 'Add' then find the languages you want and add them below. -------------------------------------------------------------*/ if (language.indexOf('en') > -1) document.location.href = 'English.html'; else if (language.indexOf('nl') > -1) document.location.href = 'dutch.html'; else if (language.indexOf('fr') > -1) document.location.href = 'french.html'; else if (language.indexOf('de') > -1) document.location.href = 'german.html'; else if (language.indexOf('ja') > -1) document.location.href = 'japanese.html'; else if (language.indexOf('it') > -1) document.location.href = 'italian.html'; else if (language.indexOf('pt') > -1) document.location.href = 'portuguese.html'; else if (language.indexOf('es') > -1) document.location.href = 'Spanish.html'; else if (language.indexOf('sv') > -1) document.location.href = 'swedish.html'; else if (language.indexOf('zh') > -1) document.location.href = 'chinese.html'; else document.location.href = 'English.html'; // End --> </script> <p><center> <font face="arial, helvetica" size="-2">Free JavaScripts provided<br> by <a href="http://javascriptsource.com">The JavaScript Source</a></font> </center><p> <!-- Script Size: 1.95 KB --> - 31-07-2010, 00:04:08sen asp de yapacaksan fazla bılgım yok yanı aslında asp yı unutmus sekıldeyım, istersen tıkandıgın yerde yardımcı olabılırım