Jump to content

Login Page Country States


FlyHost

Recommended Posts

Hello Guys, I want to use the following code on the login page, but I tried to do it with hook, but I could not.

 

 

 

<div class="form-group">
			<label for="country">{$LANG.clientareacountry}: <span class="required">*</span></label>
                <select id="country" name="country" class="form-control">
                       {foreach $clientcountries as $countryCode => $countryName}
                           <option value="{$country}"{if (!$clientcountry && $countryCode eq $defaultCountry) || ($countryCode eq $clientcountry)} selected="selected"{/if}>
                               {$country}
                           </option>
                       {/foreach}
                   </select>
             </div>

 

 

Hook I try to do

<?php

use Illuminate\Database\Capsule\Manager as Capsule;

function hook_country($vars){

   $client = Menu::context('client');

   return array("country" => $client->country);
}

add_hook('ClientLogin',1, 'hook_country');

 

 

I'm happy if you help me.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated