LSheNNawY

LSheNNawY

Cairo

Member Since 1 Year Ago

Experience Points 1,730
Experience
Level
Lessons Completed 14
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.

10 Sep
3 months ago

LSheNNawY left a reply on "PUT" Ajax Request 422 Error

Thank you all, I could fix it.

the problem was that I had to set the (ajax method) to POST not PUT and add {{ method_field('PUT') }} to the form.

24 Aug
3 months ago

LSheNNawY left a reply on "PUT" Ajax Request 422 Error

this really what i do

LSheNNawY left a reply on "PUT" Ajax Request 422 Error

it's a standalone file and I force-refreshing the browser.

LSheNNawY left a reply on "PUT" Ajax Request 422 Error

I did but no change

LSheNNawY left a reply on "PUT" Ajax Request 422 Error

I've used serialize() method and not working too.

and this is all info.

General:
Request URL: http://lara-vue-ecom.test/admin/countries/saveCountry
Request Method: PUT
Status Code: 422 Unprocessable Entity
Remote Address: 127.0.0.1:80
Referrer Policy: no-referrer-when-downgrade


Responce Headers:
Cache-Control: no-cache, private
Connection: Keep-Alive
Content-Length: 239
Content-Type: application/json
Date: Fri, 24 Aug 2018 17:19:37 GMT
Keep-Alive: timeout=5, max=100
Server: Apache/2.4.29 (Ubuntu)
Set-Cookie: XSRF-TOKEN=eyJpdiI6Ik1QeFRkcE4zNjE3aUJqN1RITVVWVkE9PSIsInZhbHVlIjoiajM4dWR2bjN0emQ0ckNIY0ZpaEpHRUx3UDMrVElOa2QyQTN0ZEd5NkM0NnNTOGt5SmpObFpyUlVUTlNJZEk1cSIsIm1hYyI6IjkwOTNmNjNmZGJlMzk3MzIxODdjOGViMmE3NzM4MjVlY2Q1Y2E0ZDFiMjNiYjhiYzNjOGRhMDYxODIxNDc5OGEifQ%3D%3D; expires=Fri, 24-Aug-2018 19:19:37 GMT; Max-Age=7200; path=/
Set-Cookie: ecommerce_session=eyJpdiI6Ino2MjZYMUpYaTE3dHlzNGgwQnlDWnc9PSIsInZhbHVlIjoia0lOZW5IXC9TM0lcL3JCWnlnRFdHeUJ4bmo2b2xTNU1pdVFWNFhGMW1aMTJuVURMZmFZQmNBTnpLd2FscTdEZmFEIiwibWFjIjoiNTcxYWFhMWJlZjZhYjc1NTA0Yzk3NzkxY2NhNmIyZmE5ZjRmZDUyODIxMWQ1ODI4YjljMWU0NTM3Y2Y3N2ZlMiJ9; expires=Fri, 24-Aug-2018 19:19:37 GMT; Max-Age=7200; path=/; httponly


Request Headers:
Accept: */*
Accept-Encoding: gzip, deflate
Accept-Language: en-US,en;q=0.9,und;q=0.8,ar;q=0.7
Connection: keep-alive
Content-Length: 771
Content-Type: multipart/form-data; boundary=----WebKitFormBoundarypD8Tw4ZYyrufSHBd
Cookie: remember_admin_59ba36addc2b2f9401580f014c7f58ea4e30989d=eyJpdiI6ImZLMTI1S21ZYTJxd1F0c1owS29DV2c9PSIsInZhbHVlIjoicDhTU3poNkRocTVFaUhqNXFxYzhGTm1RbjYyZzFUdVdyK0Y5NzdidEpcLzdTV0Fzb3VnRTZsTEczZFVVQlNUNmVMamYyTlJncWh1dEV6V3hIaVBpY3FMTUJaS01NRHlQeXY3YU44MUdqcVlNV3JBUDVQWFU3U0N5NVlMb2NHdnhOc0J6ZkpYd2FWbERlRUNqTWoyZytGMG1BK0ZUKzc3U09hcXcyZldta2hyYz0iLCJtYWMiOiIzYjBjOGYyNzUyNzBlNjkyYzg3OTZlZWQ4OGNmZjUxZjJiMWM0NjQwZjJkM2Y4ZDQ4YzlhNmU3NmRmNzMwY2Y5In0%3D; XSRF-TOKEN=eyJpdiI6Im1mVjZwYkNSQXZUeTdyMm0wd0p2SVE9PSIsInZhbHVlIjoiNjc0WHo0ZXIxNGd0dHBvK0d5dlNcL05jZXY5aVVzXC9vKzdrYnZEaktBcnh4b25WZGZzK3hIUlJNOVlhNnpiZmExIiwibWFjIjoiNmNiNTYzNDgwMGI1Y2JiYmMyYTI2MTkwODIzZTgwODFhNTJiMmQ3MmE2OWNkNmZlMjQwMjZmOGJjNTdkZjBhYiJ9; ecommerce_session=eyJpdiI6ImViSFlFQUtuS08wMXlWendmUWYrQ0E9PSIsInZhbHVlIjoiQTJFU0RnVGY2Zml3OVVQamppc25YbXp0OWFiaGUraDRUd2R1WTJnV0hIaFlINFo4Q1dlRDRIaHl3NFBacFFcL1UiLCJtYWMiOiJhMjYxZTBiNmNiMWM5ZmJkMzlmYzVjN2JlNjFiOTVmZDE0NGY4YmRmMGYxMzU5YTZkNjcwZmU3ZDJlMzcxMTU5In0%3D

Host: lara-vue-ecom.test
Origin: http://lara-vue-ecom.test
Referer: http://lara-vue-ecom.test/admin/countries
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/68.0.3440.106 Safari/537.36
X-CSRF-Token: ppFEoEhG5aSCyWN9xjrxzQUEzylhVPoJmkiT3Xoo
X-Requested-With: XMLHttpRequest


Request Payload:
------WebKitFormBoundarypD8Tw4ZYyrufSHBd
Content-Disposition: form-data; name="name_en"

Spain
------WebKitFormBoundarypD8Tw4ZYyrufSHBd
Content-Disposition: form-data; name="name_ar"

اسبانيا
------WebKitFormBoundarypD8Tw4ZYyrufSHBd
Content-Disposition: form-data; name="code"

427
------WebKitFormBoundarypD8Tw4ZYyrufSHBd
Content-Disposition: form-data; name="symbol"

ES
------WebKitFormBoundarypD8Tw4ZYyrufSHBd
Content-Disposition: form-data; name="icon"; filename=""
Content-Type: application/octet-stream


------WebKitFormBoundarypD8Tw4ZYyrufSHBd
Content-Disposition: form-data; name="id"

4
------WebKitFormBoundarypD8Tw4ZYyrufSHBd
Content-Disposition: form-data; name="_method"

PUT
------WebKitFormBoundarypD8Tw4ZYyrufSHBd--

LSheNNawY left a reply on "PUT" Ajax Request 422 Error

Countries request rules method

public function rules()
    {
        return [
            'name_en'   => 'required|regex:/^[a-zA-Z0-9 -]+/|min:3',
            'name_ar'   => 'required|regex:/^[\p{Arabic} -]+/u|min:3',
            'code'      => 'required|regex:/^[+0-9]/',
            'symbol'    => 'required|regex:/[a-zA-Z]+/|min:2',
            'icon'      => 'nullable|mimes:jpeg,jpg,bmp,png',
        ];
    }

LSheNNawY left a reply on "PUT" Ajax Request 422 Error

I'm sorry, it's 422 I've edited it, ajaxUrl and ajaxMethod are just variables for the request url and request method ['put']

LSheNNawY started a new conversation "PUT" Ajax Request 442 Error

I'm working on updating data with file upload using ajax and every time validation error says that all fields are required although the fields are not empty.

this is my js Code:

function save() {
    var data = new FormData(thisEle.closest('form'));
    $.ajax({
        url: ajaxUrl,
        method : ajaxMethod,
        data: data,
        processData: false,
        contentType: false,
    }).done(...).fail(....);
}

16 Apr
7 months ago

LSheNNawY left a reply on Validation Images

Thanks you all, the problem was the spaces and the ico file only worked when i removed image rule @bobbybouwmann from icon attribute

LSheNNawY started a new conversation Validation Images

Hi there, I'm trying to validate two files inputs one for a logo and the other for an icon, 1- added the enctype="multipart/form-data" to the form. 2- validation rules for these inputs are: [ 'logo' => 'image|mimes:jpeg, jpg, bmp, png', 'icon'=> 'image|mimes:ico', ] 3- when I try to upload a logo of the type png, it returns an error says "The Logo must be a file of type: jpeg, jpg, bmp, png." 4- when I try to upload an icon of the type ico it returns error says "The Icon must be an image."

LSheNNawY left a reply on Validation

Thank you all, This worked for me "regex:/^[\p{Arabic}]+/u"

LSheNNawY left a reply on Validation

@aurawindsurfing, thanks for the help but I've tried this before and I always got this error "preg_match(): Compilation failed: PCRE does not support \L, \l, \N{name}, \U, or \u at offset 3"

LSheNNawY started a new conversation Validation

Hi there, how can I validate Arabic alphabets?

08 Mar
9 months ago

LSheNNawY left a reply on Valdiation Errors On Non Existing Inputs

Thank you all, i was confused.

LSheNNawY started a new conversation Valdiation Errors On Non Existing Inputs

hi there, I've created a request to make a custom validation for all forms i need, i made validation rules on all inputs that may exist like, 'name', 'email', 'password'

but when i make validation on a form that only contains an input for email it gives me errors for 'name', 'email', 'password' ,...,etc not only for the email input.

so, what's the problem.

28 Aug
1 year ago

LSheNNawY left a reply on Sentinel And Redirect()->with() Doesn't Display Flash Data

I have this problem too, So, any help ??