cyjobes

cyjobes

Member Since 2 Years Ago

Experience Points 450
Experience Level 1

4,550 experience to go until the next level!

In case you were wondering, you earn Laracasts experience when you:

  • Complete a lesson — 100pts
  • Create a forum thread — 50pts
  • Reply to a thread — 10pts
  • Leave a reply that is liked — 50pts
  • Receive a "Best Reply" award — 500pts
Lessons Completed 3
Lessons
Completed
Best Reply Awards 0
Best Reply
Awards
  • start-engines Created with Sketch.

    Start Your Engines

    Earned once you have completed your first Laracasts lesson.

  • first-thousand Created with Sketch.

    First Thousand

    Earned once you have earned your first 1000 experience points.

  • 1-year Created with Sketch.

    One Year Member

    Earned when you have been with Laracasts for 1 year.

  • 2-years Created with Sketch.

    Two Year Member

    Earned when you have been with Laracasts for 2 years.

  • 3-years Created with Sketch.

    Three Year Member

    Earned when you have been with Laracasts for 3 years.

  • 4-years Created with Sketch.

    Four Year Member

    Earned when you have been with Laracasts for 4 years.

  • 5-years Created with Sketch.

    Five Year Member

    Earned when you have been with Laracasts for 5 years.

  • school-session Created with Sketch.

    School In Session

    Earned when at least one Laracasts series has been fully completed.

  • welcome-newcomer Created with Sketch.

    Welcome To The Community

    Earned after your first post on the Laracasts forum.

  • full-time-student Created with Sketch.

    Full Time Learner

    Earned once 100 Laracasts lessons have been completed.

  • pay-it-forward Created with Sketch.

    Pay It Forward

    Earned once you receive your first "Best Reply" award on the Laracasts forum.

  • subscriber-token Created with Sketch.

    Subscriber

    Earned if you are a paying Laracasts subscriber.

  • lifer-token Created with Sketch.

    Lifer

    Earned if you have a lifetime subscription to Laracasts.

  • lara-evanghelist Created with Sketch.

    Laracasts Evangelist

    Earned if you share a link to Laracasts on social media. Please email [email protected] with your username and post URL to be awarded this badge.

  • chatty-cathy Created with Sketch.

    Chatty Cathy

    Earned once you have achieved 500 forum replies.

  • lara-veteran Created with Sketch.

    Laracasts Veteran

    Earned once your experience points passes 100,000.

  • 10k-strong Created with Sketch.

    Ten Thousand Strong

    Earned once your experience points hits 10,000.

  • lara-master Created with Sketch.

    Laracasts Master

    Earned once 1000 Laracasts lessons have been completed.

  • laracasts-tutor Created with Sketch.

    Laracasts Tutor

    Earned once your "Best Reply" award count is 100 or more.

  • laracasts-sensei Created with Sketch.

    Laracasts Sensei

    Earned once your experience points passes 1 million.

  • top-50 Created with Sketch.

    Top 50

    Earned once your experience points ranks in the top 50 of all Laracasts users.

13 Aug
4 days ago

cyjobes left a reply on Working With Dates And DB

Are you saying I should use a datetime format and place the date in like it would be read (08/13/2019)? I've been giving both the fields a string format.

cyjobes left a reply on Working With Dates And DB

Thanks for the laugh and info. Yup, Im that guy in the cartoon. LOL

I see your point about not having both. Ive actually done it with just the timestamp, but there were many times Ive had to look at raw table data, and seeing a readable date in that case was helpful.

cyjobes started a new conversation Working With Dates And DB

I would like to get opinions of the method I have used in the past for dates. In addition I would like thoughts I how I might do this better.

Usually in my DB table I will have to columns for a date. For example, if it is a start date the columns might be start_date (08/13/2019) and start_date_ts (a strtotime timestamp).

The first is for having a readable/displayable date, while the other is used for calculating date using comparisons of greater than, less than or equal on the the timestamped version to get the results I need. This has been my go-to for a long time and works well.

Ive looked at Carbon, but their documentation is not all that great for finding some examples that are more likely to be used than how they display it. At least that is my experience with it so far.

A lot f what I do deals with a start and end dates. Using the timestamps I can do quick calculations to find records with dates that may land on or between a certain date.

Im a lone, self-taught developer, with no one to bounce things off of. Any advice on best practices and how to best use dates would be very much appreciated.

23 Jan
2 years ago

cyjobes left a reply on File Upload/access

@goatshark Thanks for the help. I finally got it.

Changed filesystem.php default to public. Ran the php artisan storage:link and made a few code changes. Now I can access the files.

Still kinda confused on how this is working. Thanks again.

cyjobes left a reply on File Upload/access

Unsure how to place code here to be seen. See http://kopy.io/krZF2

cyjobes left a reply on File Upload/access

@goatshark It is a link created in the view. For example, the path saved to the DB is "/project_assets/4/heave-results.jpg"

Then I use Storage to complete the path Storage::url("app" . $asset->asset_file_path);

The link created from

  • {{ $asset->asset_title }}
  • is

    http://marketing-dashboard.com:8888/storage/app/project_assets/4/heave-results.jpg

    cyjobes started a new conversation File Upload/access

    I'm learning Laravel 5.3 as I work on a project. I am stuck on some things and was hoping for guidance.

    The idea: Each entry is a project. Admin user uploads a file or set of files associated with a project Normal users can click a link from the list of file(s) to download and view

    When I created the upload I used Storage::makeDirectory(PATH_TO_FILE) to create the location for the file and storeAs(PATH, FILENAME) to place the file to that location. The path, in this case is '/project_assets/ID/FILENAME' The file is then saved to '/storage/app/project_assets/ID/FILENAME'

    Now I need to access this file from a page that a normal user can access. However I get an error when I try to do this - NotFoundHttpException in RouteCollection.php line 161:

    As I mentioned above, I am learning as I go, and may have gone about this the wrong way.

    Any guidance is appreciated.

    Thanks, Cy