Skip to content

u/JonODonovan

In this archive from Jun 2015 to Nov 2026

10
posts
199
comments
1
media
708
score
2 saved before deletion

How would you approach taking a string of text and grading it based on pre-defined rules/best practices?

Hello, I'm thinking maybe regex is the right answer. Compare the string to multiple regex checks for length, specific words, and characters, and if it passes a check give a "point" then return the total score back to the submitter. Not looking to validate to ensure completeness, like required|size,...

1 points2 comments
Open on Reddit

JSON data, string vs number

If I'm getting this JSON response "list": [ { "dt": 4, "dt_txt": "2018-12-29 00:00:00" }, etc. ] Why does $response = json_decode(file_get_contents($url)); foreach ($response->list as $forecastday) { $bot->reply($forecastday->dt_txt); } work but $response = json_decode(file_get_contents($url));

5 points7 comments
Open on Reddit

Migrating a site to a Laravel code base

If anyone has been down this path, I'm curious what you did and how was the outcome. For example, say you have a static site or say a Wordpress blog with multiple pages and you wanted to restructure/optimize some during the migration. Would it be best practice to create routes for each of the old si...

4 points7 comments
Open on Reddit

Character Design Guidelines

Hey all, please let me know if there is a better sub to ask this in. I do corporate design work and everything has a branding guideline, is there a such thing for cartoon character art? For example, I want to draw a character that I will use in different positions or scenarios. Is there a technique...

2 points2 comments
Open on Reddit

End of this list.

Back to top

Keyboard shortcuts

Move and act

jork
Next / previous post or comment
Enteroro
Open the post
f
Open the media viewer
s
Save
h
Hide (the toast has Undo)
Tab
Right after an action: the toast's Undo
x
Collapse the comment
v
Next layout: cards, compact, grid

Go to

/
Search
gthenh
Home
gthena
All
gthens
Subreddits
gthenl
Library
?
This list
Esc
Close a menu or this list

In the viewer

←or→
Previous / next file
↑or↓
Previous / next post
korj
Previous / next post
Space
Play / pause
m
Mute
z
Zoom
s
Save
o
Open the post (on its own page: back to it)
Esc
Close

Keys do nothing while you type in a box.