Click here to Skip to main content
15,909,652 members
Home / Discussions / Linux, Apache, MySQL, PHP
   

Linux, Apache, MySQL, PHP

 
QuestionPassword Verify Pin
Valecia_cho30-Mar-18 13:32
Valecia_cho30-Mar-18 13:32 
QuestionHow to call a reply forms using php. Pin
Member 1370467720-Mar-18 20:45
Member 1370467720-Mar-18 20:45 
Questiondynamic question in php and mysql Pin
antonio_dsanchez9-Feb-18 10:24
antonio_dsanchez9-Feb-18 10:24 
QuestionGet the html content from a website using php Pin
Joshin Joy17-Dec-17 20:51
Joshin Joy17-Dec-17 20:51 
AnswerRe: Get the html content from a website using php Pin
Jochen Arndt17-Dec-17 22:38
professionalJochen Arndt17-Dec-17 22:38 
GeneralRe: Get the html content from a website using php Pin
Joshin Joy18-Dec-17 20:15
Joshin Joy18-Dec-17 20:15 
GeneralRe: Get the html content from a website using php Pin
Jochen Arndt18-Dec-17 21:02
professionalJochen Arndt18-Dec-17 21:02 
GeneralRe: Get the html content from a website using php Pin
Member 1387615717-Jun-18 20:01
Member 1387615717-Jun-18 20:01 
Questionfunction to display content with php does not work as intended Pin
CHrispho15-Dec-17 9:46
CHrispho15-Dec-17 9:46 
AnswerRe: function to display content with php does not work as intended Pin
Jochen Arndt17-Dec-17 22:50
professionalJochen Arndt17-Dec-17 22:50 
QuestionChat functionality is not working when SSL is involved Pin
Member 135528281-Dec-17 17:15
Member 135528281-Dec-17 17:15 
AnswerRe: Chat functionality is not working when SSL is involved Pin
jschell5-Dec-17 12:29
jschell5-Dec-17 12:29 
QuestionPHP: using Facebook login SDK returned an error: No URL set! Pin
iucaa19-Nov-17 22:53
iucaa19-Nov-17 22:53 
QuestionPHP Getting Data From Javascript Pin
Valecia_cho23-Oct-17 13:48
Valecia_cho23-Oct-17 13:48 
AnswerRe: PHP Getting Data From Javascript Pin
Richard Deeming24-Oct-17 2:08
mveRichard Deeming24-Oct-17 2:08 
QuestionHow do I Attach acrobat pdf page to email in codeigniter? Pin
Member 1347022217-Oct-17 4:13
Member 1347022217-Oct-17 4:13 
SuggestionRe: TLDR Pin
Richard Deeming17-Oct-17 4:31
mveRichard Deeming17-Oct-17 4:31 
QuestionThinkphp 5.0 query table how the array of how to get rid of a column? And then save it to another table? Pin
micccn13-Oct-17 23:37
micccn13-Oct-17 23:37 
Questionhelp me on my php script Pin
horlartech8-Sep-17 12:03
horlartech8-Sep-17 12:03 
SuggestionRe: help me on my php script Pin
Richard MacCutchan8-Sep-17 19:24
mveRichard MacCutchan8-Sep-17 19:24 
GeneralRe: help me on my php script Pin
horlartech10-Sep-17 2:39
horlartech10-Sep-17 2:39 
GeneralRe: help me on my php script Pin
horlartech10-Sep-17 2:49
horlartech10-Sep-17 2:49 
QuestionRe: help me on my php script Pin
Richard MacCutchan10-Sep-17 4:17
mveRichard MacCutchan10-Sep-17 4:17 
QuestionCall to a member function prepare() on a non-object Pin
Igoussam28-Aug-17 10:56
Igoussam28-Aug-17 10:56 
Hello friends I have a problem I would like to modify an employee but it gives me this error:Fatal error: Call to a member function setcin() on a non-object
I do not understand why. This is my function:
PHP
<pre>public function update(employe $employe){
$this->makes();
$this->st=$this->pdo->prepare("update employe set cin=:cin,nom_em=:nom_em,id_grade=:id_grade,id_affectation=:id_affectation,adress=:adress where id_em=:id_em");
$this->st->bindvalue(':cin',$employe->getcin(),pdo::PARAM_STR);
$this->st->bindvalue(':nom_em',$employe->getnom_em(),pdo::PARAM_STR);
$this->st->bindvalue(':id_grade',$employe->getid_grade(),pdo::PARAM_INT );
$this->st->bindvalue(':id_affectation',$employe->getid_affectation(),pdo::PARAM_INT );
$this->st->bindvalue(':adress',$employe->getadress(),pdo::PARAM_STR);
$exe=$this->st->execute();

}
public function read($id_em){
$this->makes();
$this->st=$this->pdo->prepare("select * from employe where id_em=:id_em");
$this->st->bindvalue(':id_em',$id_em,pdo::PARAM_INT );
$exe=$this->st->execute();
}

And here is the call of the function:
PHP
<pre><?php

include'manager.php';
$manager=new manager();
$co=$manager->read($_POST["id_em"]);
$co->setcin($_POST['cin']);
$co->setnom_em($_POST['nom_em']);
$co->setid_grade($_POST['id_grade']);
$co->setid_affectation($_POST['id_affectation']);
$co->setadress($_POST['adress']);
$manager->update($co);
?>

and thank you
AnswerRe: Call to a member function prepare() on a non-object Pin
Richard MacCutchan28-Aug-17 21:36
mveRichard MacCutchan28-Aug-17 21:36 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.