Frontend Login

Download from…


Flexible Frontend Login Shortcode Usage Examples

If you want to use these shortcode examples make sure to delete the spaces near opening and closing brackets.

[ flexible-frontend-login vertical=bottom horizontal=left ]
[ flexible-frontend-login vertical=bottom horizontal=right ]
[ flexible-frontend-login vertical=top horizontal=left ]
[ flexible-frontend-login vertical=top horizontal=right ]

Download from…


120 thoughts on “Frontend Login

  1. Hello, I am looking at which template to add the code “” as I need to have the user login before adding images. I am using another plugin to control the public upload action.

    Could you please provide me with more information?


    1. Hi, Lynette
      I am not completely sure what you are planning to achieve. Maybe the best way is to put the template tag into the header.php file.

      Please take a look at the login link at the very top of this page. Is that what you want to have? You would need to place the template tag flexible-frontend-login-modal(); in your header file.
      Let me know if this is answering your question.

      1. Apologies – I did not see this reply before I went off to upgrade and test.

        I added the information to the header as you suggested but I still do not see the ‘popup’ information in the source code. Let me take a look at your example and I come back if I cannot get it to work.

        1. Hi Lynette, the site looks great.

          It seems like you changed the html code for the output of flexible frontend login. Please post it here so that I can take a look at it and I will try to reproduce the error.

          By the way there is a typo on the options page (to be fixed soon): please use %lost_password% instead of %lostpassword%.

          1. Thanks. I fixed the password issue (a typo on the instructions).

            I have an external message description that looks like this:

            And the code in the plugin looks like this:

            You must register with or Click To Login to the website in order to upload images

            if (!is_user_logged_in() && get_option(‘npu_user_role_select’) != 99) {
            $strOutput .= “”;
            if(get_option(‘npu_notlogged’)) {
            $strOutput .= get_option(‘npu_notlogged’);
            } else {
            $strOutput .= “You must be registered and logged in to upload images.”;

          2. It seems we did not get the whole code transmitted…?

            Your function call seems to be ok but I asked you to post the html code that you put into the FFL options page. The bug seems to sit there somehow.

        2. OK, I found the solution!
          You need to play with the z-indexes in the css files.

          So copy the /css/ffl-style.css to a subfolder /flexible-frontend-login/ in your theme directory and make the following changes:

          #ffl-mask {



          #ffl-boxes .ffl-window {


          Your login input fields will be magically available :-)

  2. Also, looking at the setting on the plugin there appears to be no information saved when I update it. The “example screens” that should show what the user is seeing is exactly what I am seeing. A blank box with nothing inside. The “Klick on this link to test your settings.” also does not appear to have any way that one can click on it.

    1. Thank you Lynette, there seems to be some error in saving the settings. I did not have that in previous versions. I need to look into the code and find the bug. I will let you know here, when it is fixed.

  3. I am removing the greater and less-than signs so it does not get transformed:

    td %label_for_username /td
    td %input_username% /td
    td %label_for_password% /td
    td %input_password% /td
    td colspan=”2″ %send_button% /td
    td colspan=”2″ %lost_password% /td

    1. Well, it is intended to be easy to use. But it is my first plugin and you really help me making it better with your feedback. I will try to find solutions which make it more intuitive. Any suggestion is welcome.

  4. Thanks for this great plugin – just what I was looking for.

    I have one issue – it doesn’t work multilingually, in conjunction with language switching plugins such as qTranslate. It works fine in any one language (based on the WPLANG setting in wp-config.php). I wish I could advise on how to get this to work multilingually – the qTranslate forum might help.

      1. Thanks for the quick response Henning. Your plugin works fine monolingually. I’ve made a partial translation (Welsh) which works fine if I set WPLANG to cy_GB. However, I want to use your plugin in a bilingual website, with switching between English and Welsh using the qTranslate plugin. Some plugins cope well in a multilingual environment and others less so, but I’m afraid I don’t know enough about php to advise what needs to be done to get things to work multilingually. The qTranslate forum has useful tips that may mean more to you than me.

        1. It should not be a problem because the plugin is completely prepared for localization. Do you know the open source program poedit? You can use it to create translations from the *.pot file in the translations folder. If so I will send you a private message in order to add your translations to the plugin.

        2. OK, after checking it myself on a site with QTranslate I see what you mean. But it is weird: I tried every single tip on making it work with Qtranslate and still it does not. So I openend a new thread on their support forum to get a hint. As soon as I found the solution I will post it here.

  5. This plugin works great. Except when I logout…I get this error.
    Not Found
    The requested URL /wordpress/wordpress/ was not found on this server.

    Seems like it’s duplicating the wordpress path.
    Is it possible I’m only running into this problem because I’mdoing all this local?


    Seems highly unlikely but I thought I would ask.

  6. I’m testing it now.
    I deactivated it to fix some other things. Now I’m back on it.
    My useage is this:
    My membership site takes over the registration page and has their own. After registration it takes them to a page on my site called Welcome.
    They were not automatically logged in, and I can see some instances why not.
    But I want them to be logged in when they register.
    Because I do not wish to fix this issue every time they upgrade the membership plugin, I’ll wait for them to fix it.
    Until then, I need your plugin to either place a login widget in the sidebar of that page, or have it pop up modal when that page is brought up, which is my preference.
    So, they register and then the screen darkens and they get the login to reveal the welcome page. The rest I have handled. So I’m off to test.
    When I placed the php tag begin and end around your code, it didn’t place the login link.
    Also, I noticed with your latest update today, the plugin out of the box shows a whacky test of the login box, showing code etc. You might have a look at that.

    1. To bring up the modal form on load is a very special task and we would have to determine on which page this should happen. I cannot promise to add this kind of function but I will think about it and see if there is a solution which does not make the usage too complicated.
      I will check the other bugs you mentioned and keep you posted here.

  7. And, good job on your first plugin!
    It has great potential.

    You might explain, like to a 3rd grader, how to place that link on the web page. and where to place that code, unless the plugin is going to do that automatically. I’ve tried all the placement settings and tried placing code in my theme’s settings under header, to no avail.

  8. Thanks for this great plugin! It’s much appreciated and almost exactly what I’m looking for. Rather than displaying a link on which a visitor has to click in order to get the login popup, I’d love to just display the login popup automatically when the webpage is loaded. Is that possible? Thanks in advance for your answer!

    1. Hi Sabrina, thank you for your feedback. I put your suggestion on the todo list for further development and will add an option to choose immediate popup on page load. But did you think of unobtrusive website design? Your visitors might find it somewhat embarrassing if they want to just look at your site and the popup gets in between…?!

      1. Hi,
        On my page the plugin seems to do just that, i.e. pop up immediately. I don’t actually like that. I’m using the sidebar widget. Any thoughts?


  9. Hello,

    I upgraded with the latest version but I am unable to see the options where you can change the custom messages. I am currently working locally.

    Suggestions please?


  10. Hi Henning,

    Thankyou. I found what I was looking for.
    Integration with another plugin caused issues but they now appear to be resolved.


  11. Hello Henning,

    I am trying to get the Login ‘box’ to display and following your previous instructions I am finding a mismatch.

    Your instructions mentioned the following:

    #ffl-boxes .ffl-window {


    However, this no longer exists in the .css file.

    Thanks for your assistance

  12. I’m very sorry… pheraps it must be clear, but how to set control popups in template use?
    $vertical to “bottom” or “top” -
    – is it mean I should write $vertical=”top” or what?

    1. Hi Peter, the full function call should look like this:
      < ?php if ( function_exists( 'flexible_frontend_login' ) ) : flexible_frontend_login( 'bottom', 'left' ); endif; ?>
      Sorry that my explanations did not make that clear enough. I will change them…

  13. I am wondering, if I want to add a “Welcome” before the username, and also just shorten the username to a first name – where would I put this code? I’ve been digging through the files and am stumped. Any help is much appreciated as I really like this plugin and want to continue using it. Thanks!

  14. Hi,

    I have installed your plugin as it was exactly what I was looking for (thanks a lot for your work, it really helps me). I am having version 0.97.5 but I have a 404 error when clicking on “lost pw”.

    Can you help?

    Thanks in advance,


  15. Hello,

    I try to integrate your plug in with shortcode.
    When i try to enter my login & password i am redirecting automatically on my admin login page but it don’t log. i tested many login plug-in, and have the same result each time.

    Do you have an idea why it don’t log ?

    Best regards

    (Sorry for poor english…)

  16. Hi Henning,

    I am an absolute beginner in WordPress (Website)..
    The plugin is great !!!!!
    Just a little question:
    How can I put the plugin directly as a link in a menu .. So not only via the detour of creat a page first?

    Thanks for your help

  17. Hi, I had the plugin working great but at some point a conflict came up.
    The login box is open all the time and if I close it without logging in.
    it won’t open again unless I refresh the page. Any help much appreciated.
    Great plugin.

  18. Henning,

    The plugin works great, but one question:

    If a user logs in incorrectly (for example, puts in the wrong password), it defaults to the wordpress login screen – is this supposed to happen? Is there a way to keep the user on the same login page/area?


    1. This would seriously require more skills than I have. Any help to make this possible is appreciated but I cannot do it on my own since I am a lay coder and do not always have the time to learn the things I’d like to learn ;-(

    1. You might need to exclude the plugin’s javascript from the minify routine of W3 Total Cache. I previously had many difficulties with that plugin and cannot give you another shorthand solution. Maybe one day I understand what W3TC does… :-)

      1. W3TC has baffled me as well. I loaded it and configured with a script provided by host.
        Will try and see if we can make the exclusion and let you know how it works out.
        Thank you again.

  19. Hello,

    in your help documentation there is :

    = How to use the Flexible Frontend Login template tag on your site =
    In template files place:

    To control popups behavior set
    $vertical to “bottom” or “top”
    $horizontal to “left” or “right”
    For popup with overlay use:

    could you tell me in which file I have to put this code ? header ? it doesn’t work …

    Thank you for your answer.


    1. Yes Fab, usually the header.php would be the right place to put it. I am sorry I cannot provide you coding for your theme but I can copy the code from the theme used on this site (WordPress Default Theme Twenty Twelve) – so here it is…
      < ?php if ( function_exists('flexible_frontend_login_modal') ) flexible_frontend_login_modal() ?>

  20. Modal dialog option – the modal overlay appears to be displayed over the top of the dialog – the dialog input boxes are not usable – this is WP 3.5 – also the options page, which I assume is supposed to be tabbed (with vertical tabs) is one big long page and breaks the normal Admin area left side menus totally – any help is appreciated

  21. With wrong credentials I get redirected to wp-login.php That is not nice. Form should handle wrong credentials without redirecting to wp-login.php Otherwise it makes no sense. Also form could have option to stay on current page (is the user is leaving a comment for example) or redirect to dashboard.

    Overall nice plugin.

  22. Hello Henning,

    I am using the Frontend Login to allow users to take a test on my site. I am able to login and take the test. I might be missing a step but when I try to click to log out, a box appears with “You are attempting to log out of career counseling. Do you really want to log out?” The “yes” or “back” click selections are missing. How can I fix that?

  23. hi
    this plugin is awsome, but i want to go further and enter it in “yellow label” on my theme
    here is my site
    :trendklub / dot / com

    i have option to put text there and i insert php code,but not working..also i add code into header and foother but widget area doesnt work too…only works on page
    pls can you reply me on my mail

    1. It looks like you activated the plugin but did not add the code appropriately. Find the following line in your theme’s header.php:
      < header id="header" class="pagewidth">
      and add the following on the next line:
      < ?php if(function_exists('flexible_frontend_login_modal') ) flexible_frontend_login_modal(); ?>
      This should do the magic.
      Good luck and let me know if it worked…

      PS: Don’t forget to take out the whitespace from “< ?"

  24. Hi,
    I translated your plugin in french. Maybe this could interest other people.
    Here is a link to the .mo, .po files.

    I saw some missing call to the translations, so I add them to your plugin.
    See the ffl.txt for changes locations and others files for the changes.

    Thank for this plugin it was really useful.


  25. Hi, thanks for this nice plugin! It works fine, but saving settings doesn’t work at my (new installed, not edited) version… You wrote that this issue should be removed already, but I have this problem with the actual version 0.97.5 and would be happy if you could give me a clue :) I’d like to change “Click to Login” to “Anmelden”…

    thanks, zan

  26. Hi!

    I love this plugin and want to keep using it but am having a problem. In some browsers, when users try to log in, they see pop-up messages and then can’t enter their info.

    For example, in Chrome, they get this message when they type in their username:

    “Please match the requested format”

    In Internet Explorer (newest version), it says:

    “You must use this format:”

    Both messages stop the visitor from being able to log in to the site. :(

    Is there any way to work around this? I have no problems in Firefox or IE 9.0.8112.

    I’m not opposed to going in and trying to change code, just tell me which file and where in the file the change should be made, if you know, of course. :)


  27. This is a great plugin, which I’d like to use on a number of websites. There is one small drawback at the moment. I use the plugin in conjunction with the qTranslate plugin for multilingual websites. Unfortunately, on the backend the Post or Page Title is adversely affected by your plugin. There is a separate title field for each language used with the website. But once this the post/page is saved the qTranslate filtering of the Title fields are interfered with. e.g.

    <!–:cy–>Ryseitiau<!–:–><!–:en–>Recipes<!–:–> Appears in the Title field, instead of “Ryseitiau” in the Cymraeg Title field, and “Recipes” in the English Title field. The unfiltered value would be: RyseitiauRecipes. The main text of the pages and posts is unaffected by your plugin.

    Any chance of a fix for this conflict?

  28. Sorry, should have used the code option. Here we go again:

    This is a great plugin, which I’d like to use on a number of websites. There is one small drawback at the moment. I use the plugin in conjunction with the qTranslate plugin for multilingual websites. Unfortunately, on the backend the Post or Page Title is adversely affected by your plugin. There is a separate title field for each language used with the website. But once this the post/page is saved the qTranslate filtering of the Title fields are interfered with. e.g.

    <!--:cy-->Ryseitiau<!--:--><!--:en-->Recipes<!--:--> appears in the Title field, instead of “Ryseitiau” in the Cymraeg Title field, and “Recipes” in the English Title field. The unfiltered value field value (i.e the value saved to the database) would be: RyseitiauRecipes. The main text of the pages and posts is unaffected by your plugin.

    Any chance of a fix for this conflict?

  29. Hi,

    I use your plugin.
    But their are some features that I missed.
    Si I add them. Here they are :
    Add Ajax
    Use beautiful CSS3, with alternative for old browsers
    HTML5 validate
    Add a register form, when activated in general settings
    Add option for choosing modal in widget
    Can now change the position of modal popup
    Add option for redirection on log in or out

    Maybe we could merge our code.

    Link to the code is here.

    See some pictures:
    Look for today :)
    Lost password in dutch
    To see CSS3 in action you need to try it on a modern browser.


      1. Just found your plugin and it’s really sweet,  I needed something really simple but something that also re-directed, Denis’ additions were perfect for me, and I am currently using it. Will you be folding his updates into your plugin soon? Would be good to know that I’m using the ‘official’ version. 1 suggestion would be to put the option of using a modal or not in the settings page as it wasn’t immediately obvious that I had to change the way I called the plugin from the template.
        Happy to contribute but you don’t seem to be asking for anything…

        1. Hi Zac,
          it took a while due to personal issues that I could come back to and answer all the comments. I will now step by step implement Denis’ suggestions as far as I agree to them and they really make things more convenient. I am not so happy with his idea of XML templating. In my opinion this is “a little too geeky”. But a lot of his ideas are great. His coding skills are far ahead of mine.

      2. Are you still working on flexible fronend login.
        I improved my code. And am still busy adding options.
        If you do not continue, I’ll be happy to take over the development.

  30. Hi Henning,

    Love the plugin, would really like to see a bit more info like the gravatar as with the Sidebar Login plugin when logged in.

    Created a Dutch translation for the plugin. Would like to submit it to you so you can add it to the package. Where would you like me to send it to?



  31. Hi Henning.

    Thanks for the response. I’m guessing that the problem lies with includes/markdown.php. I’ve had a look through the code and nothing obvious stands out – although the function encodeAmpsAndAngles($text) did attract my attention.

    The problem lies in the lesser and greater than symbols being replaced with the character entity references equivalents before qTranslate parses the post/page titles. What purpose does markdown.php serve, and is it possible to disable some or all of it, at least to determine if this is the cause of the problems with qTranslate?

    1. I added the markdown class to parse the readme file in the backend in order to maintain one file with instructions for users. But it seems to be too complicated and might be abandoned in the next release.

      Once again I have to apologize for not being quicker with my replies (and the next release) – I am just a little to busy in my life.

      If you are in a hurry slow down

      – old chinese proverb.

  32. Hi,
    I’m using Flexible frontend login for my website with my own template. I can use the widget in a sidebar, but it doesn’t “pop up” but it is just in the sidebar. I also want to use it in my theme but there I have the same problem: it doesn’t pop up. Loggin out works just fine.
    On on the top navigation menu on the right (next to contact) I used the code <?php if ( function_exists(‘flexible_frontend_login_modal’) ) flexible_frontend_login_modal(); ?> and it says Click to login.
    It does appear, but clicking on it doesn’t make any difference. Once logged in, loggin out works fine.
    Can you please help me with this? I would love to have a log-in function in my top navigation.

  33. Hi, I start to use this plugin it is absolutely fine. Nevertheless, after the login the user information are on the same line: ADMIN – USERNAME – LOGOUT. I try to modify the cose in the ” class.FrontendLogin ” in order to obtain this order and aspect (in separate line)  of the information for logged in user: 
    have you some suggestion on how modify the code for obtainig this.
    Thank you

    1. Hi Simone, you should not do changes in the plugin files. class.FrontendLogin is the main file for the pplugin’s functionality. And even if you do changes they will be gone with the next update. Please go for the custom CSS. Read the instructions on how to add custom CSS.

    1. Hi Sjoerd,
      thank you very much. Please stay in touch to update the translation from time to time. Especially the help section will be extended and translations will be extremely helpful for other users.

  34. HI, Im getting a redirect error after i attempt to login, looks like your plugin doesnt take into account domain spoofed websites so its not pointing to the correct location… 

  35. Hello, I just downloaded your plugin and trying to use it for only for specific pages to block access for non-registered visitors. Is there a way to make it – as if you’d visit a page and click on any content, then “register to get instant access” login pops up?

  36. I’m looking to edit the form elements. I need to remove the “placeholders” from the input fields. Can you explain where this can be done? Love the plugin!!!

  37. Also…I’d like to center the popup in the window. Where can I find this setting or the file I need to edit? tx!

  38. I’d like to redirect to a specific User Role accessible page after a succesful login.
    Is there some PHP or shortcode that provides an easy redirect link? tx! -rob

  39. Hello,
    I was wandering. Currently I have the login on the front end and it works great. Only thing is that when in IE navigating through pages by the menu. But it pops up even without clickling the login button is there a way to make that stop?

  40. hi, nice plugin. i’m translate it on russian. let me know, if u need it. i’ll send .mo and .po files 2 u… you’re welcome.

    1. No, Jon, not so far. But I think you should be able to make that possible with setting #ffl-mask {display:block;} in the CSS file. However I do not know if this would break the whole thing. Let me know how it works for you.

  41. Great plugin, just what I was looking for!  Thanks for making it available :)
    I was able to change the look to match my website but I have a quick question.  Is there any way to stop the pop-up from appearing on page load/reload?  If I’m not logged in and I browse my website the pop-up appears on every page (until the page complete loads) then it disappears.

    1. Hi BB, this is propably depending on how fast your server delivers the site. If it is slow it takes a while to load the javascript which hides the forms (Javascript loaded at the end of the page). When I tested it with this site I could not reproduce your experience.

  42. I get page not found error when I try to login. However once I have logged in in the usual method, I could log out from here. Only the login is not functioning properly.

  43. Hi,
    I have a question. Is it possible to get the popup with frontend login at the moment the homepage loads in the browser to give only registered people access to the website?
    If yes, what do I have to do to get it?
    Looking forward to your response.

    1. How should that work? A eligible user is identified by logging in. How should a browser know that a visitor will soon be logging in AND that he has the right to do so?

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>