PHP code example of netson / l4gettext

1. Go to this page and download the library: Download netson/l4gettext library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

netson / l4gettext example snippets



// app/config/app.php

return array(
        ..
	    'providers' => array(
                ..
                'Netson\L4gettext\L4gettextServiceProvider',
        ),
        ..
);

{{-- TRANSLATORS: the note --}}{{ _('My string.') }}
 
{{ /* TRANSLATORS: the note */ _('My string.') }}


	return array(
		// ...
		'xgettext' => array(
			'binary_path' => "/usr/bin",
			// ...
 $ php composer.phar 
 $ php composer.phar update 
 $ php artisan l4gettext:install 
 app/config/packages/netson/l4gettext/config.php 
 $ php artisan config:publish netson/l4gettext 
 $ php artisan config:publish netson/l4gettext 
$ php artisan l4gettext:list 
$ php artisan l4gettext:compile
$ php artisan l4gettext:extract
 $ php artisan l4gettext:extract --help 
 $ php artisan config:publish netson/l4gettext 
 app/config/packages/netson/l4gettext/config.php