View our reviews on Hot Scripts You can now obtain our example scripts and/or vote for them at Hotscripts. To visit Hotscripts click here.

Showing posts with label code. Show all posts
Showing posts with label code. Show all posts




These days many folks are using ad blocker programs/plug-ins. I even often use one when editing my own content etc...so, there are good uses for them. None the less sometimes they might cause a problem so here is some code to help you detect the ad-blockers (and notify the end user).

There is no doubt, some ads are just bad for your computer - I have had ads crash my laptop and try to install spyware etc... So really, ad blockers are a necessary evil.

Why do I call them an 'evil'?

I call ad-blocker programs 'evil' because the seriously impact the webmasters of the sites you visit. many of us provide free services and spend much time helping folks out each day. We obtain no paycheck or salary except what we can obtain via advertising. When you stop our ads from being displayed you are helping to put us out of business.

In all fairness, most people have no idea just how bad these programs are to the sites they visit, so you cant really hold it against the folks. I have found that a simple notification might alert the visitor to the situation without being too obnoxious.

Below is some very simple Javascript that will detect if your Google ads have been blocked via some sort of ad blocker. The below code only detects blocked Adsense iframes but could possibly be modified to detect other ad units (or the lack thereof).


<script>
var detect_google_ads = document.getElementById('google_ads_frame1');
if(detect_google_ads == null){

//alert("Please disable your ad blocking software.");
//document.write("Please disable your ad blocking software.");
//location.replace("ad-blocker-notice.html");

}

</script>



More reading on this matter:
http://tropicalpcsolutions.blogspot.com/2010/03/using-ghostery-to-block-internet-ads.html
[Read more ...]

Bookmark / Share:
StumpleUpon Ma.gnolia DiggIt! Del.icio.us Blinklist Yahoo Furl Technorati Simpy Spurl Reddit Google


Do you have a thought about this article? Post a comment and tell us about it!


Our PHP email form ContactMe has been updated to allow for Russian alphabet characters.

Thanks to a note from a Russian user, we have modified the contact form to allow for the usage of Russian language characters. To get this newer version click below:

PHP email form with Russian language support
[Read more ...]

Bookmark / Share:
StumpleUpon Ma.gnolia DiggIt! Del.icio.us Blinklist Yahoo Furl Technorati Simpy Spurl Reddit Google


Do you have a thought about this article? Post a comment and tell us about it!

A few users of our PHP guestbook program have written me in regards to the random number feature and asked that we remove it.

We didn't remove this feature from the main program as we feel it is a good idea overall. We did create a patch file you can use that will eliminate the need to enter the random number. This patch file can be found here:

PHP Guestbook patch file
[Read more ...]

Bookmark / Share:
StumpleUpon Ma.gnolia DiggIt! Del.icio.us Blinklist Yahoo Furl Technorati Simpy Spurl Reddit Google


Do you have a thought about this article? Post a comment and tell us about it!

Today we released our newest version of the customizable guestbook. With this version you can place your guestbook anywhere with just one simple line of code.




There are many customizable features available. You can change the height, width, text size and color, background color etc...For an image of the available options click here.

If you would like to get a custom guestbook for your website or blog just click here!

[Read more ...]

Bookmark / Share:
StumpleUpon Ma.gnolia DiggIt! Del.icio.us Blinklist Yahoo Furl Technorati Simpy Spurl Reddit Google


Do you have a thought about this article? Post a comment and tell us about it!

ProLog: Building Artificial Intelligence

Posted by Anonymous | 11:33 AM | code | 0 comments »

Have you ever wondered if a machine can truly think? Could all those AI movies actually come true? Truth is, the future is probably closer than we think. The concept of artificial intelligence has been around for some time now, but now days, many things that were once considered science fiction are every day reality.


I have recently started looking into programming AI (artificial intelligence). The concept is an interesting one and I would like to know if any of you have worked in this field.

Prolog: Language of AI

For starters I was looking into ProLog as a base language. I have seen some pretty interesting projects built using this language. One of the projects that gets the most airtime is the webbot program. I can't say I am ready to call AI based programs 'prophets' but I do see promise in the technology.

Any interesting ProLog projects that you know about? I would love to ear about them!
[Read more ...]

Bookmark / Share:
StumpleUpon Ma.gnolia DiggIt! Del.icio.us Blinklist Yahoo Furl Technorati Simpy Spurl Reddit Google


Do you have a thought about this article? Post a comment and tell us about it!

A visitor has submitted a fix for the Contact Form. If you host your site on a Windows server you may have trouble with sending mail.


Here is a letter I received from a visitor:


Hi there,
Fyi - I found the fix in the php manual, on a forum:

Under windows there is a bug in php/mail
See here: http://bugs.php.net/bug.php?id=28038
this results in you being unable to send 'From: Full Name '
Workaround is:
Set the following before calling the mail function:

ini_set('sendmail_from', 'me@domain.com');

this has worked for me and I'm now happy! Thanks for looking into it all the
same.

Regards,
Karen


Thanks Karen!

[Read more ...]

Bookmark / Share:
StumpleUpon Ma.gnolia DiggIt! Del.icio.us Blinklist Yahoo Furl Technorati Simpy Spurl Reddit Google


Do you have a thought about this article? Post a comment and tell us about it!