Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Prepopulating Name in Comments section  (Read 14295 times)

0 Members and 1 Guest are viewing this topic.

wbnp

  • Contributor
  • Coppermine novice
  • ***
  • Offline Offline
  • Posts: 37
Prepopulating Name in Comments section
« on: June 03, 2010, 08:36:10 pm »

When guest comments are allowed it appears that the "Name" field in the comments section is prepopulated with "Anon".  However "Anon" does not seem to be a vaild name as you get a pop-up requiring you to enter a different name.

The pop-up states, "Please provide your name for comment".

Since the other fields available for input are blank it is not intitutive that you must enter a name and can't use "Anon".

This happens with Firefox, IE and Safari although interestingly the field IS blank in Google Chrome however you still can't use Anon.  (Chrome Version 5.0.375.55).

Hopefully this ramble is somewhat clear! 
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15764
Re: Prepopulating Name in Comments section
« Reply #1 on: June 03, 2010, 09:08:33 pm »

Maybe it's better to leave that field empty and pre-populate it with the last used name when you have written your first comment (store in cookie).
Logged

wbnp

  • Contributor
  • Coppermine novice
  • ***
  • Offline Offline
  • Posts: 37
Re: Prepopulating Name in Comments section
« Reply #2 on: June 03, 2010, 09:39:30 pm »

I think that is the best (only?) solution Αndré.  (Personally I don't even care if you store the name in a cookie but it is a nice though!)
Logged

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15764
Re: Prepopulating Name in Comments section
« Reply #3 on: June 11, 2010, 03:05:51 pm »

The user name has already been stored in a cookie. We only had a bug pre-populating that value. I fixed the issue in r7676.

I also changed the english default language string to 'Your name'. If you don't want to have that string as name, please copy the whole function theme_html_comments from themes/sample/theme.php to themes/your_theme/theme.php, find
Code: [Select]
$user_name = $lang_display_comments['your_name'];and replace it with
Code: [Select]
$user_name = '';
Logged
Pages: [1]   Go Up
 

Page created in 0.017 seconds with 19 queries.