Przeglądaj źródła

Fix url poiting from root /

Lucas de Souza 4 lat temu
rodzic
commit
126d372533
3 zmienionych plików z 3 dodań i 3 usunięć
  1. 1 1
      app/create_form.php
  2. 1 1
      explorer/login.php
  3. 1 1
      templates/create_form.html

+ 1 - 1
app/create_form.php

@@ -34,7 +34,7 @@ if (empty($_POST)) {
 
 function generateCreateForm () {
     $template = getTemplate('create_form.html');
-    $context = array('post_url' => htmlspecialchars($_SERVER["PHP_SELF"]));
+    $context = array('post_url' => '../app/create_form.php');
     $template = parseTemplate($template, $context);
     echo $template;
 }

+ 1 - 1
explorer/login.php

@@ -1,7 +1,7 @@
 <?php
 require_once('../templates/templates.php');
 $template = getTemplate('explorer_login.html');
-$context = ['errors' => '','post_url' => htmlspecialchars($_SERVER["PHP_SELF"])];
+$context = ['errors' => '','post_url' => '../explorer/login.php'];
 
 function errorMessage () {
     global $context;

+ 1 - 1
templates/create_form.html

@@ -36,7 +36,7 @@
       <p style="float: right; color: #333; font-weight: 300;">
         Free Education, Private Data (FEPD)
       </p>
-      <img src="/assets/img/logo.png" width="250px" />
+      <img src="../assets/img/logo.png" width="250px" />
       <p style="font-size: 21px; color: #333; font-weight: 300;">
         Plataforma para questionários
       </p>