Пример #1
0
 protected function check_length($data)
 {
     if (!empty($data['message'])) {
         if (trim(strlen($data['message'])) > 250) {
             $this->error['message'] = "Please enter only 250 characters.";
         }
     }
     $errors = array_filter($this->error);
     if (empty($errors) === true) {
         $to = "*****@*****.**";
         $subject = 'HireUs';
         $message = "Name: " . $data['name'] . "<br/>" . "Subject: " . $data['subject'] . "<br/>" . "Email: " . $data['email'] . "<br/>" . "Message: " . $data['message'] . "\r\n";
         $headers = 'From: ' . $data['email'] . "\r\n" . 'MIME-Version: 1.0' . "\r\n" . 'Content-type: text/html; charset=iso-8859-1' . "\r\n";
         $mail_sent = mail($to, $subject, $message, $headers);
         $insertQuery = new GetGalleryData();
         $result = $insertQuery->insert($data['name'], $data['email'], $data['subject'], $data['message']);
         $this->success = $result;
     }
 }
Пример #2
0
                        <li class="header-link"><a href="index.php#ourwork">OUR WORK</a></li>
                        <li class="header-link"><a href="index.php#process">OUR PROCESS</a></li>
                        <li class="header-link"><a href="index.php#hire-us">GET IN TOUCH</a></li>
    	     		  	</ul>
    	     		</div>
          </div>    
	     	</div>
	    </div>
      <div id="noscript">
          <div class="noscript-content">
                <noscript><div class="grid_12 noscript-message">Fullstack works best with java script enabled</div></noscript>
            </div>    
       </div>
       <?php 
include_once 'GetGalleryData.php';
$project = new GetGalleryData();
$getData = $project->selectProjectData(urldecode($_REQUEST['p']));
if (!empty($getData)) {
    ?>
          <div class="container_12" id="breadcrumb">
            <div class="grid_12 breadcrumb">
               <span id="main-content" class="bc-content"><a href="index.php#ourwork">Our work</a></span>
               <span class="bc-content">&gt;</span>
               <span id="sub-content" class="bc-content"><?php 
    echo $_REQUEST['p'];
    ?>
</span>
            </div>
        </div>
      <?php 
}
Пример #3
0
<?php

header("Content-Type: application/json");
require_once 'dbconfig.php';
require_once 'GetGalleryData.php';
if (isset($_GET['getData'])) {
    $object = new GetGalleryData();
    $ourWorkData = $object->GalleryData();
    $i = 0;
    $jsonData = '{';
    if (!empty($ourWorkData)) {
        foreach ($ourWorkData as $row) {
            $i++;
            $tag = $row['tag'];
            $projectName = $row['projectname'];
            $jsonData .= '"ourwork' . $i . '":{"tag":"' . $tag . '","projectname": "' . $projectName . '"},';
        }
        $jsonData = chop($jsonData, ",");
        $jsonData .= '}';
        echo $jsonData;
    }
}