Snubby Posted October 21, 2006 Share Posted October 21, 2006 I've got a google add on a page that I use the PHP include function on to include it all over my site, but does that count as a new page impression per page, or is it just one? Link to comment Share on other sites More sharing options...
jhecht Posted October 21, 2006 Share Posted October 21, 2006 Whats a page impression? Link to comment Share on other sites More sharing options...
Snubby Posted October 21, 2006 Author Share Posted October 21, 2006 a unique view. every unique vistor that sees at most one add. Link to comment Share on other sites More sharing options...
jhecht Posted October 22, 2006 Share Posted October 22, 2006 well i would presume since every page has a different file name, that it would be more than one page impression, but hey im not quite sure so..... i dont know does someone who uses Adsense more know about this? Link to comment Share on other sites More sharing options...
zachary Posted October 22, 2006 Share Posted October 22, 2006 Yes it does and i got a fix....Put your adsense code in a text file called "adsense.txt" MAKE SURE ITS SAVED AS .TXT!Now when you want to display the banner you can add this code:include("adsense.txt"); Link to comment Share on other sites More sharing options...
justsomeguy Posted October 23, 2006 Share Posted October 23, 2006 It does count as more then one impression, and you don't need to name the file .txt. You can name it .wtf if you want, the client does not see the extension and PHP doesn't care. The code gets added to the output of the current page, and the client never knows that it came from somewhere else. Link to comment Share on other sites More sharing options...
zachary Posted October 27, 2006 Share Posted October 27, 2006 Well is he using a live include or a regular include? I gave him the code for a live. Link to comment Share on other sites More sharing options...
justsomeguy Posted October 27, 2006 Share Posted October 27, 2006 I've never heard of a "live" vs "regular" include. There is only 1 include statement, and PHP does not check on the file extension when you use it. If PHP finds PHP tags in the file, it will try to execute the code, otherwise it just inserts the text in the file. Regardless of what type of file it is. Link to comment Share on other sites More sharing options...
zachary Posted October 27, 2006 Share Posted October 27, 2006 Its a script... have you ever searched google? Link to comment Share on other sites More sharing options...
justsomeguy Posted October 27, 2006 Share Posted October 27, 2006 Right, I guess I don't really know very much about PHP or programming. Kindly tell me which of these results defines a "live include", and how it's any different then a "regular include":http://www.google.com/search?client=opera&...-8&oe=utf-8Or maybe it is somewhere in the documentation for the include statement:http://www.php.net/manual/en/function.include.phpThe word "live" does not appear in the documentation, so they must be calling it something else. It might be helpful if you can provide examples of a "live" include and a "regular" include.I don't know what you're arguing, this is the example you gave him:include("adsense.txt");And you emphasized that it must be a .txt file. I replied and said that's not true, and for whatever reason you started arguing. I'm not sure what point you're arguing. The only mention of a file extension in the documentation is when discussing whether a file that is included from a remote server will be executed on the remote server or not.You can name your local include files anything you want, and they will all be treated the exact same way. If you are including a remote file, then you need to specify the full URL of the file. If you only specify a filename, it is treated as a local file. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now