User Profile

Manish Kumar QnA

Manish Kumar

Programme
  • 0Followers
  • 0Experience
  • 13Questions
  • Manish Kumar QnA

    Manish Kumar started a new conversation What is the difference between PHP vs Python vs Ruby? 1 years ago ago

    I am trying to use this However that gives me error .

  • Manish Kumar QnA

    I am trying to use this However that gives me error .

    ERROR: Cookies are blocked due to unexpected output. For help, please see this documentation or try the support forums.
    I  am  login on my website but unable to login becuase of  this showing error:

    COOKIES ARE BLOCKED 

    I tried login again in other browser ie. Mozilla. but unable to login.

  • Manish Kumar QnA

    I am trying to use this However that gives me error .

    IF you see in example  this sign � is coming with end of the text and I want to remove this sign.

    Example - Лампа в вытяжке на кухне ме�, i.e. only 28 chars.

    I am using substr() function, but its not working.

     

     

  • Manish Kumar QnA

    I am trying to use this However that gives me error .

    I am using strip_tags() function:

    strip_tags($variable_name) ;

    but code is not working.

     

  • Manish Kumar QnA

    I am trying to use this However that gives me error .

     

    How to use substring() function with the_content() in worpress?

    I am using this code;

    <?php echo substr(the_content(), 0, 5) ?>

    but code is not working.

  • Manish Kumar QnA

    Manish Kumar started a new conversation How to upload image in core php? 2 years ago ago

    I am trying to use this However that gives me error .

    Creating an upload script

    There is one global PHP variable called $_FILES. This variable is an associate double dimension array and keeps all the information related to uploaded file. So if the value assigned to the input's name attribute in uploading form was file, then PHP would create following five variables −

    • $_FILES['file']['tmp_name'] − the uploaded file in the temporary directory on the web server.

    • $_FILES['file']['name'] − the actual name of the uploaded file.

    • $_FILES['file']['size'] − the size in bytes of the uploaded file.

    • $_FILES['file']['type'] − the MIME type of the uploaded file.

    • $_FILES['file']['error'] − the error code associated with this file upload.

     

    Example:

    Below example should allow upload images and gives back result as uploaded file information.

    <?php
       if(isset($_FILES['image'])){
          $errors= array();
          $file_name = $_FILES['image']['name'];
          $file_size = $_FILES['image']['size'];
          $file_tmp = $_FILES['image']['tmp_name'];
          $file_type = $_FILES['image']['type'];
          $file_ext=strtolower(end(explode('.',$_FILES['image']['name'])));
          
          $expensions= array("jpeg","jpg","png");
          
          if(in_array($file_ext,$expensions)=== false){
             $errors[]="extension not allowed, please choose a JPEG or PNG file.";
          }
          
          if($file_size > 2097152) {
             $errors[]='File size must be excately 2 MB';
          }
          
          if(empty($errors)==true) {
             move_uploaded_file($file_tmp,"images/".$file_name);
             echo "Success";
          }else{
             print_r($errors);
          }
       }
    ?>
    <html>
       <body>
          
          <form action = "" method = "POST" enctype = "multipart/form-data">
             <input type = "file" name = "image" />
             <input type = "submit"/>
    			
             <ul>
                <li>Sent file: <?php echo $_FILES['image']['name'];  ?>
                <li>File size: <?php echo $_FILES['image']['size'];  ?>
                <li>File type: <?php echo $_FILES['image']['type'] ?>
             </ul>
    			
          </form>
          
       </body>
    </html>
  • Manish Kumar QnA

    Manish Kumar started a new conversation how to upload image in wordpress on localhost? 2 years ago ago

    I am trying to use this However that gives me error .

    Warning: move_uploaded_file(http://localhost/wordpress/wp-content/plugins/coinmen_capital/images/CAPITAL1.jpg): failed to open stream: HTTP wrapper does not support writeable connections in C:\xampp\htdocs\wordpress\wp-content\plugins\coinmen_capital\index.php 

  • Manish Kumar QnA

    Manish Kumar started a new conversation How to change admin _menu_page icon in wordpress? 2 years ago ago

    I am trying to use this However that gives me error .

    How to change admin _menu_page icon in wordpress?

  • Manish Kumar QnA

    I am trying to use this However that gives me error .

    How to insert chinese and japanese  character in mysql table?

  • Manish Kumar QnA

    I am trying to use this However that gives me error .

    This message may not have been sent by: sender@gmail.com
    please provide me solution for above message when i send it through mail() function php from my website.

  • Manish Kumar QnA

    Manish Kumar started a new conversation how to use like operator in codeigniter ? 2 years ago ago

    I am trying to use this However that gives me error .

    how to use like operator in codeigniter ?

  • Manish Kumar QnA

    I am trying to use this However that gives me error .

    How to solve unsupported operand types error in pagination in codeigniter ?

  • Manish Kumar QnA

    I am trying to use this However that gives me error .

    How to solve unsupported operand types error in pagination codeigniter?