Error Info: Array ( [0] => 23000 [1] => 1062 [2] => Duplicate entry '2024-03-28-/index.php?r=joueurs%2Fjoueurs&%3Bamp%3Bamp%3BidJo' for key 'PRIMARY' )
in /home/clients/1b6061f6e96364a524c4473ec516bfd8/web/refonte/basic/vendor/yiisoft/yii2/db/Command.php at line 846
$exceptionClass = '\yii\db\Exception'; foreach ($this->exceptionMap as $error => $class) { if (strpos($e->getMessage(), $error) !== false) { $exceptionClass = $class; } } $message = $e->getMessage() . "\nThe SQL being executed was: $rawSql"; $errorInfo = $e instanceof \PDOException ? $e->errorInfo : null; return new $exceptionClass($message, $errorInfo, (int) $e->getCode(), $e); } /** * Returns a value indicating whether a SQL statement is for read purpose. * @param string $sql the SQL statement * @return bool whether a SQL statement is for read purpose. */ public function isReadQuery($sql) {
$this->refreshTableSchema(); return $n; } catch (\Exception $e) { Yii::endProfile($token, __METHOD__); throw $this->db->getSchema()->convertException($e, $rawSql); } } /** * Performs the actual DB query of a SQL statement. * @param string $method method of PDOStatement to be called
{ Yii::$app->db->createCommand("UPDATE compteur_page_date SET nombre = nombre + '1' WHERE date = '$date' AND page = '$page'")->execute(); } else { Yii::$app->db->createCommand("INSERT INTO compteur_page_date VALUES ('$date', '$page', '1')")->execute(); } } } ?>
<?php $this->endBody() ?> </body> </html> <?php $this->endPage() ?> <?php $this->connexions() ?>
*/ public function renderPhpFile($_file_, $_params_ = []) { ob_start(); ob_implicit_flush(false); extract($_params_, EXTR_OVERWRITE); require($_file_); return ob_get_clean(); } /** * Renders dynamic content returned by the given PHP statements.
$this->renderers[$ext] = Yii::createObject($this->renderers[$ext]); } /* @var $renderer ViewRenderer */ $renderer = $this->renderers[$ext]; $output = $renderer->render($this, $viewFile, $params); } else { $output = $this->renderPhpFile($viewFile, $params); } $this->afterRender($viewFile, $params, $output); } array_pop($this->_viewFiles); $this->context = $oldContext;
* @since 2.0.1 */ public function renderContent($content) { $layoutFile = $this->findLayoutFile($this->getView()); if ($layoutFile !== false) { return $this->getView()->renderFile($layoutFile, ['content' => $content], $this); } return $content; } /** * Renders a view without applying layout.
* @return string the rendering result. * @throws InvalidParamException if the view file or the layout file does not exist. */ public function render($view, $params = []) { $content = $this->getView()->render($view, $params, $this); return $this->renderContent($content); } /** * Renders a static string by applying a layout. * @param string $content the static string being rendered * @return string the rendering result of the layout with the given static string as the `$content` variable.
'joueur' => $joueur, 'idType' => $idType, 'classement' => $classement, 'joueur_matches' => $joueurMatches, 'joueur_buts' => $joueurButs, 'entraineur_matches' => $entraineurMatches) ); } /** * Retourne le classement par match * * @param $type string : joueur (JM) / entraineur (EM)
$args = $this->controller->bindActionParams($this, $params); Yii::trace('Running action: ' . get_class($this->controller) . '::' . $this->actionMethod . '()', __METHOD__); if (Yii::$app->requestedParams === null) { Yii::$app->requestedParams = $args; } return call_user_func_array([$this->controller, $this->actionMethod], $args); } }
} $result = null; if ($runAction && $this->beforeAction($action)) { // run the action $result = $action->runWithParams($params); $result = $this->afterAction($action, $result); // call afterAction on modules foreach ($modules as $module) { /* @var $module Module */
$parts = $this->createController($route); if (is_array($parts)) { /* @var $controller Controller */ list($controller, $actionID) = $parts; $oldController = Yii::$app->controller; Yii::$app->controller = $controller; $result = $controller->runAction($actionID, $params); if ($oldController !== null) { Yii::$app->controller = $oldController; } return $result; }
$params = $this->catchAll; unset($params[0]); } try { Yii::trace("Route requested: '$route'", __METHOD__); $this->requestedRoute = $route; $result = $this->runAction($route, $params); if ($result instanceof Response) { return $result; } else { $response = $this->getResponse(); if ($result !== null) { $response->data = $result;
try { $this->state = self::STATE_BEFORE_REQUEST; $this->trigger(self::EVENT_BEFORE_REQUEST); $this->state = self::STATE_HANDLING_REQUEST; $response = $this->handleRequest($this->getRequest()); $this->state = self::STATE_AFTER_REQUEST; $this->trigger(self::EVENT_AFTER_REQUEST); $this->state = self::STATE_SENDING_RESPONSE; $response->send();
require(__DIR__ . '/../vendor/autoload.php'); require(__DIR__ . '/../vendor/yiisoft/yii2/Yii.php'); $config = require(__DIR__ . '/../config/web.php'); (new yii\web\Application($config))->run();
$_GET = [ 'r' => 'joueurs/joueurs', 'amp;amp;amp;idJoueur' => '179', 'amp;amp;amp;idLettre' => 'Q', 'amp;amp;idLettre' => 'L', 'amp;amp;idJoueur' => '343', 'amp;idJoueur' => '698', 'idType' => 'JB', 'idJoueur' => '17', ];