Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


How can I hide my blog from people?



How can I hide my blog from people?..

Answer / Shubham Kaushik

To make your WordPress site private or hidden, you can either set it to password-protected or limit access by user roles. To set a password for your site, navigate to Settings > General in your WordPress dashboard and provide the new password under 'Site Address (URL)'. If you want to restrict access based on user roles, create a custom function in functions.php and use the appropriate code snippet to specify the roles that should be granted access.nn```phpn// Function to redirect non-admin usersnfunction my_redirect_non_admins() {n if (!current_user_can('administrator')) {n wp_redirect(site_url('/login'));n exit;n }n}nadd_action('template_redirect', 'my_redirect_non_admins');n```

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More WordPress Interview Questions

Is wordpress a security risk?

1 Answers  


Tell me how do I disable trackbacks and pingbacks?

1 Answers  


Explain, are the objects passed by value or by reference?

1 Answers  


What is the difference wordpress.com vs wordpress.org?

1 Answers  


What is an sql file?

1 Answers  


How do I turn on automatic updates for wordpress?

1 Answers  


Why You Should Use WordPress?

1 Answers  


How do I set up a web page?

1 Answers  


What's the difference between bluehost and wordpress?

1 Answers  


Can we set specific page to be displayed as homepage and different for blog posting in wordpress cms?

1 Answers  


Explain me what are the custom fields in wordpress? How to display it?

1 Answers  


Can I use a database other than mysql?

1 Answers  


Categories