This topic has 19 replies, 2 voices, and was last updated 9 years by Radu.

  • Author
  • #69099
     jnevent
    Participant

    I would like to disable all the header functions during the time when the user is registering with Facebook for the first time(kleo/kleo-framework/lib/function-facebook-login.php).

    How do I make it so the user cannot click any of the buttons in the header during this time?

    #69112
     Radu
    Moderator

    Hi,

    Use this php snippet, add to wp-admin/wp-content/themes/kleo-child/functions.php

    COPY CODE
    
    /*Hide theme header if the url contains fb=register*/
    $url = $_SERVER["REQUEST_URI"];
    $fromFB = strpos($url, 'fb=registered');
    if($fromFB !== false) {
    ?>
    <style type="text/css">
    #header {display:none !important;}
    </style>
    
    <?php
    }
    /*END theme header if the url contains fb=register**/
    
    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #69116
     jnevent
    Participant

    There is no ‘wp-admin/wp-content’
    Do you mean ‘wp-content/themes’?

    #69117
     Radu
    Moderator

    Yes,

    sorry

    wp-content/themes/kleo-child/functions.php

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #69119
     jnevent
    Participant

    Should that code you gave me be the only code in functions.php or should I copy the functions.php from kleo and put the code at the top?

    #69120
     Radu
    Moderator

    Put that code at the top or bottom

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #69122
     jnevent
    Participant

    I get error when starting the site:

    Fatal error: Cannot redeclare kleo_setup() (previously declared in /home/hpkursen/public_html/wp-content/themes/kleo-child/functions.php:52) in /home/hpkursen/public_html/wp-content/themes/kleo/functions.php on line 49

    #69124
     Radu
    Moderator

    can you provide your functions.php file ?

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #69125
     jnevent
    Participant

    It was on the bottom before, I put it on the top now but it’s still the same error. Here is the file.

    #69126
     jnevent
    Participant

    I renamed it text, but it’s the functions.php

    #69127
     jnevent
    Participant

    I made it .txt

    Attachments:
    You must be logged in to view attached files.
    #69130
     Radu
    Moderator

    Delete the code that i provided you from themes/kleo/functions.php and add the content from attached file functions.php.txt to themes/kleo-child/functions.php

    NOTE : Kleo child theme should be activated.

    If you don’t have the kleo-child theme installed, look in downloaded package from themeforest in directory wordpress for kleo-child.zip, install this theme and activate.

    It should work i tested.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    Attachments:
    You must be logged in to view attached files.
    #69137
     jnevent
    Participant

    I tried it and got the same error. Here is the whole function.php

    I have used kleo-child before so I’m guessing it’s installed and activated.

    Attachments:
    You must be logged in to view attached files.
    #69142
     Radu
    Moderator

    put the snippet that i provided you after the

    COPY CODE
    
    /***************************************************
    :: Load Kleo framework
    ***************************************************/
    
    HERE
    
    
    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #69143
     jnevent
    Participant

    The same error

    Attachments:
    You must be logged in to view attached files.
    #69145
     Radu
    Moderator

    strange, provide ftp to help you

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #69146
     jnevent
    Participant

    Could I not just edit the kleo instead of kleo-child?

    #69147
     Radu
    Moderator

    You can, but is not recommended.

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
    #69149
     jnevent
    Participant

    I did it in the kleo and it’s working now. Can you remove this topic for security purposes because I provided with function file.

    Thank you for you help.

    #69150
     Radu
    Moderator

    You’re welcome,

    It will not delete the topic because someone maybe will look for a similar solution.

    I think you are able to edit your posts and set them as private reply.

    Regards

    Radu

    Hi there!!! Help others from the community and mark any reply as solution if it solved your question. Mark as a solution
Viewing 20 posts - 1 through 20 (of 20 total)

The forum ‘KLEO’ is closed to new topics and replies.

Log in with your credentials

Forgot your details?