in /var/www/vhosts/batiakdenizdanismanlik.com/httpdocs/vendor/yiisoft/yii2/db/Connection.php at line 579
$token = 'Opening DB connection: ' . $this->dsn; try { Yii::info($token, __METHOD__); Yii::beginProfile($token, __METHOD__); $this->pdo = $this->createPdoInstance(); $this->initConnection(); Yii::endProfile($token, __METHOD__); } catch (\PDOException $e) { Yii::endProfile($token, __METHOD__); throw new Exception($e->getMessage(), $e->errorInfo, (int) $e->getCode(), $e); } } /** * Closes the currently active DB connection. * It does nothing if the connection is already closed. */ public function close() {
* Returns the PDO instance for the currently active master connection. * This method will open the master DB connection and then return [[pdo]]. * @return PDO the PDO instance for the currently active master connection. */ public function getMasterPdo() { $this->open(); return $this->pdo; } /** * Returns the currently active slave connection. * If this method is called the first time, it will try to open a slave connection when [[enableSlaves]] is true.
* is available and `$fallbackToMaster` is false. */ public function getSlavePdo($fallbackToMaster = true) { $db = $this->getSlave(false); if ($db === null) { return $fallbackToMaster ? $this->getMasterPdo() : null; } else { return $db->pdo; } } /**
if ($this->db->getTransaction()) { // master is in a transaction. use the same connection. $forRead = false; } if ($forRead || $forRead === null && $this->db->getSchema()->isReadQuery($sql)) { $pdo = $this->db->getSlavePdo(); } else { $pdo = $this->db->getMasterPdo(); } try { $this->pdoStatement = $pdo->prepare($sql);
Yii::trace('Query result served from cache', 'yii\db\Command::query'); return $result[0]; } } } $this->prepare(true); $token = $rawSql; try { Yii::beginProfile($token, 'yii\db\Command::query'); $this->pdoStatement->execute();
* @return array all rows of the query result. Each array element is an array representing a row of data. * An empty array is returned if the query results in nothing. * @throws Exception execution failed */ public function queryAll($fetchMode = null) { return $this->queryInternal('fetchAll', $fetchMode); } /** * Executes the SQL statement and returns the first row of the result. * This method is best used when only the first row of result is needed for a query. * @param integer $fetchMode the result fetch mode. Please refer to [PHP manual](http://www.php.net/manual/en/function.PDOStatement-setFetchMode.php)
* @param Connection $db the database connection used to generate the SQL statement. * If this parameter is not given, the `db` application component will be used. * @return array the query results. If the query results in nothing, an empty array will be returned. */ public function all($db = null) { $rows = $this->createCommand($db)->queryAll(); return $this->populate($rows); } /** * Converts the raw query results into the format as specified by this query. * This method is internally used to convert the data fetched from database
* @param Connection $db the DB connection used to create the DB command. * If null, the DB connection returned by [[modelClass]] will be used. * @return array|ActiveRecord[] the query results. If the query results in nothing, an empty array will be returned. */ public function all($db = null) { return parent::all($db); } /** * @inheritdoc */ public function prepare($builder)
'error' => [ 'class' => 'yii\web\ErrorAction', ], ]; } public function Queryss($page){ $urun= Sayfa::find()->orderBy(['sira'=>SORT_DESC])->all(); $tercumeler = Tercumeler::find()->all(); $soruCevap = SoruCevap::find()->all(); $galeri = Galeri::find()->all(); $anaSayfa = Bilgi::find()->where(['sayfa'=>$page])->one(); return [$urun,$tercumeler,$soruCevap,$galeri,$anaSayfa];
return [$dilkurslari,$countDilkursu,$anaSayfa]; } public function actionIndex() { $model = new ContactForm(); $query = $this->Queryss('anasayfa'); if ($model->load(Yii::$app->request->post()) && $model->contact(Yii::$app->params['adminEmail'])) { Yii::$app->session->setFlash('contactFormSubmitted'); echo '<script>alert("İsteğiniz Batı Akdeniz Danışmanlığına Ulaşmıştır. Sizinle En Kısa Süre içinde İletişime Geçilecektir.");window.location="http://www.batiakdenizdanismanlik.com"</script>'; // return $this->refresh(); } else { return $this->render('index',[
$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); Yii::$app->controller = $oldController; return $result; } else { $id = $this->getUniqueId(); throw new InvalidRouteException('Unable to resolve the request "' . ($id === '' ? $route : $id . '/' . $route) . '".');
$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();
$_SERVER = [ 'PATH' => '/usr/local/bin:/bin:/usr/bin', 'HTTP_ACCEPT' => '*/*', 'HTTP_HOST' => 'batiakdenizdanismanlik.com', 'HTTP_REFERER' => 'https://www.batiakdenizdanismanlik.com/', 'HTTP_USER_AGENT' => 'claudebot', 'DOCUMENT_ROOT' => '/var/www/vhosts/batiakdenizdanismanlik.com/httpdocs', 'REMOTE_ADDR' => '3.93.59.171', 'REMOTE_PORT' => '35902', 'SERVER_ADDR' => '94.138.202.135', 'SERVER_NAME' => 'batiakdenizdanismanlik.com', 'SERVER_ADMIN' => '', 'SERVER_PORT' => '443', 'REQUEST_SCHEME' => 'https', 'REQUEST_URI' => '/', 'REDIRECT_URL' => '/', 'REDIRECT_REQUEST_METHOD' => 'GET', 'HTTPS' => 'on', 'PERL5LIB' => '/usr/share/awstats/lib:/usr/share/awstats/plugins', 'PASSENGER_COMPILE_NATIVE_SUPPORT_BINARY' => '0', 'PASSENGER_DOWNLOAD_NATIVE_SUPPORT_BINARY' => '0', 'REDIRECT_STATUS' => '200', 'X_SPDY' => 'HTTP2', 'SSL_PROTOCOL' => 'TLSv1.3', 'SSL_CIPHER' => 'TLS_AES_256_GCM_SHA384', 'SSL_CIPHER_USEKEYSIZE' => '256', 'SSL_CIPHER_ALGKEYSIZE' => '256', 'SCRIPT_FILENAME' => '/var/www/vhosts/batiakdenizdanismanlik.com/httpdocs/web/index.php', 'QUERY_STRING' => '', 'SCRIPT_URI' => 'https://batiakdenizdanismanlik.com/', 'SCRIPT_URL' => '/', 'SCRIPT_NAME' => '/web/index.php', 'SERVER_PROTOCOL' => 'HTTP/1.1', 'SERVER_SOFTWARE' => 'LiteSpeed', 'REQUEST_METHOD' => 'GET', 'X-LSCACHE' => 'on', 'PHP_SELF' => '/web/index.php', 'REQUEST_TIME_FLOAT' => 1711637602.067183, 'REQUEST_TIME' => 1711637602, ];