The basic install of uBlogsy V2.1.1 relies on "http://" being stored in the comment 'Website' field. Of course for external links "http://" needs to be at the beginning otherwise it's assumed it's a local link and it won't work.
The problem comes if the user saves their website without "http://" at the front or indeed saves a blank string. The razor scripts in the package will display "website : " in comment listings if the 'Website' field is completely blank and will display a bad link if the 'Website' field is missing the "http://" prefix altogether.
Whether you consider this a bug or not depends on how much you expect the package to work out of the box. I'm quite happy to and in all cases will have to do some customisation so I don't mind dealing with this kind of thing myself.
I wouldn't think that adding business logic rules to the assembly is the answer, but maybe some changes to the razor scripts to deal with these anomalies.
Website "http://" default
The basic install of uBlogsy V2.1.1 relies on "http://" being stored in the comment 'Website' field.
Of course for external links "http://" needs to be at the beginning otherwise it's assumed it's a local link and it won't work.
The problem comes if the user saves their website without "http://" at the front or indeed saves a blank string.
The razor scripts in the package will display "website : " in comment listings if the 'Website' field is completely blank and will display a bad link if the 'Website' field is missing the "http://" prefix altogether.
Whether you consider this a bug or not depends on how much you expect the package to work out of the box.
I'm quite happy to and in all cases will have to do some customisation so I don't mind dealing with this kind of thing myself.
I wouldn't think that adding business logic rules to the assembly is the answer, but maybe some changes to the razor scripts to deal with these anomalies.
Regards,
Matt
I'm not sure what the issue is.
The contact form automatically includes the http when rendering.
Are you saying that people will remove this? In that case, perhaps some client side validation?
Yes, some people might remove it or perhaps a form filling browser plugin.
Client side scripting or handling the various cases in the Razor scripts that output this field is cool.
The latter is what I have done.
Can you show me what you've done?
Sure Anthony,
I amened uBlogsyListComments.cshtml with some code like this:
Basically first check if there's a website entered, if not then leave it.
If there is, make sure it's got the correct http prefixes.
Regards,
Matt
is working on a reply...