Call PHP with $POST

  • Hello guys, my name is Yunus and I'm a backend developer. If you have a problem just drop me a message, but unfortinately I can't understand everything as I'm using google translator and many things gets lost in translation. So there is a language barrier and I'm sorry about this. Be patient and we will find a solution for sure. Thank you in advance.

  • 1. codes in index.php of package

    https://github.com/pagekit/extension-hello/blob/6fd87ba37276cc8d1676f59610d151f3af80a45e/index.php#L39-L43


    2. codes in index.php of package

    https://github.com/pagekit/extension-hello/blob/6fd87ba37276cc8d1676f59610d151f3af80a45e/index.php#L74-L83


    3. new a create controller in package/src/Controller of package HelloController.php

    https://github.com/pagekit/ext…ree/master/src/Controller


    4.codes in HelloController.php of package

    https://github.com/pagekit/extension-hello/blob/6fd87ba37276cc8d1676f59610d151f3af80a45e/src/Controller/HelloController.php#L1-L11


    5.codes in HelloController.php of package

    https://github.com/pagekit/extension-hello/blob/6fd87ba37276cc8d1676f59610d151f3af80a45e/src/Controller/HelloController.php#L12-L15


    output :


    http://www.example.com/admin/hello/admin


    example 2


    Code
    1. /**
    2. * @Route("/example")
    3. */
    4. public function exampleAction(){
    5.     return 'yay';
    6. }

    output:

    http://www.example.com/admin/hello/admin/example

    Hello guys, my name is Yunus and I'm a backend developer. If you have a problem just drop me a message, but unfortinately I can't understand everything as I'm using google translator and many things gets lost in translation. So there is a language barrier and I'm sorry about this. Be patient and we will find a solution for sure. Thank you in advance.

  • Thank you, yns.wtf.

  • Okay one another question Yunus how to call a function declared in controller without leaving the site?


    This simple contact extension we talked about it needs only a function to submit data through mail function of pagekit backend.

    If I understand you right. You want to call function (Example SwiftMail).


    Hello guys, my name is Yunus and I'm a backend developer. If you have a problem just drop me a message, but unfortinately I can't understand everything as I'm using google translator and many things gets lost in translation. So there is a language barrier and I'm sorry about this. Be patient and we will find a solution for sure. Thank you in advance.

  • Well yeah Yunus I want to bind the contact form action to a send mail function. I read through all those files already 5 times they all show how to send a mail through pagekit backend with an template, registration, change password etc etc. Roman's extension has an event listener and works pretty similar as it just notify about new comments in the blog extension.


    well but I don't understand how bixie it did as his construct of framework plus extension is way too complex for a noob like me.

  • Hello guys, my name is Yunus and I'm a backend developer. If you have a problem just drop me a message, but unfortinately I can't understand everything as I'm using google translator and many things gets lost in translation. So there is a language barrier and I'm sorry about this. Be patient and we will find a solution for sure. Thank you in advance.

  • Jeeez Yunus I have no words lad I guess this one will help me very much to finish what I wanted to do. Thank you so much much 🙏🙏🙏


    vimeo link isn't working but I guess I will be able to get through the code and extend my extension with it to get the first working version out. We'll I hope so👍

  • Video link is run at now :D

    Hello guys, my name is Yunus and I'm a backend developer. If you have a problem just drop me a message, but unfortinately I can't understand everything as I'm using google translator and many things gets lost in translation. So there is a language barrier and I'm sorry about this. Be patient and we will find a solution for sure. Thank you in advance.

  • Hello guys, my name is Yunus and I'm a backend developer. If you have a problem just drop me a message, but unfortinately I can't understand everything as I'm using google translator and many things gets lost in translation. So there is a language barrier and I'm sorry about this. Be patient and we will find a solution for sure. Thank you in advance.