• Hi, I am hoping someone can help a complete wordpress novice

    I am planning to develop a wordpress website that will provide a simple searchable company knowledgebase. I intend to rent a dedicated server with cpanel for hosting this.

    The website will contain a ‘core’ set of information that is relevant to all users who view this, however some additional region specific information will be required and will differ from geographical location to location.

    Can anyone suggest a method of changing a websites viewable content based on the accessing user IP address? All IP addresses will be known in advance so it would be a matter of assigning the correct content to the user.

    I hope I explained this clearly! Any help / advice is much appreciated.

Viewing 2 replies - 1 through 2 (of 2 total)
  • This could be easily achieved using PHP, but within WordPress…..this is an interesting problem.

    You’ll probably need to write a plugin that gets the user’s IP address (the easy part) and then display only certain posts/pages (the hard part).

    My question is, what happens if someone tries to access the website from home, or while on a business trip? It might be a better option to use a membership type of plugin, and then create different membership groups that can view different pages/posts. Just thinking out loud here….

    Thread Starter lostd

    (@lostd)

    Thank you for your reply kjodle.

    I have thought about using subdomains for the various regional sections and if cpanel allows use deny IP to manage access. Though i’m not sure if cpanel supports denying access to individual subdomains.

    It seems a bit resource intensive having separate WP installations and content for each but outside of some clever code it probably is the only way of achieving the task.

    The offsite access was something I had thought about but couldn’t come up with a solution outside of the membership option you described (thins may be an option for future development though).

    If I do come up with a working solution I will update the thread in case anyone else has similar thoughts!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Site content viewed by IP address’ is closed to new replies.