"> What will be the output of the following PHP code?<?php

Home » PHP » PHP Functions » Question
  1. What will be the output of the following PHP code?
    <?php 
    $string = addslashes('how are "you" doing?');
    echo $string;
    ?>
    1. how are "you" doing?
    2. how are you doing?
    3. how are \"you\" doing?
    4. Error
    5. None of these
Correct Option: C

The addslashes() function returns a string with backslashes in front of predefined characters.



Your comments will be displayed only after manual approval.