Hello guys,

I am here to ask for help, which it is a very problematic (for me) question:
I went to the phalconPHP references and put it inside the controller (I don't know if I had to create a new controller or not, maybe yes) but I put it inside of IndexController.php. and here it is the code of that page:

    <?php

        use \Phalcon\Mvc\Controller;
        use Phalcon\Translate\Adapter\NativeArray;

        class IndexController extends Controller
        {

            public $testing;
            public $url;

            protected function getTranslation()
            {
                 // Ask browser what is the best language
                 $language = $this->request->getBestLanguage();

                 $translationFile = "app/messages/" . $language . ".php";

                 // Check if we have a translation file for that lang
                 if (file_exists($translationFile)) {
                         require $translationFile;
                 } else {
                         // Fallback to some default
                         require "app/messages/en.php";
                 }

                 // Return a translation object
                 return new NativeArray(
                         [
                                 "content" => $messages,
                         ]
                 );
            }

            public function indexAction()
            {
                $this->view->get_title = $this->get_title();
                $this->view->t = $this->getTranslation();
            }

            public function get_title()
            {
                return "DaizGroup - Only for you with great stuff";
            }
        }

?>

Now I will post the index.volt (views/index/index.volt for the main content of the page (the menu I am using bootstrap so i put it in other page views/index.volt).
Here it is the code of th views/index/index.volt page:

<div class="introduction-section" id="page-top">
  <h1><span class="glyphicon glyphicon-shopping-cart"></span>{{ t._('Do-you-like-shop-a-lot')  }}?</h1>
  <br clear="all">
  <ul class="explore btn-explore">
    <li><a href="/shop">{{  t._('Shop-Now') }}</a></li>
  </ul>
</div>
<div class="about-section" id="about">
  <h1>{{ t._('About') }}</h1>
  <br clear="all">
  <p>{{ t._('AboutDesc')  }}</p>
  <br clear="all">
  <br clear="all">
  <blockquote>{{  t._('blockquote')  }}</blockquote>
</div>
<div class="partners-section" id="partners">
  <h1>Partners</h1>
  <br clear="all">
  <p>Still looking for partners :(</p>
</div>
<div class="services-section" id="services">
  <h1>Services</h1>
  <br clear="all">
  <br clear="all">
  <br clear="all">
  <div class="shop-cart-service">
    <figure>
      <img src="img/shop-cart.png" width="35%" />
      <h1>Online Shopping</h1>
      <figcaption>A easy way to shop with a better UI/UX for our clients</figcaption>
    </figure>
  </div>
  <div class="daizpay-service">
    <figure>
      <img src="img/dayz-pay.png" width="35%" />
      <h1>Daiz Payment's Gateway</h1>
      <figcaption>A better way to do payments through our online shop</figcaption>
    </figure>
  </div>
</div>
<div class="contact-section" id="contact">
  <h1>Contacts</h1>
  <br clear="all">
  <br clear="all">
  <div class="contacts-form">
    <div class="form-message"></div>
    <form action="" method="POST" class="ajax">
      <label for="nome" class="name-label">Name:</label><br clear="all" />
      <input type="text" name="name" id="name" /><br clear="all" />
      <br clear="all" />
      <label for="email" class="email-label">Email:</label><br clear="all" />
      <input type="email" name="email" id="email" /><br clear="all" />
      <br clear="all" />
      <label for="subject">Subject:</label><br clear="all" />
      <input type="text" name="subject" id="subject" /><br clear="all" />
      <br clear="all" />
      <label for="message">Message:</label><br clear="all" />
      <textarea rows="4" cols="49" name="message" id="message"></textarea><br clear="all" />
      <br clear="all" />
      <input type="submit" value="Send" id="submit" />
      <input type="reset" value="Reset" />
    </form>
  </div>
</div>

Also I created inside the views folder a new folder called messages, where it contains the languages files. I will just put it en.php page file code here (it is all arrays):

<?php

$messages = array(

     "AboutDesc" => "DaizGroup was thought and createad in 30th October 2016 in Braga. The CEO thought about this to give a easy way to people buy with a better gateway security. He thought it wouldn't be worst if our company just do payments of shopping retailing with secure gateways. Also we developed a gateway payment, easy and secure, and it works on this website. Our company sells everything from books to anything of technology. This website is also done with the heart of our own CEO and his team for our clients.",
      "Do-you-shop-a-lot" = "Do you shop a lot",
      "Shop-Now" => "Shop Now",
      "About-Us" => "About Us",
      "Partners" => "Partners",
      "Services" => "Services",
      "blockquote" => "Will not be possible if you don't have determination, passion, warrior spirit and never give up. Follow your dreams and wait for the right moment.",
      "SadPartners" => "Still looking for partners",
      "OnlineShopping" => "Online Shopping",
      "DaizGateway" => "Daiz Payment's Gateway",
      "OnlineShoppingDesc" => "A easy way to shop with a better UI/UX for our clients",
      "DaizGatewayDesc" => "A better way to do payments through our online shop",
      "Name" => "Name",
      "Email" => "Email",
      "Subject" => "Subject",
      "Message" => "Message",
      "Send" => "Send",
      "Reset" => "Reset",
      "About" => "About"
    );

    ?>

Can you guys help me pls...?

I want to learn programing. How i can I strat it ? Please describe learning step by step.

First you need to start learning the structure of the web programming, starting with HTML and then it comes the rest. But first HTML.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.