PHPee.com PHP development forum
Can we hide the javascript code in view source?

 
Post new topic   Reply to topic    phpee.com Forum Index -> Phlogger3 feature requests
View previous topic :: View next topic  
Author Message
Jaguar



Joined: 16 Apr 2004
Posts: 10
Location: New York, USA

PostPosted: Thu Nov 25, 2004 2:07 am    Post subject: Can we hide the javascript code in view source? Reply with quote
t Question

There has been a discussion among some fellow webmasters in reference to counters on web pages. It seems that the major Link List sites have banned the use of all counters and pages or web sites submitted to them for listing. This is most often done by checking page source for the javascript code.

Question is there a way to hide the code we use on each page of a web script that we want counted so that it does not show in page view source?

Could we call the important part to the page with php include and if so how would the php script to accomplish this look.

I have found this to be by far and away the best counter with the kind of information I want to see at my finger tips.
I currently have it installed on 25 of my web sites. I have been using the Pphlogger 2.2.5 since the end of April.

The question about hiding the javascript code came up because one of the webmasters had his domain banned for using a third party counter called webstats.

It seems that the explanation from the webmaster of the LL was that to many webmasters were planting dialers and other items in a surfers computer. So they are banning any and all counters.

This can only be known by viewing the page source, so can we hide it and still have the counter work?

I would appreciated any idea's put forth. One the webmasters came up with a script that could be use to call the code to the page. Question is will it work and will the javscript show in view source of the page or will it be hidden?
Back to top
View user's profile Send private message Visit poster's website
jman



Joined: 06 Jan 2005
Posts: 15
Location: USA

PostPosted: Mon Jan 10, 2005 9:54 pm    Post subject: May be easy Reply with quote
It may be really easy to hide the counter from automated scripts since they must look for some exact phrase that identifies the Javascript as counter code. Solution: change the code a bit:
Remove comments
Change variable names
Consider renaming your PPHlogger folders

This should sufficiently confuse automated counter detectors unless they are looking for ANY Javascript, which would be ridiculous.

- Josh
Back to top
View user's profile Send private message Visit poster's website
Jaguar



Joined: 16 Apr 2004
Posts: 10
Location: New York, USA

PostPosted: Tue Jan 11, 2005 6:27 pm    Post subject: Can we hide the javascript code Reply with quote
Thanks for the comments on this subject, but what I believe the problem is the LL and TGP owners want to ban any javascript as they fear that it could be code that can cause damage or infect a viewers computer.
Back to top
View user's profile Send private message Visit poster's website
lionel
Moderator


Joined: 09 Dec 2003
Posts: 162
Location: Costa Blanca, Spain

PostPosted: Wed Jan 12, 2005 7:19 pm    Post subject: Reply with quote
who are these link list sites?
Back to top
View user's profile Send private message Visit poster's website
Jaguar



Joined: 16 Apr 2004
Posts: 10
Location: New York, USA

PostPosted: Wed Jan 12, 2005 9:06 pm    Post subject: Can we hide the javascript code on a page Reply with quote
Sorry that I did not spell it out but I am referring to Link List sites in the adult category such as Link-O-Rama etc. This also includes the major TGP the Hun.

I have seen one webmaster who has been able to do this with his program but I am not familiar with the one he is using.
Back to top
View user's profile Send private message Visit poster's website
sdjl
Moderator


Joined: 17 Nov 2003
Posts: 1100
Location: London, UK

PostPosted: Wed Jan 12, 2005 11:53 pm    Post subject: Reply with quote
You could always just write yourself a PHP function to check if the current visitor is using a known browser such as IE, Friefox, Opera, Netscape, etc and then only show the JS code if that browser type is matched.

Most TGP and link list sites would probably use a script to do their checking, which would (in theory) result in no browser type showing..

David
_________________
-----
PPHlogger Manual | PM Me
Back to top
View user's profile Send private message Visit poster's website
lionel
Moderator


Joined: 09 Dec 2003
Posts: 162
Location: Costa Blanca, Spain

PostPosted: Thu Jan 13, 2005 7:57 pm    Post subject: Reply with quote
ahh, i see Smile

David's solution sounds the best way Smile
Back to top
View user's profile Send private message Visit poster's website
Post new topic   Reply to topic    phpee.com Forum Index -> Phlogger3 feature requests All times are GMT + 1 Hour
Page 1 of 1

 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB
Theme design based on Team 101 Designs, modified by Philip Iezzi