Re[2]: [PHP] counting hyperlink clicks in php

2007-02-17 Thread Ed Grigoryan
Hello Brad,

Saturday, February 17, 2007, 4:22:22 PM, you wrote:

 Denis L. Menezes wrote:
 Dear friends.

 I have a site where I have news headers. I wish to count the clicks on the
 news headers so that I can see how many times each of the the news has been
 viewed. This way I can show the most viewed news.

 Can one of you please advise hwo this can be done?

 Thanks
 Denis 

   
 I think the best way to do this would be to set an onClick (Javascript)
 event handler for each of the links, and then use AJAX style stuff to
 send the information to PHP on the server side, then PHP can log the
 link that was clicked, and keep track of the most clicked links.
 -B


Another way to do this is to take the user to a page that would
identify the clicked link (by ID, for example), store the visits data
to a database or a text file and then redirect to the corresponding
news. So, such link might look like this:
a href=http://www.news.com/redirect.php?news_id=150;read news/a

Hope this helps.

Ed

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re[2]: [PHP] How can I know if a browser is cookies enables?

2007-02-05 Thread Ed Grigoryan
Hello tedd,

Monday, February 5, 2007, 7:04:34 PM, you wrote:

 At 11:36 PM -0500 2/4/07, Mauricio Muriel wrote:
Hello.

How can I know if a web browser is cookies enables?

Regards

Mauricio M.

 Give it a glass of milk and watch what happens.

 tedd
 -- 
 ---
 http://sperling.com  http://ancientstones.com  http://earthstones.com

It can also be done with JavaScript. Found an example at:
http://techpatterns.com/downloads/javascript_check_cookies.php

Ed

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] How can I know if a browser is cookies enables?

2007-02-05 Thread Ed Grigoryan
Also try:
http://www.aspfaqs.com/webtech/082400-1.shtml

What would we do without search engines? :))

Ed

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php