• Categories
    • PHP
    • phpMyAdmin
    • PHPMailer
    • FFMpeg
    • PHPEXcel
    • PHPDoc
    • PHPUnit
    • CakePHP
    • CakePHP 2.0
    • Cake PHP 2.1
    • CakePHP Model
    • Facebook PHP SDK
    • composer-php
    • PHP 7
    • PHP GD
    All Categories
  • About

What is the difference between client-side and server-side programming?

javascriptphpclient-sideserver-side


PHP Snippet 1:

<script type="text/javascript">
    var foo = 'bar';
    <?php
        file_put_contents('foo.txt', ' + foo + ');
    ?>

    var baz = <?php echo 42; ?>;
    alert(baz);
</script>

PHP Snippet 2:

<script type="text/javascript">
    var foo = 'bar';

    var baz = 42;
    alert(baz);
</script>

Related Snippets

How to create a video stream from a single dynamic image in PHP

Call to a member function givePermissionTo() on null

Transpose and flatten multiple rows of array data [duplicate]

PHP to search within txt file and echo the whole line

possible options to create pdf file using html elements to generate invoice in php and codeigniter

PHP Deprecated issue when running artisan command

error:14094410:SSL routines:ssl3_read_bytes:sslv3 alert handshake failure

wordpress : How to specify the cause "This site can’t be reached"

Extract string between first whitespace and last whitespace in php

cakephp save drag and drop list order to database

Why do I have invalid argument supply for foreach in Laravel for json response? [duplicate]

How to get array values using foreach in laravel

PDOException: PDO::__construct(): php_network_getaddresses: getaddrinfo failed: no such host known

Is there a way to use Foundry Model for Authentification inside Functional Tests?

Need to display only array value in JSON output

About Contact Privacy policy Terms and conditions