• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Naming policy

 
Vladan Radovanovic
Ranch Hand
Posts: 216
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello, I visit this forum quite frequently and so often see people not registering acording to naming policy. Instead of posting follow up messages and reminding them to register, wouldn't be easier just to write some client side ( or server side if You prefer) validation using javascript that is going to inforce: User Name (first name, space and last name) ???
Vladan
 
paul wheaton
Trailboss
Pie
Posts: 21187
Firefox Browser IntelliJ IDE Java
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The software we use is not written by us. It's a commercial package. We have already done many hacks, but that is one that looks pretty dangerous.
 
Sean MacLean
author
Ranch Hand
Posts: 621
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Paul,
I've thought of this too and also I realize that you don't want to hack the software (and the you may be upgrading anyway) but I just looked at the registration source for the html and it seems to me that you could put a simple javascript validation in there that would (at least) act as a first line of defence. I've written such a thing if you want to try it out. Just let me know and I email you the revised page.
Sean
 
Thomas Paul
mister krabs
Ranch Hand
Posts: 13974
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sean, if you'll notice, the registration page is actually generated by a perl program. Someone would have to hack the perl program to add the JavaScript to the generated code.
 
paul wheaton
Trailboss
Pie
Posts: 21187
Firefox Browser IntelliJ IDE Java
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sean,
How much do you know about perl?
 
Sean MacLean
author
Ranch Hand
Posts: 621
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm fine with Perl. As well, adding a bit more html to the perl code is not a problem - this used to be the meat and potatoes of our web appications. If there's something you want to try, just email me directly and we can see what's up. Just so you know, I'm an application developer for big horkin' web sites .
Sean
 
Thomas Paul
mister krabs
Ranch Hand
Posts: 13974
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The problem is that we would be hacking UBB's code so that when an update to the code came along, the hack would be lost.
 
Sean MacLean
author
Ranch Hand
Posts: 621
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well, I've never seen the UUB code but they have to be either reading in a template file that contains the html or they've hard coded the html throughout the Perl. Either way, you simply find the point at which the cgi calls
print "<HEAD>";
print "</HEAD>;
or (if they are using an html template just edit that like regular html).
then between these two lines paste in
< script>
function check()
...
< /script>
Find the form element tag and add the onSubmit bit.
< FORM ACTION=" ..... onSubmit="return check();">
That's it. It would take about 5 minutes. There's no risk as long as you back up the original especially since you're not changing any of the perl code logic - just what it prints to the browser. In the old days our interface guys used to tweak their html directly in the Perl (gulp) which is particularly easy since Perl isn't compiled. Of course, we've developed well beyond the good ol' days now the we develop in Java and VB mostly. Anyway, it's not my place to say what's what with regard to the Ranch...

Sean
I edited this to show the HTML and remove the Javascript error, Carl
[This message has been edited by Carl Trusiak (edited February 05, 2001).]
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic