•  · 1 friends

Add new block page people - Block Only Girl

Hello,

How to add a new block on the People page .

As on UNA - Block UNA Team

https://una.io/page/persons-home

image_transcoder.php?o=bx_froala_image&h=1237&dpx=1&t=1555366073


Example  : add a new block Woman only 

Regards

Daniel

  • 145
Replies (13)
  • The illegal way :)

    Make raw block and put a place holder like <!--womenonly--> in that block.

    add some code to page.php to search for only women profiles and format the results.

    before page.php sends the page to browser change your place holder with the code you prepared.





    • Will be great if you can add some visuals, along with what the code would look like and how you'll plum it all up 

      • You can give more details

        • Hi guys,

          find these lines in page.php:
          if ($oPage) {
                $oTemplate->setPageNameIndex (BX_PAGE_DEFAULT);
              $oTemplate->setPageType ($oPage->getType());
             $oTemplate->setPageContent ('page_main_code', $oPage->getCode());}
           else {
           $oTemplate->displayPageNotFound();}

          //add the lines below
          ob_start();    
                $oTemplate->getPageCode();
              $pageinbuffer = ob_get_clean();

          Now $pageinbuffer has all the code to display in the browser and you can do any changes by using php standard string replace functions as well as regex functions.

          When you finish your changes just echo $pageinbuffer to send the page to browser.

          To go through this route you need to be ready to fight and solve with many problems.

          If you need more details my recommendation is to ask for professional help to develop a block from Boonex or AQB Soft. That way you will not expect future problems.

          I am not a professional programmer :(

          • Hello, there is a simpler solution in fact, you can make the fields of the category "sex" clickable by following this tutorial. https://github.com/unaio/una/wiki/Browseable-categories

            image_transcoder.php?o=bx_froala_image&h=1235&dpx=1&t=1555365206

            • Not a link but how Add new block in page the people

              • it may be a beginning

                • Also note that in a few days, AQB Soft  will release a module that can record different searches. You can save a search "woman" and access it in one click.

                  • @Baloo

                    2 answers - No relation to the request

                    • Sorry, I should have looked at the post in full.

                      • Take my money now !!
                        • There is no one who is how to do it!

                          • In my opinion, you will need to request a custom application from a developer to be able to do it. I suppose you would like a display of the opposite sex to the visitor. It would be interesting to have such an application.

                            6
                            4
                            2
                            2
                            Labels:
                            Added:
                            Category: