Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_TopicIcon
jqgrid
21/08/2014
15:02
Avatar
hindos
Member
Members
Forum Posts: 5
Member Since:
21/08/2014
sp_UserOfflineSmall Offline

hii !!! i using jqgrid  (jqsuitePHP 4.6 ) but nothing appears  what's the problem !! pleaaase help 

grid.php

<?php
require_once 'jq-config.php';
// include the jqGrid Class
require_once ABSPATH."php/jqGrid.php";
// include the driver class
require_once ABSPATH."php/jqGridPdo.php";
// Connection to the server
$dns = 'mysql:host=localhost;dbname=gestion_conges';
$utilisateur = 'root';
$motDePasse = '';
$conn= new PDO( $dns, $utilisateur, $motDePasse );
// MySQL specific command for the charset
// Tell the db that we use utf-8
$conn->query("SET NAMES utf8");
// Create the jqGrid instance
$grid = new jqGridRender($conn);
// Data from this SQL is 1252 encoded, so we need to tell the grid
// Set the SQL Data source
$table = 'personnel';
$grid->SelectCommand ='SELECT * FROM '.$table;
// set the ouput format to XML
$grid->dataType = 'json';
// Let the grid create the model
$grid->setColModel();
// set labels in the header
$grid->setColProperty("nom", array("label"=>"Nom"));
$grid->setColProperty("prenom", array("label"=>"Prenom"));
$grid->setColProperty("date", array("label"=>"Date de naissance"));
$grid->setColProperty("cin", array("label"=>"CIN"));
$grid->setColProperty("type", array("label"=>"Type"));
$grid->setColProperty("num1", array("label"=>"Téléphone(1)"));
$grid->setColProperty("num2", array("label"=>"Téléphone(2)"));
$grid->setColProperty("adresse", array("label"=>"Adresse"));
$grid->setColProperty("matricule", array("label"=>"Matricule"));

$grid->setUrl('grid.php');
// Set some grid options
//$grid->setGridOptions(array("rowNum"=>10,"rowList"=>array(10,20,30),"sortname"=>"CategoryID"));
// Enable toolbar searching
/*$sql = 'SELECT * FROM personnel';
$req = $conn->query($sql);
while($row = $req->fetch()) {
echo $row['nom']."<br/>";
}
$req->closeCursor(); */
$grid->toolbarfilter = true;
$grid->setFilterOptions(array("stringResult"=>true));
// Enjoy
$grid->renderGrid('#grid','#pager',true, null, null, true,true);
$conn = null;
?>

 

grid.html

<?php
require_once 'tabs.php';
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<head>
<title>jqGrid PHP Demo</title>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<link rel="stylesheet" type="text/css" media="screen" href="themes/redmond/jquery-ui-1.8.2.custom.css" />
<link rel="stylesheet" type="text/css" media="screen" href="themes/ui.jqgrid.css" />
<link rel="stylesheet" type="text/css" media="screen" href="themes/ui.multiselect.css" />
<style type="text">
html, body {
margin: 0; /* Remove body margin/padding */
padding: 0;
overflow: hidden; /* Remove scroll bars on browser window */
font-size: 75%;
}
</style>
<script src="js/jquery.js" type="text/javascript"></script>
<script src="js/i18n/grid.locale-en.js" type="text/javascript"></script>
<script type="text/javascript">
$.jgrid.no_legacy_api = true;
$.jgrid.useJSON = true;
</script>
<script src="js/jquery.jqGrid.min.js" type="text/javascript"></script>
<script src="js/jquery-ui-1.8.2.custom.min.js" type="text/javascript"></script>
</head>
<body>
<div>
<?php include ("grid.php");?>
</div>
<br/>
<?php tabs(array("grid.php"));?>
</body>
</html>


 

jqGrid PHP Demo

//

 


?>

21/08/2014
17:02
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Hello,

 

Please post your question here

 

Regards

For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.

22/08/2014
16:09
Avatar
hindos
Member
Members
Forum Posts: 5
Member Since:
21/08/2014
sp_UserOfflineSmall Offline

tony said
Hello,

 

Please post your question here

 

Regards

there is a  problem  of registration!!!!!!!!!!

25/08/2014
18:05
Avatar
tony
Sofia, Bulgaria
Moderator
Members

Moderators
Forum Posts: 7721
Member Since:
30/10/2007
sp_UserOfflineSmall Offline

Hello,

 

Try to clear your browser cache and try to register.

Also in this case we recommend you to use Chrome browser.

Please report this problem to support at trirand dot net.

If you can not register, please send the problem to the above e-mail.

 

Kind Regards

Tony

For professional UI suites for Java Script and PHP visit us at our commercial products site - guriddo.net - by the very same guys that created jqGrid.

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
33 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

OlegK: 1255

markw65: 179

kobruleht: 144

phicarre: 132

YamilBracho: 124

Renso: 118

Member Stats:

Guest Posters: 447

Members: 11373

Moderators: 2

Admins: 1

Forum Stats:

Groups: 1

Forums: 8

Topics: 10592

Posts: 31289

Newest Members:

, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information