Each user has a one textfield with different text value.
user has loggned in
I want site name as text value .
How to programmatically done it.

Comments

saitanay’s picture

In your theme,. say batrik,. you will find like

    <?php if ($site_name || $site_slogan): ?>
      <div id="name-and-slogan"<?php if ($hide_site_name && $hide_site_slogan) { print ' class="element-invisible"'; } ?>>

before this you can override the $site_name like

global $user;
//get user object
$current_user = user_load($user->uid);
$user_site_name = $user->field_custom_site_name[xx]..['value'];
$site_name = $user_site_name;

above is just a pseudo code,. you gotta refine it.

savithac’s picture

Thanks Mr.Saitanay it works great.