Skip to content

Alex Rusin Blog

  • BlogExpand
    • AWS
    • Javascript Development
    • Remix
    • PHP MySQL Development
    • Laravel
    • System Administration
    • WordPress Development
    • Magento
    • Uncategorized
  • My Projects
Alex Rusin Blog
  • Laravel | PHP MySQL Development

    API Server Logging with Laravel

    Byalexrusin September 11, 2020September 11, 2020

    When you work with APIs it is usually a good idea to log requests and responses. I already covered how to do logging when you are consuming an API. You can read about it in this post. Here we will cover how to do it when building an API service with Laravel. For example, you…

    Read More API Server Logging with LaravelContinue

  • Laravel | PHP MySQL Development

    Exporting Records with Timezone Adjustments

    Byalexrusin August 27, 2020August 27, 2020

    As a rule, dates in a database are stored in UTC. So, when you export records from database constrained by dates, it is a good idea to use appropriate timezone in export query. You can do it in one of two ways. One way is create incoming dates in user’s timezone, then covert time to…

    Read More Exporting Records with Timezone AdjustmentsContinue

  • PHP MySQL Development

    Retrying and Logging Requests with Guzzle

    Byalexrusin May 10, 2020September 17, 2023

    When consuming 3d party API, you may want to do two things: In this article we will look at how to implement the above features using Guzzle, a popular PHP library for making API calls. Let us scaffold our app composer init composer require guzzlehttp/guzzle:~6.0 composer require monolog/monolog composer require –dev phpunit/phpunit:^8 We will be…

    Read More Retrying and Logging Requests with GuzzleContinue

  • Laravel | PHP MySQL Development

    Stream Files From S3

    Byalexrusin September 20, 2019September 20, 2019

    When using S3 as our external storage, sometimes we have to let users download files from S3. If file is too large, it may not fit in the memory. The solution is to stream file into user’s browser straight from S3. Let’s take a look how to do it with Laravel’s Filesystem. There are 2…

    Read More Stream Files From S3Continue

  • System Administration

    Loading Start Scripts for GitBash on Windows

    Byalexrusin August 31, 2019October 11, 2019

    I use GitBash as my shell on Windows. Below are the scripts I normally load including git ssh agent. Useful git aliases:

    Read More Loading Start Scripts for GitBash on WindowsContinue

  • Uncategorized

    YouTube and Copyright

    Byalexrusin August 11, 2019August 3, 2020

    Отношение YouTube к авторскому праву состоит таким образом, чтобы защитить себя (YouTube) от возможных исков, которые могут подать большие компании. Для YouTube маленький человек в этом отношении не стоит на первом плане. Добросовестное использование YouTube поддерживает принцип добросовестного использования произвений третьиих лиц. Когда в Вашем YouTube влоге используюется произведение третьих лиц, следует придерживаться следующих правил,…

    Read More YouTube and CopyrightContinue

  • Laravel

    WebSocket is closed before the connection is established

    Byalexrusin August 10, 2019August 10, 2019

    I have been using great package by Beyondcode laravel-websockets. Recently I tried to connect to the websocket server in a new application and got the following error “failed: WebSocket is closed before the connection is established”. Strangely enough this error was manifested in Chrome and not in Firefox. After digging a little bit I found…

    Read More WebSocket is closed before the connection is establishedContinue

  • System Administration

    Too Many Redirects

    Byalexrusin June 10, 2019June 10, 2019

    Sometimes your website may be making more redirects than necessary to account for https and stripping or adding trailing slash.

    Read More Too Many RedirectsContinue

  • Laravel | PHP MySQL Development

    Testing API Clients

    Byalexrusin June 9, 2019June 9, 2019

    Since an API client is a boundary between your code and the outside world you should write as little code as possible to implement it. The client should strictly do its job by sending a request and returning a response. That is why we don’t really test the clients themselves but rather the code that processes the response from the client.

    Read More Testing API ClientsContinue

  • System Administration

    Block IP Addresses in .htaccess behind Load Balancer

    Byalexrusin June 6, 2019June 8, 2019

    Sometimes you need to block access from certain IP addresses to your web site. It is easy to do in .htaccess file if you are running Apache. What if your server is behind a load balancer ? The code below lets you block IP addresses when your server is behind AWS load balancer.

    Read More Block IP Addresses in .htaccess behind Load BalancerContinue

Page navigation

Previous PagePrevious 1 … 5 6 7 8 9 … 13 Next PageNext

© 2025 Alex Rusin Blog - WordPress Theme by Kadence WP

  • Blog
    • AWS
    • Javascript Development
    • Remix
    • PHP MySQL Development
    • Laravel
    • System Administration
    • WordPress Development
    • Magento
    • Uncategorized
  • My Projects