×
Login Register an account
Top Submissions Explore Upgoat Search Random Subverse Random Post Colorize! Site Rules
2

Malformed URLs causes posts to die

submitted by bobdole9 to TalkDev 5 monthsNov 17, 2023 14:22:55 ago (+2/-0)     (TalkDev)

Tried to share the link below as is, and when I posted, it disappeared.

fox5atlanta.com/news/south-fulton-police-k-9-killed-friday-morning-in-line-of-duty-by-officer-in-another-department

Did it again adding "https://www." and it was fine.

Is there a way to error check input values before submission...so we may be able to fix the fuckup?


9 comments block


[ - ] lord_nougat 2 points 5 monthsNov 17, 2023 14:47:53 ago (+2/-0)

Yes, there is. It is called 'proofreading'.
Something of a lost art, these days, particularly in the press.

[ - ] bobdole9 [op] 1 point 5 monthsNov 17, 2023 15:01:17 ago (+1/-0)

Where does it say "your link MUST have https://" ?

Checking form submission usability was my job...usually with a Javascript alert of "shit is wrong" after a regex check.

[ - ] bobdole9 [op] 0 points 5 monthsNov 17, 2023 15:02:40 ago (+0/-0)

@system - seems // and " will add a semicolon to the comment after posting.

[ - ] system 0 points 5 monthsNov 17, 2023 15:45:55 ago (+0/-0)*

http or https (..ugh. Hypertext Transfer Protocol) must be included. I added some javascript to check for it. As far the semicolon thing , that will take some time. Gotta rework the parsing functions which is a nightmare for me to get right with everything it checks for.

[ - ] bobdole9 [op] 0 points 5 monthsNov 17, 2023 15:52:10 ago (+0/-0)

From my time of "fuck your semicolons, php", it wouldn't be outside of possibility that once you worked the string, the echo of the final string has an extra ; in the code.

[ - ] bobdole9 [op] 0 points 5 monthsNov 17, 2023 16:04:41 ago (+0/-0)

e or s (..ugh. Hypertext Transfer Protocol) must be included.

Uh, wouldn't it be p or s? As in ht tp or ht tps? May be dumb...not sure where e comes in?

Edit: fucky spaces for text to appear.

[ - ] deleted 0 points 5 monthsNov 17, 2023 16:28:33 ago (+0/-0)

deleted

[ - ] Sector2 0 points 5 monthsNov 17, 2023 15:31:14 ago (+0/-0)

"https://www." doesn't help. Links still get fragmented into a mess. Although they don't seem to destroy your entire comment anymore.

A few months back, links would delete, replace, and scramble other parts of your post.

[ - ] bobdole9 [op] 0 points 5 monthsNov 17, 2023 15:54:48 ago (+0/-0)

Trick I found was from the URL form input on "Share a Link" posting. The one in comments is something else.