Imamul.Hossain

Experience

460

0 Best Reply Awards

  • Member Since 2 Months Ago
  • 0 Lessons Completed
  • 0 Favorites

9th June, 2017

Imamul.Hossain left a reply on Back Button Problem • 2 weeks ago

@Borisu and @bashy, thank you........

8th June, 2017

Imamul.Hossain started a new conversation Back Button Problem • 2 weeks ago

When I logged out from my dashboard, the page is directed to login page, but problem is that if I press back button of browser, the page again goes to previous page where I was. Is session being destroyed or not? How can I prevent this? ''' public function login() { $adminId = Session::get('adminId'); if (isset($adminId)) { return Redirect::to('dashboard')->send(); } else { return view('admin.login'); }

}

public function logout() { Session::put('adminId', NULL); Session::put('message', "You're successfully logged out now!"); return Redirect::to('admin-login'); } '''

10th May, 2017

Imamul.Hossain left a reply on Date/time Is Not Inserted If I Use Format('Y-m-d H:i:s A') • 1 month ago

Thank you @Snapey and glad to get the answer

9th May, 2017

Imamul.Hossain started a new conversation Bengali Font Problem An Article Is Generated As Pdf • 1 month ago

Which 3rd party library is more effective to generate pdf? I used mpdf in OOP (PHP) and dompdf in laravel. When I use dompdf, I found bengali font problem. '??' is coming...............what can I do now?

6th May, 2017

Imamul.Hossain left a reply on Date/time Is Not Inserted If I Use Format('Y-m-d H:i:s A') • 1 month ago

@Jaytee I know, but I want AM/PM not 24 hour format.

Imamul.Hossain started a new conversation Date/time Is Not Inserted If I Use Format('Y-m-d H:i:s A') • 1 month ago

I used several processes:

  1. Carbon class
  2. dateTime class
  3. date('Y-m-d h:i:s A')

If I use 'A' then problem is found.

Imamul.Hossain left a reply on The Requested URL /public Was Not Found On This Server. • 1 month ago

@Snapey Wow, thank u.......

5th May, 2017

Imamul.Hossain left a reply on The Requested URL /public Was Not Found On This Server. • 1 month ago

@Cronix Yes, I add/ commit them

Imamul.Hossain left a reply on The Requested URL /public Was Not Found On This Server. • 1 month ago

@Snapey, I deleted my project folder, everything was deleted. Later I pull them from git, but .env, vendor folder were not found. that is why i could not run my project. I have created another laravel project and copy everything from my previous project into new project. now it is working. thank you so much..........

But now, when I git push the new project, the .env fill and some other files/folders are not pushed. why? the command line says.....The following paths are ignored by one of your .gitignore files: vendor Use -f if you really want to add them.

give me suggestions..........again thank u

4th May, 2017

Imamul.Hossain left a reply on The Requested URL /public Was Not Found On This Server. • 1 month ago

@Snapey I've installed apache.

Imamul.Hossain left a reply on The Requested URL /public Was Not Found On This Server. • 1 month ago

@Snapey you are so helpful I know. Now tell me how to do this.

Imamul.Hossain started a new conversation The Requested URL /public Was Not Found On This Server. • 1 month ago

When I browse localhost and in my project folder, when I clock on public then bellow message is shown. Why? ''' Not Found

The requested URL /public was not found on this server. '''

24th April, 2017

Imamul.Hossain left a reply on Ajax Table Update Inserts <br> In Database, Why? • 2 months ago

@Snapey, its not working

Imamul.Hossain left a reply on Ajax Table Update Inserts <br> In Database, Why? • 2 months ago

@Snapey , in script: input is like as follows:

<!DOCTYPE html>
<html>
<body onload="loadDoc('','demo')">

<h1>Input</h1>
<input type="text" id="givenInput" onkeyup="loadDoc(this.value,'demo')">
<br><br>
<h1>Output</h1>
<p id="demo"></p>
</body>
</html>

23rd April, 2017

Imamul.Hossain left a reply on Ajax Table Update Inserts <br> In Database, Why? • 2 months ago

@Snapey and @jlrdw , It is not laravel. It is atomic project for searching and editing a table using AJAX. I did not find any error but it inserts in database.

Imamul.Hossain left a reply on Ajax Table Update Inserts <br> In Database, Why? • 2 months ago

My code:

In class:

<?php
namespace App\W3School\SearchStudent;

use PDO;

class Student
{
    public $host = 'localhost';
    public $user = 'root';
    public $pass = '';
    public $db = 'student';
    public $conn = '';
    public $id = '';
    public $name = '';
    public $mobile = '';
    public $email = '';
    public $text = '';
    public $like = '';

    public function __construct()
    {

        try {
            $this->conn = new PDO("mysql:host=$this->host;dbname=$this->db", $this->user, $this->pass);
        } catch (PDOException $e) {
            echo $e->getMessage();
        }
    }

    public function setData($data = '')
    {
        if (array_key_exists('text', $data) and !empty($data)) {
            $this->text = $data['text'];
        }
        if (array_key_exists('id', $data) and !empty($data)) {
            $this->id = $data['id'];
        }
        if (array_key_exists('name', $data) and !empty($data)) {
            $this->name = $data['name'];
        }
        if (array_key_exists('email', $data) and !empty($data)) {
            $this->email = $data['email'];
        }
        if (array_key_exists('mobile', $data) and !empty($data)) {
            $this->mobile = $data['mobile'];
        }
        if (array_key_exists('like', $data) and !empty($data)) {
            $this->like = $data['like'];
        }
    }
 public function update()
    {
        $sql = "UPDATE `student` SET `name`=:name, `email`=:email, `mobile`=:mobile WHERE `id` = :id;";
        $getSql = $this->conn->prepare($sql);
        $result=$getSql->execute(array(
            ":name"=>$this->name,
            ":email"=>$this->email,
            ":mobile"=>$this->mobile,
            ":id"=>$this->id
        ));
        return $result;
    }
$obj = new Student();
$obj->setData($_GET);
if (!isset($_GET['text'])){
    $obj->update();
}

In AJAX:

 function update(id) {
        var name=document.getElementById('name'+id).innerHTML;
        var email=document.getElementById('email'+id).innerHTML;
        var mobile=document.getElementById('mobile'+id).innerHTML;

        searchPage = 'Student.php?id=' + id+'&name='+name+'&email='+email+'&mobile='+mobile;
        xhttp.open('GET', searchPage);
        xhttp.onreadystatechange = function () {
            if (this.readyState == 4 && this.status == 200) {
                document.getElementById("demo").innerHTML = this.responseText;
            }
        };
        xhttp.send();
    }

Imamul.Hossain left a reply on Ajax Table Update Inserts <br> In Database, Why? • 2 months ago

@jlucia I did not do what u r saying.

In class File:

22nd April, 2017

Imamul.Hossain started a new conversation Ajax Table Update Inserts <br> In Database, Why? • 2 months ago

From a Student table, when I click on a field and trying to update that field entry, it inserts '' after new data, why?

17th April, 2017

Imamul.Hossain left a reply on How To Remove Public From Laravel 5.4 • 2 months ago

@jlrdw I visited the link you provided......... and thanks for your courtesy..........

Imamul.Hossain left a reply on How To Remove Public From Laravel 5.4 • 2 months ago

@samalapsy I tried it several times, but no css or js is found.

@Snapey could you show me the proper ways, please please....

Finally, many many thanks to those persons who have come forward to help me......

16th April, 2017

Imamul.Hossain started a new conversation How To Remove Public From Laravel 5.4 • 2 months ago

I'm using laravel 5.4. I want to remove public from url. If I move .htaccess and index.php to root folder, no css or js is found. What can I do now?

Edit Your Profile
Update

Want to change your profile photo? We pull from gravatar.com.