jdc1898

jdc1898

Member Since 2 Years Ago

Experience Points 15,230
Experience
Level
Lessons Completed 149
Lessons
Completed
Best Reply Awards 0
Best Answer
Awards
  • Start Your Engines Achievement

    Start Your Engines

    Earned once you have completed your first Laracasts lesson.

  • First Thousand Achievement

    First Thousand

    Earned once you have earned your first 1000 experience points.

  • One Year Member Achievement

    One Year Member

    Earned when you have been with Laracasts for 1 year.

  • Two Year Member Achievement

    Two Year Member

    Earned when you have been with Laracasts for 2 years.

  • Three Year Member Achievement

    Three Year Member

    Earned when you have been with Laracasts for 3 years.

  • Four Year Member Achievement

    Four Year Member

    Earned when you have been with Laracasts for 4 years.

  • Five Year Member Achievement

    Five Year Member

    Earned when you have been with Laracasts for 5 years.

  • School In Session Achievement

    School In Session

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

  • Welcome To The Community Achievement

    Welcome To The Community

    Earned after your first post on the Laracasts forum.

  • Full Time Learner Achievement

    Full Time Learner

    Earned once 100 Laracasts lessons have been completed.

  • Pay It Forward Achievement

    Pay It Forward

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

  • Subscriber Achievement

    Subscriber

    Earned if you are a paying Laracasts subscriber.

  • Lifer Achievement

    Lifer

    Earned if you have a lifetime subscription to Laracasts.

  • Laracasts Evangelist Achievement

    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 Achievement

    Chatty Cathy

    Earned once you have achieved 500 forum replies.

  • Laracasts Veteran Achievement

    Laracasts Veteran

    Earned once your experience points passes 100,000.

  • Ten Thousand Strong Achievement

    Ten Thousand Strong

    Earned once your experience points hits 10,000.

  • Laracasts Master Achievement

    Laracasts Master

    Earned once 1000 Laracasts lessons have been completed.

  • Laracasts Tutor Achievement

    Laracasts Tutor

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

  • Laracasts Sensei Achievement

    Laracasts Sensei

    Earned once your experience points passes 1 million.

  • Top 50 Achievement

    Top 50

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

20 Jun
4 months ago

jdc1898 left a reply on Hypens In DB Data Returning Substrings

@shez1983 You nailed it! Is that something that you just knew or is it documented? Anyway Thank you!

jdc1898 left a reply on Hypens In DB Data Returning Substrings

Good thought but no.

    protected $primaryKey = 'sku';
    public $timestamps = false;
    protected $fillable = [...]

jdc1898 left a reply on Laravel Images Broken When Deployed

Okay. If you have a file that you put in that directory, say sample.jpg, then the image will be available. Example: http://localhost/storage/sample.jpg

jdc1898 left a reply on Laravel Images Broken When Deployed

Did you create a symbolic link by using the php artisan storage:link command?

jdc1898 left a reply on Deploying Laravel Project

Why did you alter your index.php file? Your routes should be in you api.php file.

jdc1898 left a reply on Laravel Images Broken When Deployed

If you put images outside of the public folder then they will not be accessible to visitors.

If you do decide to do this, then any images will need to be streamed to the client by your code and not directly accessible as assets by the browser

jdc1898 started a new conversation Hypens In DB Data Returning Substrings

I have a dataset that stores SKU's in a table (10107686-1282-CS-500) but when I return this column from the database it only returns (10107686) and I can't figure out why. What is odd is that if I dump the returned object, the SKU appear correct.

Example:

    [attributes:protected] => Array
        (
            [sku] => 10107686-1282

the column name is (sku) in the table and I am accessing it by $data->sku

What am I doing wrong here?

14 Jun
5 months ago

jdc1898 left a reply on Problem With Hosting Laravel Project

Is is safe to assume your connections are properly configured in your .env or config/database.php file? Was it working and stopped?

jdc1898 left a reply on Feature Promotion

@mschaelin something like this is exactly what I was looking for. Thank you! Are there any other ones out that to compare?

12 Jun
5 months ago

jdc1898 left a reply on How To Store IMAGES Outside Public Folder

Someone else may can chime in on whether or not that "will" work. It is my understanding that the resources directory is designed for pre-processed files that will be combined. Like JS or CSS.

As @jlrdw mentioned, it is a filesystem so you can probably do whatever you want.

jdc1898 left a reply on How To Calculate The Total Likes Of All Posts Of A User

Sorry didn't see your second example.

Can you post you schema?

jdc1898 left a reply on How To Store IMAGES Outside Public Folder

Public is common and appropriate for non-preprocessed resources.

To access those assets from your bade you simply reference it.

Example: {{ asset('images/1.png') }} is the same as public/images/1.png

11 Jun
5 months ago

jdc1898 left a reply on How To Calculate The Total Likes Of All Posts Of A User

Did you try this?

$post = Post::whereUserId(auth::id())->get('id')->count();

jdc1898 started a new conversation Feature Promotio

Looking for some guidance from the community on the best package or solution to guide new users through particular features of my App. For example, if I release a new feature that allows users to subscribe to my newsletter and it is a new menu item, the next time someone logs into my site, I want to auto expand the menu and night the new feature. Of course a nice little message next to it would appear detailing its purpose. Any subsequent time a user logs in they would not get that message. I would like to gently “remind” them once a month if they aren’t using the feature or otherwise disabled feature notifications. Before jumping into writing something I thought I would get some opinions on what the best direction would be. I know Laravel’s broadcast channels may be an avenue so looking forward to what people do for things like this.

22 Jan
9 months ago

jdc1898 left a reply on Refactoring Code Snippet For Test Suite

Can you use the __construct method and pass your slug?

jdc1898 left a reply on Returning Related Data Values

Did you read through: https://laravel.com/docs/5.5/eloquent-relationships#has-many-through paying attention to the section "Has Many Through"?

I think you should be able to return whatever data you want this way...

return $this->hasManyThrough('App\OrderDetail', 'App\Orders');

19 Oct
1 year ago

jdc1898 left a reply on $.ajax() POST Translating To GET

Are you sure that it is hitting the correct URL? Can you look at your web server log and see it actually going to the expected endpoint?

Meaning does ('bug/report' = '/bug/report')